Is this information correct?

Andrew Cagney ac131313@cygnus.com
Tue May 28 18:05:00 GMT 2002


> On Mon, May 27, 2002 at 02:07:21PM -0400, Daniel Jacobowitz wrote:
> 
>> What's this part about though?  I think it's really referring to gdb
>> 5.1 instead.  5.2 should be fine.
> 
> 
> Blah, its 6:30 am now... but we figured out what it was.
> It was not gdb's fault, nor gcc's fault.  The "problem"
> was that he was using -O2 and setting a break point
> for main causes the break point to be set 4 bytes behond
> 'main' (the function pointer) which was already at the
> start of some inlined constructor for which is was not
> clear that it would be there (-O2 magic etc).
> Anyway, my (independantly from gdb written) libcwd gave
> exactly the same source file line number info ;).

Can I suggest adding a more generic comment about avoiding ``-O2'' and 
``-fomit-frame-pointer''.  GD should be able to handle these cases but 
(typically) it can't.  A known limitation in GDB (i.e. a bug :-).

enjoy,
Andrew




More information about the Gdb mailing list