dwarf2 and frame bases

Daniel Jacobowitz drow@false.org
Thu Nov 11 09:57:00 GMT 2004


On Wed, Nov 10, 2004 at 04:09:33PM -0800, Randolph Chung wrote:
> > 'b' is in some particular frame.  It's up the stack from the current
> > frame at the time of that error message, I get.  So we should be
> > unwinding reg3 and using the unwound copy to determine the value of b.
> > Is the unwinding breaking?
> 
> but the unwound copy is wrong too... :) i explain more below..

Then, that's a bug in the unwinder.

> r3 is also a callee-saved register, so its contents are undefined on
> entry to the function. so even if you were to unwind r3, you won't get
> the right frame base.

That's your mistake.  At the first instruction of the prologue,
unwinding r3 for the previous frame should use the copy already in
r3; you need to be falling back to a prologue analyzer and cutting it
off at $pc.  I thought you already were?

-- 
Daniel Jacobowitz



More information about the Gdb mailing list