Add handler for printing java stack traces for compiled code SIGSEGV.
Added a new FaultHandler which attempts to print a java stack trace
when a SIGSEGV occurse in generated code. This should help debugging
compiler and GC related heap corruption.
Bug: 13725693
Bug: 12934910
Change-Id: Id54d83ea180c222eb86d449c61926e83f0b026ad
diff --git a/runtime/thread.h b/runtime/thread.h
index 59fe724..f1c1d77 100644
--- a/runtime/thread.h
+++ b/runtime/thread.h
@@ -156,6 +156,10 @@
LOCKS_EXCLUDED(Locks::thread_suspend_count_lock_)
SHARED_LOCKS_REQUIRED(Locks::mutator_lock_);
+ void DumpJavaStack(std::ostream& os) const
+ LOCKS_EXCLUDED(Locks::thread_suspend_count_lock_)
+ SHARED_LOCKS_REQUIRED(Locks::mutator_lock_);
+
// Dumps the SIGQUIT per-thread header. 'thread' can be NULL for a non-attached thread, in which
// case we use 'tid' to identify the thread, and we'll include as much information as we can.
static void DumpState(std::ostream& os, const Thread* thread, pid_t tid)