From bad560bb69fce7fb03c5490c85efca23a2a79627 Mon Sep 17 00:00:00 2001 From: "ted.mielczarek" Date: Tue, 9 Feb 2010 12:16:45 +0000 Subject: [PATCH] Print ARM register values in minidump_stackwalk. r=nealsid at http://breakpad.appspot.com/57002 git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@516 4c0a9323-5329-0410-9bdc-e9ce6186880e --- src/processor/minidump_stackwalk.cc | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/processor/minidump_stackwalk.cc b/src/processor/minidump_stackwalk.cc index 6b7931bd..368d64fa 100644 --- a/src/processor/minidump_stackwalk.cc +++ b/src/processor/minidump_stackwalk.cc @@ -70,6 +70,7 @@ using google_breakpad::StackFramePPC; using google_breakpad::StackFrameSPARC; using google_breakpad::StackFrameX86; using google_breakpad::StackFrameAMD64; +using google_breakpad::StackFrameARM; // Separator character for machine readable output. static const char kOutputSeparator = '|'; @@ -211,6 +212,16 @@ static void PrintStack(const CallStack *stack, const string &cpu) { sequence = PrintRegister("fp", frame_sparc->context.g_r[30], sequence); if (frame_sparc->context_validity & StackFrameSPARC::CONTEXT_VALID_PC) sequence = PrintRegister("pc", frame_sparc->context.pc, sequence); + } else if (cpu == "arm") { + const StackFrameARM *frame_arm = + reinterpret_cast(frame); + + if (frame_arm->context_validity & StackFrameARM::CONTEXT_VALID_R13) + sequence = PrintRegister("r13", frame_arm->context.iregs[13], sequence); + if (frame_arm->context_validity & StackFrameARM::CONTEXT_VALID_R14) + sequence = PrintRegister("r14", frame_arm->context.iregs[14], sequence); + if (frame_arm->context_validity & StackFrameARM::CONTEXT_VALID_R15) + sequence = PrintRegister("r15", frame_arm->context.iregs[15], sequence); } printf("\n"); }