Re: Debugging a frameless function

Daniel Jacobowitz
2009-04-29T18:39:58Z

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