.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.47.4. .TH LD.LLD "1" "March 2018" "ld.lld 6.0" "User Commands" .SH NAME ld.lld \- manual page for ld.lld 6.0 .SH DESCRIPTION OVERVIEW: lld .PP USAGE: build\-llvm/bin/ld.lld [options] .SS "OPTIONS:" .TP \fB\-\-allow\-multiple\-definition\fR Allow multiple definitions .TP \fB\-\-as\-needed\fR Only set DT_NEEDED for shared libraries if used .TP \fB\-\-auxiliary\fR Set DT_AUXILIARY field to the specified name .TP \fB\-\-Bdynamic\fR Link against shared libraries .TP \fB\-\-Bshareable\fR Build a shared object .TP \fB\-\-Bstatic\fR Do not link against shared libraries .TP \fB\-\-Bsymbolic\-functions\fR Bind defined function symbols locally .TP \fB\-\-Bsymbolic\fR Bind defined symbols locally .TP \fB\-\-build\-id=\fR Generate build ID note .TP \fB\-\-build\-id\fR Generate build ID note .TP \fB\-\-b\fR Change the input format of the inputs following this option .TP \fB\-\-call_shared\fR Link against shared libraries .TP \fB\-\-color\-diagnostics=\fR Use colors in diagnostics .TP \fB\-\-color\-diagnostics\fR Use colors in diagnostics .TP \fB\-\-compress\-debug\-sections=\fR Compress DWARF debug sections .TP \fB\-\-compress\-debug\-sections\fR Compress DWARF debug sections .TP \fB\-\-dc\fR Assign space to common symbols .TP \fB\-\-define\-common\fR Assign space to common symbols .TP \fB\-\-defsym=\fR Define a symbol alias .TP \fB\-\-defsym\fR Define a symbol alias .TP \fB\-\-demangle\fR Demangle symbol names .TP \fB\-\-disable\-new\-dtags\fR Disable new dynamic tags .TP \fB\-\-discard\-all\fR Delete all local symbols .TP \fB\-\-discard\-locals\fR Delete temporary local symbols .TP \fB\-\-discard\-none\fR Keep all symbols in the symbol table .TP \fB\-\-dn\fR Do not link against shared libraries .TP \fB\-\-dp\fR Assign space to common symbols .TP \fB\-\-dynamic\-linker\fR Which dynamic linker to use .TP \fB\-\-dynamic\-list=\fR Read a list of dynamic symbols .TP \fB\-\-dynamic\-list\fR Read a list of dynamic symbols .TP \fB\-\-dy\fR Link against shared libraries .TP \fB\-d\fR Assign space to common symbols .TP \fB\-\-eh\-frame\-hdr\fR Request creation of .eh_frame_hdr section and PT_GNU_EH_FRAME segment header .TP \fB\-\-emit\-relocs\fR Generate relocations in output .TP \fB\-\-enable\-new\-dtags\fR Enable new dynamic tags .TP \fB\-\-end\-lib\fR End a grouping of objects that should be treated as if they were together in an archive .TP \fB\-\-entry=\fR Name of entry point symbol .TP \fB\-\-entry\fR Name of entry point symbol .TP \fB\-\-error\-limit=\fR Maximum number of errors to emit before stopping (0 = no limit) .TP \fB\-\-error\-limit\fR Maximum number of errors to emit before stopping (0 = no limit) .TP \fB\-\-error\-unresolved\-symbols\fR Report unresolved symbols as errors .TP \fB\-\-exclude\-libs=\fR Exclude static libraries from automatic export .TP \fB\-\-exclude\-libs\fR Exclude static libraries from automatic export .TP \fB\-\-export\-dynamic\-symbol=\fR Put a symbol in the dynamic symbol table .TP \fB\-\-export\-dynamic\-symbol\fR Put a symbol in the dynamic symbol table .TP \fB\-\-export\-dynamic\fR Put symbols in the dynamic symbol table .TP \fB\-E\fR Put symbols in the dynamic symbol table .TP \fB\-e\fR Name of entry point symbol .TP \fB\-\-fatal\-warnings\fR Treat warnings as errors .TP \fB\-\-filter=\fR Set DT_FILTER field to the specified name .TP \fB\-\-filter\fR Set DT_FILTER field to the specified name .TP \fB\-\-fini=\fR Specify a finalizer function .TP \fB\-\-fini\fR Specify a finalizer function .HP \fB\-\-fix\-cortex\-a53\-843419\fR Apply fixes for AArch64 Cortex\-A53 erratum 843419 .HP \fB\-\-format=\fR Change the input format of the inputs following this option .HP \fB\-\-format\fR Change the input format of the inputs following this option .TP \fB\-\-full\-shutdown\fR Perform a full shutdown instead of calling _exit .TP \fB\-F\fR Set DT_FILTER field to the specified name .TP \fB\-f\fR Set DT_AUXILIARY field to the specified name .TP \fB\-\-gc\-sections\fR Enable garbage collection of unused sections .TP \fB\-\-gdb\-index\fR Generate .gdb_index section .TP \fB\-\-hash\-style=\fR Specify hash style (sysv, gnu or both) .TP \fB\-\-hash\-style\fR Specify hash style (sysv, gnu or both) .TP \fB\-\-help\fR Print option help .TP \fB\-h\fR Set DT_SONAME .TP \fB\-\-icf\-data\fR Enable ICF to also fold identical read only data .TP \fB\-\-icf\fR=\fI\,all\/\fR Enable identical code folding .TP \fB\-\-icf\fR=\fI\,none\/\fR Disable identical code folding .TP \fB\-\-image\-base=\fR Set the base address .TP \fB\-\-image\-base\fR Set the base address .TP \fB\-\-init=\fR Specify an initializer function .TP \fB\-\-init\fR Specify an initializer function .TP \fB\-\-library\-path=\fR Add a directory to the library search path .TP \fB\-\-library\-path\fR Add a directory to the library search path .TP \fB\-\-library=\fR Root name of library to use .TP \fB\-\-library\fR Root name of library to use .TP \fB\-\-lto\-aa\-pipeline=\fR AA pipeline to run during LTO. Used in conjunction with \fB\-lto\-newpm\-passes\fR .TP \fB\-\-lto\-newpm\-passes=\fR Passes to run during LTO .TP \fB\-\-lto\-O\fR Optimization level for LTO .TP \fB\-\-lto\-partitions=\fR Number of LTO codegen partitions .TP \fB\-L\fR Add a directory to the library search path .TP \fB\-l\fR Root name of library to use .TP \fB\-\-Map=\fR Print a link map to the specified file .TP \fB\-\-Map\fR Print a link map to the specified file .TP \fB\-\-merge\-exidx\-entries\fR Enable merging .ARM.exidx entries .TP \fB\-M\fR Print a link map to the standard output .TP \fB\-m\fR Set target emulation .TP \fB\-\-no\-as\-needed\fR Always DT_NEEDED for shared libraries .TP \fB\-\-no\-color\-diagnostics\fR Do not use colors in diagnostics .TP \fB\-\-no\-define\-common\fR Do not assign space to common symbols .TP \fB\-\-no\-demangle\fR Do not demangle symbol names .TP \fB\-\-no\-dynamic\-linker\fR Inhibit output of .interp section .TP \fB\-\-no\-eh\-frame\-hdr\fR Do not create .eh_frame_hdr section .TP \fB\-\-no\-gc\-sections\fR Disable garbage collection of unused sections .TP \fB\-\-no\-gdb\-index\fR Do not generate .gdb_index section .TP \fB\-\-no\-gnu\-unique\fR Disable STB_GNU_UNIQUE symbol binding .TP \fB\-\-no\-merge\-exidx\-entries\fR Disable merging .ARM.exidx entries .TP \fB\-\-no\-omagic\fR Do not set the text data sections to be writable .TP \fB\-\-no\-print\-gc\-sections\fR Do not list removed unused sections .TP \fB\-\-no\-rosegment\fR Do not put read\-only non\-executable sections in their own segment .TP \fB\-\-no\-threads\fR Do not run the linker multi\-threaded .TP \fB\-\-no\-undefined\-version\fR Report version scripts that refer undefined symbols .TP \fB\-\-no\-undefined\fR Report unresolved symbols even if the linker is creating a shared library .TP \fB\-\-no\-whole\-archive\fR Restores the default behavior of loading archive members .TP \fB\-\-noinhibit\-exec\fR Retain the executable output file whenever it is still usable .TP \fB\-\-non_shared\fR Do not link against shared libraries .TP \fB\-\-nopie\fR Do not create a position independent executable .TP \fB\-\-nostdlib\fR Only search directories specified on the command line .TP \fB\-N\fR Set the text and data sections to be readable and writable .TP \fB\-\-oformat\fR Specify the binary format for the output object file .TP \fB\-\-omagic\fR Set the text and data sections to be readable and writable .TP \fB\-\-opt\-remarks\-filename\fR YAML output file for optimization remarks .TP \fB\-\-opt\-remarks\-with\-hotness\fR Include hotness informations in the optimization remarks file .TP \fB\-\-orphan\-handling=\fR Control how orphan sections are handled when linker script used .TP \fB\-\-orphan\-handling\fR Control how orphan sections are handled when linker script used .TP \fB\-\-output=\fR Path to file to write output .TP \fB\-\-output\fR Path to file to write output .TP \fB\-O\fR Optimize output file size .TP \fB\-o\fR Path to file to write output .TP \fB\-\-pack\-dyn\-relocs=\fR Pack dynamic relocations in the given format (none or android) .TP \fB\-\-pic\-executable\fR Create a position independent executable .TP \fB\-\-pie\fR Create a position independent executable .TP \fB\-\-plugin\-opt=\fR specifies LTO options for compatibility with GNU linkers .TP \fB\-\-plugin\-opt\fR specifies LTO options for compatibility with GNU linkers .TP \fB\-\-print\-gc\-sections\fR List removed unused sections .TP \fB\-\-print\-map\fR Print a link map to the standard output .TP \fB\-q\fR Generate relocations in output .TP \fB\-\-relocatable\fR Create relocatable object file .TP \fB\-\-reproduce=\fR Dump linker invocation and input files for debugging .TP \fB\-\-reproduce\fR Dump linker invocation and input files for debugging .TP \fB\-\-retain\-symbols\-file=\fR Retain only the symbols listed in the file .TP \fB\-\-retain\-symbols\-file\fR Retain only the symbols listed in the file .TP \fB\-\-rpath=\fR Add a DT_RUNPATH to the output .TP \fB\-\-rpath\fR Add a DT_RUNPATH to the output .TP \fB\-\-rsp\-quoting=\fR Quoting style for response files. Values supported: windows|posix .TP \fB\-\-rsp\-quoting\fR Quoting style for response files. Values supported: windows|posix .TP \fB\-R\fR Add a DT_RUNPATH to the output .TP \fB\-r\fR Create relocatable object file .TP \fB\-\-script=\fR Read linker script .TP \fB\-\-script\fR Read linker script .TP \fB\-\-section\-start\fR
Set address of section .TP \fB\-\-shared\fR Build a shared object .TP \fB\-\-soname=\fR Set DT_SONAME .TP \fB\-\-soname\fR Set DT_SONAME .TP \fB\-\-sort\-section=\fR Specifies sections sorting rule when linkerscript is used .TP \fB\-\-sort\-section\fR Specifies sections sorting rule when linkerscript is used .TP \fB\-\-start\-lib\fR Start a grouping of objects that should be treated as if they were together in an archive .TP \fB\-\-static\fR Do not link against shared libraries .TP \fB\-\-strip\-all\fR Strip all symbols .TP \fB\-\-strip\-debug\fR Strip debugging information .TP \fB\-\-symbol\-ordering\-file\fR Layout sections in the order specified by symbol file .TP \fB\-\-sysroot=\fR Set the system root .TP \fB\-\-sysroot\fR Set the system root .TP \fB\-S\fR Strip debugging information .TP \fB\-s\fR Strip all symbols .TP \fB\-\-target1\-abs\fR Interpret R_ARM_TARGET1 as R_ARM_ABS32 .TP \fB\-\-target1\-rel\fR Interpret R_ARM_TARGET1 as R_ARM_REL32 .TP \fB\-\-target2=\fR Interpret R_ARM_TARGET2 as , where is one of rel, abs, or got\-rel .TP \fB\-\-target2\fR Interpret R_ARM_TARGET2 as , where is one of rel, abs, or got\-rel .TP \fB\-\-Tbss=\fR Same as \fB\-\-section\-start\fR with .bss as the sectionname .TP \fB\-\-Tbss\fR Same as \fB\-\-section\-start\fR with .bss as the sectionname .TP \fB\-\-Tdata=\fR Same as \fB\-\-section\-start\fR with .data as the sectionname .TP \fB\-\-Tdata\fR Same as \fB\-\-section\-start\fR with .data as the sectionname .TP \fB\-\-thinlto\-cache\-dir=\fR Path to ThinLTO cached object file directory .TP \fB\-\-thinlto\-cache\-policy\fR Pruning policy for the ThinLTO cache .TP \fB\-\-thinlto\-jobs=\fR Number of ThinLTO jobs .TP \fB\-\-threads\fR Run the linker multi\-threaded .TP \fB\-\-trace\-symbol=\fR Trace references to symbols .TP \fB\-\-trace\-symbol\fR Trace references to symbols .TP \fB\-\-trace\fR Print the names of the input files .HP \fB\-\-Ttext\-segment=\fR Same as \fB\-\-section\-start\fR with .text as the sectionname .HP \fB\-\-Ttext\-segment\fR Same as \fB\-\-section\-start\fR with .text as the sectionname .TP \fB\-\-Ttext=\fR Same as \fB\-\-section\-start\fR with .text as the sectionname .TP \fB\-\-Ttext\fR Same as \fB\-\-section\-start\fR with .text as the sectionname .TP \fB\-T\fR Read linker script .TP \fB\-t\fR Print the names of the input files .TP \fB\-\-undefined=\fR Force undefined symbol during linking .TP \fB\-\-undefined\fR Force undefined symbol during linking .TP \fB\-\-unresolved\-symbols=\fR Determine how to handle unresolved symbols .TP \fB\-\-unresolved\-symbols\fR Determine how to handle unresolved symbols .TP \fB\-u\fR Force undefined symbol during linking .TP \fB\-\-verbose\fR Verbose mode .TP \fB\-\-version\-script=\fR Read a version script .TP \fB\-\-version\-script\fR Read a version script .TP \fB\-\-version\fR Display the version number and exit .TP \fB\-V\fR Display the version number and exit .TP \fB\-v\fR Display the version number .TP \fB\-\-warn\-common\fR Warn about duplicate common symbols .TP \fB\-\-warn\-unresolved\-symbols\fR Report unresolved symbols as warnings .TP \fB\-\-whole\-archive\fR Force load of all members in a static library .TP \fB\-\-wrap=\fR Use wrapper functions for symbol .TP \fB\-\-wrap\fR Use wrapper functions for symbol .TP \fB\-X\fR Delete temporary local symbols .TP \fB\-x\fR Delete all local symbols .TP \fB\-y\fR Trace references to symbols .TP \fB\-z\fR