This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: Debugging a frameless function
- From: Daniel Jacobowitz <drow at false dot org>
- To: Eli Zaretskii <eliz at gnu dot org>
- Cc: gdb at sourceware dot org
- Date: Wed, 29 Apr 2009 14:39:46 -0400
- Subject: Re: Debugging a frameless function
- References: <83zldzco0p.fsf@gnu.org>
On Wed, Apr 29, 2009 at 09:28:54PM +0300, Eli Zaretskii wrote:
> My question is, how should GDB overcome the difficulty of a frameless
> function, when it tries to unwind a frame where EBP is used for
> holding a variable? Can someone please spot any missing pieces in the
> session below, and give me hints on where to look for the source of
> the trouble?
Sounds like the debug info is bad. If it tells GDB to look for
something relative to the frame base, and it tells GDB that the frame
base is in %ebp, but %ebp has a random variable, then the debug info
is incorrect. Check manually, using readelf -wi (and -wo if location
lists are in use).
--
Daniel Jacobowitz
CodeSourcery