🌐
GNU
gcc.gnu.org › onlinedocs › gcc › Link-Options.html
Link Options (Using the GNU Compiler Collection (GCC))
Use the gold linker instead of the default linker. ... Use the LLVM lld linker instead of the default linker. ... Use the Modern Linker (mold) instead of the default linker. ... Use the Wild linker (wild) instead of the default linker. ... Search the library named library when linking.
linker for ELF files
In software engineering, gold is a linker for ELF files. It became an official GNU package and was added to binutils in March 2008 and first released in binutils version 2.19. gold … Wikipedia
Factsheet
gold
Developer Ian Lance Taylor
Written in C++
Factsheet
gold
Developer Ian Lance Taylor
Written in C++
🌐
Wikipedia
en.wikipedia.org › wiki › Gold_(linker)
gold (linker) - Wikipedia
March 12, 2025 - The author cited complete removal ... the GNU linker. This rewrite also fixes some bugs in old ld that break ELF files in various minor ways. To specify gold in a makefile, one sets the LD or LD environment variable to ld.gold. To specify gold through a compiler option, one can use ...
Discussions

How to link with the GNU gold linker instead of ld in Haskell - Stack Overflow
My Haskell project spends lots of time in Linking dist/build/myapp/myapp ... and also in loading shared libraries when executing TemplateHaskell code. I suspect this is because ld is slow. How ca... More on stackoverflow.com
🌐 stackoverflow.com
Link with the gold linker for faster build times
Yesterday I put in some time to finally figure out how to link with GNU gold, which is much faster than ld. I found the topic quite underdocumented. Thought I'd share it for others who hate waiting on Linking dist/build/myapp/myapp .... Thanks to the helpful people on #ghc, especially rwbarton. More on reddit.com
🌐 r/haskell
52
57
April 6, 2017
linux - What is the gold linker? - Unix & Linux Stack Exchange
Has anyone used the gold linker before? To link a fairly large project, I had to use this as opposed to the GNU ld, which threw up a few errors and failed to link. How is the gold linker able to l... More on unix.stackexchange.com
🌐 unix.stackexchange.com
c++ - Replacing ld with gold - any experience? - Stack Overflow
-fuse-ld=gold is not complete. If you have to use -Wl,-fuse-ld=gold as it's used at the link-time. 2017-11-16T12:43:53.843Z+00:00 ... @Nawaz No, -Wl, is used to pass an option directly to ld; to use another linker you need to tell that to gcc. Please refer to the doc. More on stackoverflow.com
🌐 stackoverflow.com
🌐
LLVM
llvm.org › docs › GoldPlugin.html
The LLVM gold plugin — LLVM 23.0.0git documentation
The gold linker is installed as ld.gold. To see whether gold is the default on your system, run /usr/bin/ld -v. It will report “GNU gold” or else “GNU ld” if not. If gold is already installed at /usr/bin/ld.gold, one option is to simply make that the default by backing up your existing /usr/bin/ld and creating a symbolic link with ln -s /usr/bin/ld.gold /usr/bin/ld.
🌐
GitHub
github.com › daemon515 › SSLGold
GitHub - daemon515/SSLGold: The original Gold linker source with my experimental updates · GitHub
-> Use the ld.gold found in $(specify_where_to_store_bins)/bins as the default linker · -> PLT randomization build options: --plt-random-size=SIZE → SIZE by which to increase each plt entry size · -z, plt-random-sequence → changes the sequence order of the PLT entries ·
Author   daemon515
🌐
Stack Overflow
stackoverflow.com › tags › gold-linker › hot
Hottest 'gold-linker' Answers - Stack Overflow
January 21, 2019 - Minimal synthetic benchmark: LD vs gold vs LLVM LLD Outcome: gold was about 3x to 4x faster for all values I've tried when using -Wl,--threads -Wl,--thread-count=$(nproc) to enable multithreading LLD ... ... The --rpath-link option is used by bfd ld to add to the search path used for finding DT_NEEDED shared libraries when doing link-time symbol resolution. It's basically telling the linker what to use as ...
🌐
Wordpress
globalengineer.wordpress.com › 2016 › 05 › 22 › gnu-c-and-gold-linker
GNU C++ and Gold Linker | The Global Engineer's Notebook
December 18, 2016 - Setting “export LD=ld.gold” so that the $LD environment variable uses ld.gold rather than ld (this is useful for projects using makefiles) As the super user, running binutils-config –linker ld.gold to change the default
🌐
Debian Manpages
manpages.debian.org › experimental › binutils-common › ld.gold.1.en.html
ld.gold(1) — binutils-common — Debian experimental — Debian Manpages
-fuse-ld [gold,bfd] Ignored for GCC linker option compatibility · -g · Ignored · --gc-sections · Remove unused sections · --no-gc-sections · Don't remove unused sections (default) --gdb-index · Generate .gdb_index section · --no-gdb-index · Do not generate .gdb_index section (default) --gnu-unique ·
🌐
Ubuntu
manpages.ubuntu.com › manpages › trusty › man1 › ld.gold.1.html
Ubuntu Manpage: gold - The GNU ELF linker
es-mapped Keep files mapped across passes (default) --no-keep-files-mapped Release mapped files after each pass --ld-generated-unwind-info Generate unwind information for PLT (default) --no-ld-generated-unwind-info Do not generate unwind information for PLT -l LIBNAME, --library LIBNAME Search for library LIBNAME -L DIR, --library-path DIR Add directory to search path --text-reorder Enable text section reordering for GCC section names (default) --no-text-reorder Disable text section reordering for GCC section names -nostdlib Only search directories specified on the command line. --rosegment Put read-only non-executable sections in their own segment --rosegment-gap OFFSET Set offset between executable and read-only segments -m EMULATION Set GNU linker emulation; obsolete --mmap-output-file Map the output file for writing (default).
Find elsewhere
🌐
Baeldung
baeldung.com › home › building › exploring gnu gold linker
Exploring GNU Gold Linker | Baeldung on Linux
June 13, 2025 - We can use gold by specifying it with the compiler option -fuse-ld=gold: ... Those variables will tell GCC to use the gold linker.
🌐
Gentoo Wiki
wiki.gentoo.org › wiki › Gold
Gold - Gentoo wiki
April 14, 2025 - Additionally, the default linker is also installed as ld - and this binary is used by compilers. Gold can be enabled by setting the gold USE flag for sys-devel/binutils.
🌐
Reddit
reddit.com › r/haskell › link with the gold linker for faster build times
r/haskell on Reddit: Link with the gold linker for faster build times
April 6, 2017 - ghc-options: "*": "-split-sections -optl-fuse-ld=gold" apply-ghc-options: everything · (of course after adding this you must nuke all your built snapshots and rebuild everything) Actually LLVM's LLD linker is even better, but I think it prevented me from using GHCi in object mode.
🌐
SysTutorials
systutorials.com › docs › linux › man › 1-ld.gold
ld.gold: The GNU ELF linker - Linux Manuals (1)
gold - The GNU ELF linker · ld.gold [,options/] ,file/... --help · Report usage information · -v, --version · Report version information · -V · Report version and target information · --add-needed · Not supported · --no-add-needed · Do not copy DT_NEEDED tags from shared libraries (default) --allow-multiple-definition Allow multiple definitions of symbols ·
🌐
Grokipedia
grokipedia.com › gold (linker)
gold (linker) — Grokipedia
January 14, 2026 - Written in C++ by Ian Lance Taylor ... with many object files, and is invoked via the GNU Compiler Collection (GCC) with the -fuse-ld=gold option......
🌐
CommandLinux
commandlinux.com › home › man page › gold
GOLD
January 29, 2026 - gold – The GNU ELF linker · ld.gold [,options/] ,file/… · –help · Report usage information · -v, –version · Report version information · -V · Report version and target information · –add-needed · Not supported · –no-add-needed · Do not copy DT_NEEDED tags from shared libraries ·
Top answer
1 of 4
35

The gold linker was designed as an ELF-specific linker, with the intention of producing a more maintainable and faster linker than BFD ld (the “traditional” GNU binutils linker). As a side-effect, it is indeed able to link very large programs using less memory than BFD ld, presumably because there are fewer layers of abstraction to deal with, and because the linker’s data structures map more directly to the ELF format.

I’m not sure there’s much documentation which specifically addresses the design differences between the two linkers, and their effect on memory use. There is a very interesting series of articles on linkers by Ian Lance Taylor, the author of the various GNU linkers, which explains many of the design decisions leading up to gold. He writes that

The linker I am now working, called gold, on will be my third. It is exclusively an ELF linker. Once again, the goal is speed, in this case being faster than my second linker. That linker has been significantly slowed down over the years by adding support for ELF and for shared libraries. This support was patched in rather than being designed in.

(The second linker is BFD ld.)

The gold linker is deprecated in binutils 2.44 and will be dropped entirely at some point in the future.

2 of 4
18

The gold linker was written to make the link process considerably faster. According to the gold auther Ian Lance Taylor

At the moment gold has only one significant advantage over the existing linker: it is faster. On large C++ programs, I have measured it as running five times faster.

He is comparing gold linker performance with the traditional GNU linker. gold (unlike the GNU linker) does not use the BFD library to process object files.

The limitation of gold is that (unlike GNU linker which can process many object file types) it can only link ELF format object files.

Regarding the issues you faced with when using GNU linker, here is an interesting answer to a similar question on SO from Michael Adam:

The gold linker even found some dependency problems in our code, since it seems to be more correct than the classical one with respect to some details. See, e.g. this Samba commit.

🌐
Fedora Project
fedoraproject.org › wiki › GoldLinking
GoldLinking - Fedora Project Wiki
Usage: gold-rebuild [OPTION]... Link programs with gold linker. -c, --color Output in colors. -r, --rebuild Rebuild current binutils snapshot, create Yum for Mock repository and use it. Without --rebuild we use distribution binutils. -g, --group <GROUP> Select Fedora comps GROUP to rebuild.
🌐
The Fedora Project
fedoraproject.org › wiki › Changes › DeprecateGoldLinker
Changes/DeprecateGoldLinker - Fedora Project Wiki
April 16, 2025 - Instead it would need the builder to add the --with gold option. A release after that, remove the option to build gold entirely. ... For developers who are currently using the gold linker in their project(s), a decision will have to be made as to whether they should switch to a different linker or stay with gold.