.eh_frame section
Ian Lance Taylor
ian@cygnus.com
Thu Oct 9 09:26:00 GMT 1997
Date: Wed, 8 Oct 1997 16:49:24 -0700
From: Richard Henderson <rth@cygnus.com>
On Wed, Oct 08, 1997 at 06:38:03PM -0400, meissner@cygnus.com wrote:
> | Most architectures have a word sized pc-relative relocation, but few
> | (none?) provide a pseudo-op to use it. So there we are.
>
> On the other hand, doing:
>
> .long .-label
>
> (or .word, .etc.) will often times generate the approprate relocation.
When "label" is external, no assembler I've found can handle it.
I tried gas (alpha, i386), Irix 6, Solaris 2.5, DU 4.0b.
Not too surprising, since that's a reverse PC relative reloc. You
could only get a proper PC relative reloc by doing
.long label-.
However, many assemblers don't support that either.
Incidentally, if the DWARF spec requires that the value be an offset
from the start of the section, and we're generating an absolute
address, then we're already violating the spec. I don't know much
about DWARF, but it sounds like they didn't consider the case of
loading the information into memory with the program.
Ian
More information about the Gcc
mailing list