
l
ld(1) | ld(1) |
libraries
Dump info about libraries searched.
procelim
Dump info about sections that have been rejected by the +Oprocelim option
sections
Dump info about each input section added to the output ®le.
symbols
Dump info about global symbols referenced/de®ned from/in the input ®les.
all Dumps all of the above info. Same as
Defaults
Unless otherwise directed, ld names its output a.out. The
The default value of the
For
Incremental linking with ld
In the
The linker performs the following different modes of linking:
∙normal link: the default operation mode in which the linker links all modules.
∙initial incremental link: the mode entered when you request an incremental link, but the output module created by the incremental linker does not exist, or it exists but the incremental linker is unable to perform an incremental update.
∙incremental link: the mode entered when you request an incremental link, an output module created by the incremental linker exists, and the incremental linker does not require an initial incremental link.
Incremental links are usually much faster than regular links. On the initial link, the incremental linker requires about the same amount of time that a normal link process requires, but subsequent incremental links can be much faster than a normal link. A change in one object ®le in a moderate size link (tens of ®les, several megabytes total) normally is about 10 times faster than a regular ld link. The incremental linker perform as many incremental links as allocated padding space and other constrains permit. The cost of the reduced link time is an increase in the size of the executable or shared library.
The incremental linker allocates padding space for all components of the output ®le. Padding makes modules larger than those modules linked by ld. As object ®les increase in size during successive incremental links, the incremental linker can exhaust the available padding. If this occurs, it displays a warning message and does a complete initial incremental link of the module. When an object ®le changes, the incremental linker not only replaces the content of that ®le in the executable or shared library being linked, but also adjusts references to all symbols de®ned in the object ®le and referenced by other objects. This is done by looking at relocation records saved in the incrementally linked executable or shared library.
On the initial incremental link, the linker processes the input object ®les and libraries in the same way as the normal link. In addition to the normal linking process, the incremental linker saves information about object ®les, global symbols, and relocations, and pads sections in the output ®le for expansion. On subsequent incremental links, the linker uses timestamps and ®le sizes to determine which object ®les have changed, and updates those modules.
Under certain conditions, the incremental linker cannot perform incremental links. When this occurs, the incremental linker automatically performs an initial incremental link to restore the process. In the following situations, the linker automatically performs an initial incremental link of the output ®le:
Section 1−434 | − 12 − |