DWARF2 unwinding documentation/help
Jim Wilson
wilson@tuliptree.org
Mon Aug 25 21:41:00 GMT 2003
Bernardo Innocenti wrote:
> My target is an m68k-elf variant using a surrogate of the ELF format.
> It needs to place the unwinding tables in the data segment and doesn't
> link crtbegin/crtend. I've seen EH related stuff in there, but I'm
> not sure whether they are needed.
There needs to be a way for the unwinder to find the EH info at run
time. One mechanism involves using the crtbegin and crtend files to
defines constructors and destructors that call register_frame_info and
deregister_frame_info. We can then maintain a linked list of pointers
to EH info that can be searched at run time. See unwind-dw2-fde.c.
Another mechanism involves searching the in-core ELF headers at the time
an exception is thrown. We have glibc support for this, see
unwind-dw2-fde-glibc.c. There is also a darwin specific file I haven't
looked at. You will need to use one of these mechanisms, or define one
that works for your target.
--
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com
More information about the Gcc
mailing list