This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: dwarf-frame.c question


On May 30, 2003, Jim Blandy <jimb@redhat.com> wrote:

> Andrew Cagney <ac131313@redhat.com> writes:
>> One idea (the origins of which are unknown) is for the compiler to
>> generate CFI info containing no addresses and have GDB look for that
>> dependant on the PC address being obtained using return or resume
>> (sigtramp, sentinel).

> I don't understand this.  Could you explain the idea in more detail?

The idea Andrew and I came up with was initially to get GCC to emit a
useless nop (especially when compiling without optimization) that
would hold the post-call CFI information.  Afterwards, one of us
thought that, even if the nop was removed, we could still emit CFI
information for the now-empty region, and have GDB (or, even better,
the DWARF3 spec) recognize this as a special case for non-returning
calls.

I agree with you that, in general, the CFI information might just
indicate that the stack was trashed beyond recognition, but often
the info will still be there, and there's no reason to not present the
information in a usable format in such cases.

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                 aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist                Professional serial bug killer


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]