This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: dwarf2 frame unwinder assumptions on SP
- From: Daniel Jacobowitz <drow at false dot org>
- To: Christophe LYON <christophe dot lyon at st dot com>
- Cc: gdb at sources dot redhat dot com
- Date: Mon, 11 Jul 2005 10:50:53 -0400
- Subject: Re: dwarf2 frame unwinder assumptions on SP
- References: <42D285AB.9E36C062@st.com>
On Mon, Jul 11, 2005 at 04:43:55PM +0200, Christophe LYON wrote:
>
> Hi all,
>
> I am working on the connection of the dwarf2 frame unwinder
> to our GDB port, and I have trouble with some assumptions
> made by GDB about SP.
>
> Currently, in my x-tdep.c I have:
> set_gdbarch_unwind_pc(gdbarch, x_unwind_pc);
> frame_unwind_append_sniffer (gdbarch, dwarf2_frame_sniffer);
It sounds like you need to set a "frame base" sniffer also, other than
the dwarf one. The dwarf2 frame unwinder does not set anything related
to the "frame base" used by symbolic debug information; it only unwinds
the stack pointer as best it can.
Does "print $sp" work correctly when unwinding?
--
Daniel Jacobowitz
CodeSourcery, LLC