ppc stackwalker (#30). r=bryner

- Implementation of PowerPC stackwalker.  Tested using stackwalker_selftest
   (#18).
 - Hook up processor-side multi-CPU support in MinidumpProcessor and
   minidump_stackwalk using the new Stackwalker::StackwalkerForCPU method.

http://groups.google.com/group/airbag-dev/browse_thread/thread/1c2fa7c5182a77a9


git-svn-id: http://google-breakpad.googlecode.com/svn/trunk@34 4c0a9323-5329-0410-9bdc-e9ce6186880e
This commit is contained in:
mmentovai 2006-09-25 18:29:48 +00:00
parent 3402cae5e5
commit 960e5277ee
11 changed files with 335 additions and 73 deletions

View file

@ -43,10 +43,8 @@
#include "processor/stackwalker.h"
#include "processor/minidump_format.h"
namespace google_airbag {
class MinidumpContext;
class MinidumpModuleList;
@ -57,24 +55,21 @@ class StackwalkerX86 : public Stackwalker {
// register state corresponding to the innermost called frame to be
// included in the stack. The other arguments are passed directly through
// to the base Stackwalker constructor.
StackwalkerX86(MinidumpContext* context,
MemoryRegion* memory,
MinidumpModuleList* modules,
SymbolSupplier* supplier);
StackwalkerX86(const MDRawContextX86 *context,
MemoryRegion *memory,
MinidumpModuleList *modules,
SymbolSupplier *supplier);
private:
// Implementation of Stackwalker, using x86 context (%ebp, %eip) and
// stack conventions (saved %ebp at [%ebp], saved %eip at 4[%ebp]).
virtual bool GetContextFrame(StackFrame* frame);
virtual bool GetCallerFrame(StackFrame* frame);
virtual bool GetContextFrame(StackFrame *frame);
virtual bool GetCallerFrame(StackFrame *frame,
const StackFrames *walked_frames);
// Stores the CPU context corresponding to the innermost stack frame to
// be returned by GetContextFrame.
const MDRawContextX86* context_;
// Stores the frame pointer returned in the last stack frame returned by
// GetContextFrame or GetCallerFrame.
u_int32_t last_frame_pointer_;
const MDRawContextX86 *context_;
};