Re: how is the eh_frame section used?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ethan Tira-Thompson <ejt@xxxxxxxxxxxxxx> writes:

> I would like to know how the data in the eh_frame section is used
> during runtime, and why the section changes based on the presence/
> absence of the -r flag.  (the data section does not change in terms
> of size or layout between the two products, however the eh_frame
> section does, and this throws off my extraction of relocation table
> information; I'm targeting MIPS with elf-format output)

The eh_frame data is used to unwind the stack when an exception is
thrown.  It records things like where to find the return address and
which registers are stored where.

The linker does some automatic optimization of the .eh_frame section
when linking.  See bfd/elf-eh-frame.c.  I would guess that perhaps it
does not do that when linking with -r.

Ian

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux