Linker (computing)
are assembled into a new library or executable A linker or link editor is a computer program that combines intermediate software build files such as object and library files into a single executable file such as a program or library. A linker is often part of a toolchain that includes a compiler and/or assembler that generates intermediate files that the linker processes. The linker may be integrated with other toolchain tools such that the user does not interact with the linker directly. A simpler version that writes its output directly to memory is called the loader, though loading is typically considered a separate process.
are assembled into a new library or executable A linker or link editor is a computer program that combines intermediate software build files such as object and library files into a single executable file such as a program or library. A linker is often part of a toolchain that includes a compiler and/or assembler that generates intermediate files that the linker processes. The linker may be integrated with other toolchain tools such that the user does not interact with the linker directly. A simpler version that writes its output directly to memory is called the loader, though loading is typically considered a separate process. == Relocation == As the compiler has no information on the layout of objects in the final output, it cannot take advantage of shorter or more efficient instructions that place a requirement on the address of another object. For example, a jump instruction can reference an absolute address or an offset from the current location, and the offset could be expressed with different lengths depending on the distance to the target. By first generating the most conservative instruction (usually the largest relative or absolute variant, depending on platform) and adding relaxation hints, it is possible to substitute shorter or more efficient instructions during the final link. In regard to jump optimizations this is also called automatic jump-sizing. This step can be performed only after all input objects have been read and assigned temporary addresses; the linker relaxation pass subsequently reassigns addresses, which may in turn allow more potential relaxations to occur. In general, the substituted sequences are shorter, which allows this process to always converge on the best solution given a fixed order of objects; if this is not the case, relaxations can conflict, and the linker needs to weigh the advantages of either option. While instruction relaxation typically occurs at link-time, inner-module relaxation can already take place as part of the optimizing process at compile-time. In some cases, relaxation can also occur at load-time as part of the relocation process or combined with dynamic dead-code elimination techniques. == Linkage editor == In IBM System/360 through IBM Z mainframe operating systems such as OS/360 and its successors, this type of program is known as a linkage editor. As the name implies a linkage editor has the additional capability of allowing the addition, replacement, and/or deletion of individual program sections. Operating systems such as OS/360 have format for executable load-modules containing supplementary data about the component sections of a program, so that an individual program section can be replaced, and other parts of the program updated so that relocatable addresses and other references can be corrected by the linkage editor, as part of the process. One advantage of this is that it allows a program to be maintained without having to keep all of the intermediate object files, or without having to re-compile program sections that haven't changed. It also permits program updates to be distributed in the form of small files (originally card decks), containing only the object module to be replaced. In such systems, object code is in the form and format of 80-byte punched-card images, so that updates can be introduced into a system using that medium. In later releases of OS/360 and in subsequent systems, load-modules contain additional data about versions of components modules, to create a traceable record of updates. It also allows one to add, change, or remove an overlay structure from an already linked load module. The term "linkage editor" should not be construed as implying that the program operates in a user-interactive mode like a text editor. It is intended for batch-mode execution, with the editing commands being supplied by the user in sequentially organized files, such as punched cards, DASD, or magnetic tape. Linkage editing (IBM nomenclature) or consolidation or collection (ICL nomenclature) refers to the linkage editor's or consolidator's act of combining the various pieces into a relocatable binary, whereas the loading and relocation into an absolute binary at the target address is normally considered a separate step. == Notable implementations== Ian Lance Taylor's Linkers blog entries Linkers and Loaders, a Linux Journal article by Sandeep Grover Another Listing of Where to Get a Complete Collection of Free Tools for Assembly Language Development GNU linker manual LLD - The LLVM Linker
References
- == Overview == Computer programs typically are composed of several parts or modules; these parts/modules do not need to be contained within a single object file, and in such cases refer to each ot . · retrieved 2026-10-02 · rev 1378131773
Cite this reference
MLA "== Overview == Computer programs typically are composed of several parts or modules; these parts/modules do not need to be contained within a single object file, and in such cases refer to each ot ." == Overview == Computer programs typically are composed of several parts or modules; these parts/modules do not need to. 2026-10-02. https://en.wikipedia.org/w/index.php?oldid=1378131773. Accessed 24 November 2026.
Chicago "== Overview == Computer programs typically are composed of several parts or modules; these parts/modules do not need to be contained within a single object file, and in such cases refer to each ot ." == Overview == Computer programs typically are composed of several parts or modules; these parts/modules do not need to. 2026-10-02. https://en.wikipedia.org/w/index.php?oldid=1378131773.
APA == Overview == Computer programs typically are composed of several parts or modules; these parts/modules do not need to. (2026). == Overview == Computer programs typically are composed of several parts or modules; these parts/modules do not need to be contained within a single object file, and in such cases refer to each ot . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1378131773
- GCC 12 Adds Support For Using The Mold Linker . www.phoronix.com . · retrieved 2026-10-02 · rev 1378131773
Cite this reference
MLA "GCC 12 Adds Support For Using The Mold Linker . www.phoronix.com ." GCC 12 Adds Support For Using The Mold Linker. 2026-10-02. https://en.wikipedia.org/w/index.php?oldid=1378131773. Accessed 24 November 2026.
Chicago "GCC 12 Adds Support For Using The Mold Linker . www.phoronix.com ." GCC 12 Adds Support For Using The Mold Linker. 2026-10-02. https://en.wikipedia.org/w/index.php?oldid=1378131773.
APA GCC 12 Adds Support For Using The Mold Linker. (2026). GCC 12 Adds Support For Using The Mold Linker . www.phoronix.com . Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1378131773
- IBM OS Linkage Editor and Loader . IBM Corporation . 1972. · retrieved 2026-10-02 · rev 1378131773
Cite this reference
MLA "IBM OS Linkage Editor and Loader . IBM Corporation . 1972." IBM OS Linkage Editor and Loader. 2026-10-02. https://en.wikipedia.org/w/index.php?oldid=1378131773. Accessed 24 November 2026.
Chicago "IBM OS Linkage Editor and Loader . IBM Corporation . 1972." IBM OS Linkage Editor and Loader. 2026-10-02. https://en.wikipedia.org/w/index.php?oldid=1378131773.
APA IBM OS Linkage Editor and Loader. (2026). IBM OS Linkage Editor and Loader . IBM Corporation . 1972. Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1378131773
- GNU Binutils: Linker Scripts . 2018-07-18. retrieved 2019-01-18 · retrieved 2019-01-17 · rev 1378131773
Cite this reference
MLA "GNU Binutils: Linker Scripts . 2018-07-18. retrieved 2019-01-18." GNU Binutils: Linker Scripts. 2019-01-17. https://en.wikipedia.org/w/index.php?oldid=1378131773. Accessed 24 November 2026.
Chicago "GNU Binutils: Linker Scripts . 2018-07-18. retrieved 2019-01-18." GNU Binutils: Linker Scripts. 2019-01-17. https://en.wikipedia.org/w/index.php?oldid=1378131773.
APA GNU Binutils: Linker Scripts. (2019). GNU Binutils: Linker Scripts . 2018-07-18. retrieved 2019-01-18. Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1378131773
- Assemblers and Loaders . February 1993. · retrieved 2026-10-02 · rev 1378131773
Cite this reference
MLA "Assemblers and Loaders . February 1993." Assemblers and Loaders. 2026-10-02. https://en.wikipedia.org/w/index.php?oldid=1378131773. Accessed 24 November 2026.
Chicago "Assemblers and Loaders . February 1993." Assemblers and Loaders. 2026-10-02. https://en.wikipedia.org/w/index.php?oldid=1378131773.
APA Assemblers and Loaders. (2026). Assemblers and Loaders . February 1993. Retrieved November 24, 2026, from https://en.wikipedia.org/w/index.php?oldid=1378131773
Cite this article
MLA
"Linker (computing)." encyclopegia.org, 2026, https://encyclopegia.org/wiki/linker-computing. Accessed 24 November 2026.
Chicago
"Linker (computing)." encyclopegia.org. Accessed November 24, 2026. https://encyclopegia.org/wiki/linker-computing.
APA
encyclopegia.org. (2026). Linker (computing). Retrieved November 24, 2026, from https://encyclopegia.org/wiki/linker-computing
Accessed November 24, 2026 · CC BY-SA 4.0 · citation page · JSON