3.2.2.9 Reading relocations
Coff relocations are easily transformed into the internal BFD form
(arelent
).
Reading a coff relocation table is done in the following stages:
-
Read the entire coff relocation table into memory.
-
Process each relocation in turn; first swap it from the
external to the internal form.
-
Turn the symbol referenced in the relocation's symbol index
into a pointer into the canonical symbol table.
This table is the same as the one returned by a call to
bfd_canonicalize_symtab
. The back end will call that
routine and save the result if a canonicalization hasn't been done.
-
The reloc index is turned into a pointer to a howto
structure, in a back end specific way. For instance, the 386
and 960 use the
r_type
to directly produce an index
into a howto table vector; the 88k subtracts a number from the
r_type
field and creates an addend field.
This document was generated
by system on December, 2 2004
using texi2html