This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC 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: The Extension to ELF


Ian Lance Taylor <iant@google.com> writes:

> [...]
> ELF is designed to permit fast program loading at runtime, and to
> permit fast linking.  Changing symbol and relocation values to take
> general expressions works against that goal.
> [...]

It may interest you to know that, for an older Cygnus project (mep),
we implemented a facility called computed/complex relocations, as an
ELF extension.  This is a way of encoding general symbol/arithmetic
expressions to be evaluated at link time and substituted into the
binary output.  (It may be similar to the vms-alpha ETIR facility.)

This has been merged into gnu binutils some time ago, though is not
widely known, and only used by a single cgen-based gas port.  See the
OBJ_COMPLEX_RELC conditionals in gas/*, the BSF_*RELC/STT_RELC logic
in bfd/*.

- FChE


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