diff src/share/vm/utilities/vmError.cpp @ 6972:bd7a7ce2e264

6830717: replay of compilations would help with debugging Summary: When java process crashed in compiler thread, repeat the compilation process will help finding root cause. This is done with using SA dump application class data and replay data from core dump, then use debug version of jvm to recompile the problematic java method. Reviewed-by: kvn, twisti, sspitsyn Contributed-by: yumin.qi@oracle.com
author minqi
date Mon, 12 Nov 2012 14:03:53 -0800
parents a1b8cf9cf970
children 679e6584c177 9deda4d8e126
line wrap: on
line diff
--- a/src/share/vm/utilities/vmError.cpp	Fri Nov 09 08:36:17 2012 -0800
+++ b/src/share/vm/utilities/vmError.cpp	Mon Nov 12 14:03:53 2012 -0800
@@ -1009,6 +1009,15 @@
     OnError = NULL;
   }
 
+  static bool skip_replay = false;
+  if (DumpReplayDataOnError && _thread && _thread->is_Compiler_thread() && !skip_replay) {
+    skip_replay = true;
+    ciEnv* env = ciEnv::current();
+    if (env != NULL) {
+      env->dump_replay_data();
+    }
+  }
+
   static bool skip_bug_url = !should_report_bug(first_error->_id);
   if (!skip_bug_url) {
     skip_bug_url = true;