diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2023-09-02 21:17:18 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2023-12-08 17:34:50 +0000 |
| commit | 06c3fb2749bda94cb5201f81ffdb8fa6c3161b2e (patch) | |
| tree | 62f873df87c7c675557a179e0c4c83fe9f3087bc /contrib/llvm-project/lld/docs | |
| parent | cf037972ea8863e2bab7461d77345367d2c1e054 (diff) | |
| parent | 7fa27ce4a07f19b07799a767fc29416f3b625afb (diff) | |
Diffstat (limited to 'contrib/llvm-project/lld/docs')
| -rw-r--r-- | contrib/llvm-project/lld/docs/ELF/start-stop-gc.rst | 2 | ||||
| -rw-r--r-- | contrib/llvm-project/lld/docs/MachO/ld64-vs-lld.rst | 2 | ||||
| -rw-r--r-- | contrib/llvm-project/lld/docs/NewLLD.rst | 2 | ||||
| -rw-r--r-- | contrib/llvm-project/lld/docs/ReleaseNotes.rst | 137 | ||||
| -rw-r--r-- | contrib/llvm-project/lld/docs/conf.py | 126 | ||||
| -rw-r--r-- | contrib/llvm-project/lld/docs/index.rst | 11 | ||||
| -rw-r--r-- | contrib/llvm-project/lld/docs/ld.lld.1 | 41 |
7 files changed, 186 insertions, 135 deletions
diff --git a/contrib/llvm-project/lld/docs/ELF/start-stop-gc.rst b/contrib/llvm-project/lld/docs/ELF/start-stop-gc.rst index 0baa1cae246a..acbc3c9b49e7 100644 --- a/contrib/llvm-project/lld/docs/ELF/start-stop-gc.rst +++ b/contrib/llvm-project/lld/docs/ELF/start-stop-gc.rst @@ -10,7 +10,7 @@ If your ``-Wl,--gc-sections`` build fail with a linker error like this: it is likely your C identifier name sections are not properly annotated to suffice under ``--gc-sections``. -``__start_meta`` and ``__stop_meta`` are sometimed called encapsulation +``__start_meta`` and ``__stop_meta`` are sometimes called encapsulation symbols. In October 2015, GNU ld switched behavior and made a ``__start_meta`` reference from a live section retain all ``meta`` input sections. This conservative behavior works for existing code which does not take GC into fair diff --git a/contrib/llvm-project/lld/docs/MachO/ld64-vs-lld.rst b/contrib/llvm-project/lld/docs/MachO/ld64-vs-lld.rst index 327bf0ab7167..4e2f3f29491b 100644 --- a/contrib/llvm-project/lld/docs/MachO/ld64-vs-lld.rst +++ b/contrib/llvm-project/lld/docs/MachO/ld64-vs-lld.rst @@ -51,6 +51,6 @@ the aliased symbols turn out to be weak definitions, but ld64 will. *********************************** ld64 has a special mode where it sets some stabs modification times to 0 for hermetic builds, enabled by setting any value for the ``ZERO_AR_DATE`` -environment variable. LLD flips this default to perfer hermetic builds, but +environment variable. LLD flips this default to prefer hermetic builds, but allows disabling this behavior by setting ``ZERO_AR_DATE=0``. Any other value of ``ZERO_AR_DATE`` will be ignored. diff --git a/contrib/llvm-project/lld/docs/NewLLD.rst b/contrib/llvm-project/lld/docs/NewLLD.rst index 1b1c87067f51..18b0cc83db51 100644 --- a/contrib/llvm-project/lld/docs/NewLLD.rst +++ b/contrib/llvm-project/lld/docs/NewLLD.rst @@ -5,7 +5,7 @@ The ELF Linker as a Library --------------------------- You can embed LLD to your program by linking against it and calling the linker's -entry point function lld::elf::link. +entry point function ``lld::lldMain``. The current policy is that it is your responsibility to give trustworthy object files. The function is guaranteed to return as long as you do not pass corrupted diff --git a/contrib/llvm-project/lld/docs/ReleaseNotes.rst b/contrib/llvm-project/lld/docs/ReleaseNotes.rst index a450923cded9..d8e34d1e6c74 100644 --- a/contrib/llvm-project/lld/docs/ReleaseNotes.rst +++ b/contrib/llvm-project/lld/docs/ReleaseNotes.rst @@ -26,39 +26,65 @@ Non-comprehensive list of changes in this release ELF Improvements ---------------- -* Link speed improved greatly compared with lld 15.0. Notably input section - initialization and relocation scanning are now parallel. - (`D130810 <https://reviews.llvm.org/D130810>`_) - (`D133003 <https://reviews.llvm.org/D133003>`_) -* ``ELFCOMPRESS_ZSTD`` compressed input sections are now supported. - (`D129406 <https://reviews.llvm.org/D129406>`_) -* ``--compress-debug-sections=zstd`` is now available to compress debug - sections with zstd (``ELFCOMPRESS_ZSTD``). - (`D133548 <https://reviews.llvm.org/D133548>`_) -* ``--no-warnings``/``-w`` is now available to suppress warnings. - (`D136569 <https://reviews.llvm.org/D136569>`_) -* ``DT_RISCV_VARIANT_CC`` is now produced if at least one ``R_RISCV_JUMP_SLOT`` - relocation references a symbol with the ``STO_RISCV_VARIANT_CC`` bit. - (`D107951 <https://reviews.llvm.org/D107951>`_) -* ``DT_STATIC_TLS`` is now set for AArch64/PPC32/PPC64 initial-exec TLS models - when producing a shared object. -* ``--no-undefined-version`` is now the default; symbols named in version - scripts that have no matching symbol in the output will be reported. Use - ``--undefined-version`` to revert to the old behavior. - (`D135402 <https://reviews.llvm.org/D135402>`_) -* ``-V`` is now an alias for ``-v`` to support ``gcc -fuse-ld=lld -v`` on many targets. -* ``-r`` no longer defines ``__global_pointer$`` or ``_TLS_MODULE_BASE_``. -* A corner case of mixed GCC and Clang object files (``STB_WEAK`` and - ``STB_GNU_UNIQUE`` in different COMDATs) is now supported. - (`D136381 <https://reviews.llvm.org/D136381>`_) -* The output ``SHT_RISCV_ATTRIBUTES`` section now merges all input components - instead of picking the first input component. - (`D138550 <https://reviews.llvm.org/D138550>`_) -* For x86-32, ``-fno-plt`` GD/LD TLS models ``call *___tls_get_addr@GOT(%reg)`` - are now supported. Previous output might have runtime crash. -* Armv4(T) thunks are now supported. - (`D139888 <https://reviews.llvm.org/D139888>`_) - (`D141272 <https://reviews.llvm.org/D141272>`_) +* When ``--threads=`` is not specified, the number of concurrency is now capped to 16. + A large ``--thread=`` can harm performance, especially with some system + malloc implementations like glibc's. + (`D147493 <https://reviews.llvm.org/D147493>`_) +* ``--remap-inputs=`` and ``--remap-inputs-file=`` are added to remap input files. + (`D148859 <https://reviews.llvm.org/D148859>`_) +* ``--lto=`` is now available to support ``clang -funified-lto`` + (`D123805 <https://reviews.llvm.org/D123805>`_) +* ``--lto-CGO[0-3]`` is now available to control ``CodeGenOpt::Level`` independent of the LTO optimization level. + (`D141970 <https://reviews.llvm.org/D141970>`_) +* ``--check-dynamic-relocations=`` is now correct 32-bit targets when the addend is larger than 0x80000000. + (`D149347 <https://reviews.llvm.org/D149347>`_) +* ``--print-memory-usage`` has been implemented for memory regions. + (`D150644 <https://reviews.llvm.org/D150644>`_) +* ``SHF_MERGE``, ``--icf=``, and ``--build-id=fast`` have switched to 64-bit xxh3. + (`D154813 <https://reviews.llvm.org/D154813>`_) +* Quoted output section names can now be used in linker scripts. + (`#60496 <https://github.com/llvm/llvm-project/issues/60496>`_) +* ``MEMORY`` can now be used without a ``SECTIONS`` command. + (`D145132 <https://reviews.llvm.org/D145132>`_) +* ``REVERSE`` can now be used in input section descriptions to reverse the order of input sections. + (`D145381 <https://reviews.llvm.org/D145381>`_) +* Program header assignment can now be used within ``OVERLAY``. This functionality was accidentally lost in 2020. + (`D150445 <https://reviews.llvm.org/D150445>`_) +* Operators ``^`` and ``^=`` can now be used in linker scripts. +* LoongArch is now supported. +* ``DT_AARCH64_MEMTAG_*`` dynamic tags are now supported. + (`D143769 <https://reviews.llvm.org/D143769>`_) +* AArch32 port now supports BE-8 and BE-32 modes for big-endian. + (`D140201 <https://reviews.llvm.org/D140201>`_) + (`D140202 <https://reviews.llvm.org/D140202>`_) + (`D150870 <https://reviews.llvm.org/D150870>`_) +* ``R_ARM_THM_ALU_ABS_G*`` relocations are now supported. + (`D153407 <https://reviews.llvm.org/D153407>`_) +* ``.ARM.exidx`` sections may start at non-zero output section offset. + (`D148033 <https://reviews.llvm.org/D148033>`_) +* Arm Cortex-M Security Extensions is now implemented. + (`D139092 <https://reviews.llvm.org/D139092>`_) +* BTI landing pads are now added to PLT entries accessed by range extension thunks or relative vtables. + (`D148704 <https://reviews.llvm.org/D148704>`_) + (`D153264 <https://reviews.llvm.org/D153264>`_) +* AArch64 short range thunk has been implemented to mitigate the performance loss of a long range thunk. + (`D148701 <https://reviews.llvm.org/D148701>`_) +* ``R_AVR_8_LO8/R_AVR_8_HI8/R_AVR_8_HLO8/R_AVR_LO8_LDI_GS/R_AVR_HI8_LDI_GS`` have been implemented. + (`D147100 <https://reviews.llvm.org/D147100>`_) + (`D147364 <https://reviews.llvm.org/D147364>`_) +* ``--no-power10-stubs`` now works for PowerPC64. +* ``DT_PPC64_OPT`` is now supported; + (`D150631 <https://reviews.llvm.org/D150631>`_) +* ``PT_RISCV_ATTRIBUTES`` is added to include the SHT_RISCV_ATTRIBUTES section. + (`D152065 <https://reviews.llvm.org/D152065>`_) +* ``R_RISCV_PLT32`` is added to support C++ relative vtables. + (`D143115 <https://reviews.llvm.org/D143115>`_) +* RISC-V global pointer relaxation has been implemented. Specify ``--relax-gp`` to enable the linker relaxation. + (`D143673 <https://reviews.llvm.org/D143673>`_) +* The symbol value of ``foo`` is correctly handled when ``--wrap=foo`` and RISC-V linker relaxation are used. + (`D151768 <https://reviews.llvm.org/D151768>`_) +* x86-64 large data sections are now placed away from code sections to alleviate relocation overflow pressure. + (`D150510 <https://reviews.llvm.org/D150510>`_) Breaking changes ---------------- @@ -66,41 +92,30 @@ Breaking changes COFF Improvements ----------------- -* The linker command line entry in ``S_ENVBLOCK`` of the PDB is now stripped - from input files, to align with MSVC behavior. - (`D137723 <https://reviews.llvm.org/D137723>`_) -* Switched from SHA1 to BLAKE3 for PDB type hashing / ``-gcodeview-ghash`` - (`D137101 <https://reviews.llvm.org/D137101>`_) -* Improvements to the PCH.OBJ files handling. Now LLD behaves the same as MSVC - link.exe when merging PCH.OBJ files that don't have the same signature. - (`D136762 <https://reviews.llvm.org/D136762>`_) -* Changed the OrdinalBase for DLLs from 0 to 1, matching the output from - both MS link.exe and GNU ld. (`D134140 <https://reviews.llvm.org/D134140>`_) +* lld-link can now find libraries with relative paths that are relative to + `/libpath`. Before it would only be able to find libraries relative to the + current directory. + I.e. ``lld-link /libpath:c:\relative\root relative\path\my.lib`` where before + we would have to do ``lld-link /libpath:c:\relative\root\relative\path my.lib`` +* lld-link learned -print-search-paths that will print all the paths where it will + search for libraries. +* By default lld-link will now search for libraries in the toolchain directories. + Specifically it will search: + ``<toolchain>/lib``, ``<toolchain>/lib/clang/<version>/lib`` and + ``<toolchain>/lib/clang/<version>/lib/windows``. MinGW Improvements ------------------ -* The lld-specific options ``--guard-cf``, ``--no-guard-cf``, - ``--guard-longjmp`` and ``--no-guard-longjmp`` has been added to allow - enabling Control Flow Guard and long jump hardening. These options are - disabled by default, but enabling ``--guard-cf`` will also enable - ``--guard-longjmp`` unless ``--no-guard-longjmp`` is also specified. - ``--guard-longjmp`` depends on ``--guard-cf`` and cannot be used by itself. - Note that these features require the ``_load_config_used`` symbol to contain - the load config directory and be filled with the required symbols. - (`D132808 <https://reviews.llvm.org/D132808>`_) - -* Pick up libraries named ``<name>.lib`` when linked with ``-l<name>``, even - if ``-static`` has been specified. This fixes conformance to what - GNU ld does. (`D135651 <https://reviews.llvm.org/D135651>`_) - -* Unwinding in Rust code on i386 in MinGW builds has been fixed, by avoiding - to leave out the ``rust_eh_personality`` symbol. - (`D136879 <https://reviews.llvm.org/D136879>`_) - MachO Improvements ------------------ WebAssembly Improvements ------------------------ +Fixes +##### + +* Arm exception index tables (.ARM.exidx sections) are now output + correctly when they are at a non zero offset within their output + section. (`D148033 <https://reviews.llvm.org/D148033>`_) diff --git a/contrib/llvm-project/lld/docs/conf.py b/contrib/llvm-project/lld/docs/conf.py index 95befddf80ea..6f411ed3863d 100644 --- a/contrib/llvm-project/lld/docs/conf.py +++ b/contrib/llvm-project/lld/docs/conf.py @@ -16,92 +16,92 @@ from datetime import date # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. -#sys.path.insert(0, os.path.abspath('.')) +# sys.path.insert(0, os.path.abspath('.')) # -- General configuration ----------------------------------------------------- # If your documentation needs a minimal Sphinx version, state it here. -#needs_sphinx = '1.0' +# needs_sphinx = '1.0' # Add any Sphinx extension module names here, as strings. They can be extensions # coming with Sphinx (named 'sphinx.ext.*') or your custom ones. -extensions = ['sphinx.ext.intersphinx', 'sphinx.ext.todo'] +extensions = ["sphinx.ext.intersphinx", "sphinx.ext.todo"] # Add any paths that contain templates here, relative to this directory. -templates_path = ['_templates'] +templates_path = ["_templates"] # The suffix of source filenames. -source_suffix = '.rst' +source_suffix = ".rst" # The encoding of source files. -#source_encoding = 'utf-8-sig' +# source_encoding = 'utf-8-sig' # The master toctree document. -master_doc = 'index' +master_doc = "index" # General information about the project. -project = u'lld' -copyright = u'2011-%d, LLVM Project' % date.today().year +project = "lld" +copyright = "2011-%d, LLVM Project" % date.today().year # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. -#language = None +# language = None # There are two options for replacing |today|: either, you set today to some # non-false value, then it is used: -#today = '' +# today = '' # Else, today_fmt is used as the format for a strftime call. -today_fmt = '%Y-%m-%d' +today_fmt = "%Y-%m-%d" # List of patterns, relative to source directory, that match files and # directories to ignore when looking for source files. -exclude_patterns = ['_build'] +exclude_patterns = ["_build"] # The reST default role (used for this markup: `text`) to use for all documents. -#default_role = None +# default_role = None # If true, '()' will be appended to :func: etc. cross-reference text. -#add_function_parentheses = True +# add_function_parentheses = True # If true, the current module name will be prepended to all description # unit titles (such as .. function::). -#add_module_names = True +# add_module_names = True # If true, sectionauthor and moduleauthor directives will be shown in the # output. They are ignored by default. show_authors = True # The name of the Pygments (syntax highlighting) style to use. -pygments_style = 'friendly' +pygments_style = "friendly" # A list of ignored prefixes for module index sorting. -#modindex_common_prefix = [] +# modindex_common_prefix = [] # -- Options for HTML output --------------------------------------------------- # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. -html_theme = 'llvm-theme' +html_theme = "llvm-theme" # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the # documentation. -#html_theme_options = {} +# html_theme_options = {} # Add any paths that contain custom themes here, relative to this directory. html_theme_path = ["."] # The name for this set of Sphinx documents. If None, it defaults to # "<project> v<release> documentation". -#html_title = None +# html_title = None # A shorter title for the navigation bar. Default is the same as html_title. -#html_short_title = None +# html_short_title = None # The name of an image file (relative to this directory) to place at the top # of the sidebar. -#html_logo = None +# html_logo = None # If given, this must be the name of an image file (path relative to the # configuration directory) that is the favicon of the docs. Modern browsers use @@ -109,110 +109,104 @@ html_theme_path = ["."] # icon file (.ico), which is 16x16 or 32x32 pixels large. Default: None. The # image file will be copied to the _static directory of the output HTML, but # only if the file does not already exist there. -html_favicon = '_static/favicon.ico' +html_favicon = "_static/favicon.ico" # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". -html_static_path = ['_static'] +html_static_path = ["_static"] # If not '', a 'Last updated on:' timestamp is inserted at every page bottom, # using the given strftime format. -html_last_updated_fmt = '%Y-%m-%d' +html_last_updated_fmt = "%Y-%m-%d" # If true, SmartyPants will be used to convert quotes and dashes to # typographically correct entities. -#html_use_smartypants = True +# html_use_smartypants = True # Custom sidebar templates, maps document names to template names. -html_sidebars = {'index': ['indexsidebar.html']} +html_sidebars = {"index": ["indexsidebar.html"]} # Additional templates that should be rendered to pages, maps page names to # template names. # html_additional_pages = {'index': 'index.html'} # If false, no module index is generated. -#html_domain_indices = True +# html_domain_indices = True # If false, no index is generated. -#html_use_index = True +# html_use_index = True # If true, the index is split into individual pages for each letter. -#html_split_index = False +# html_split_index = False # If true, links to the reST sources are added to the pages. html_show_sourcelink = True # If true, "Created using Sphinx" is shown in the HTML footer. Default is True. -#html_show_sphinx = True +# html_show_sphinx = True # If true, "(C) Copyright ..." is shown in the HTML footer. Default is True. -#html_show_copyright = True +# html_show_copyright = True # If true, an OpenSearch description file will be output, and all pages will # contain a <link> tag referring to it. The value of this option must be the # base URL from which the finished HTML is served. -#html_use_opensearch = '' +# html_use_opensearch = '' # This is the file name suffix for HTML files (e.g. ".xhtml"). -#html_file_suffix = None +# html_file_suffix = None # Output file base name for HTML help builder. -htmlhelp_basename = 'llddoc' +htmlhelp_basename = "llddoc" # -- Options for LaTeX output -------------------------------------------------- latex_elements = { -# The paper size ('letterpaper' or 'a4paper'). -#'papersize': 'letterpaper', - -# The font size ('10pt', '11pt' or '12pt'). -#'pointsize': '10pt', - -# Additional stuff for the LaTeX preamble. -#'preamble': '', + # The paper size ('letterpaper' or 'a4paper'). + #'papersize': 'letterpaper', + # The font size ('10pt', '11pt' or '12pt'). + #'pointsize': '10pt', + # Additional stuff for the LaTeX preamble. + #'preamble': '', } # Grouping the document tree into LaTeX files. List of tuples # (source start file, target name, title, author, documentclass [howto/manual]). latex_documents = [ - ('contents', 'lld.tex', u'lld Documentation', - u'LLVM project', 'manual'), + ("contents", "lld.tex", "lld Documentation", "LLVM project", "manual"), ] # The name of an image file (relative to this directory) to place at the top of # the title page. -#latex_logo = None +# latex_logo = None # For "manual" documents, if this is true, then toplevel headings are parts, # not chapters. -#latex_use_parts = False +# latex_use_parts = False # If true, show page references after internal links. -#latex_show_pagerefs = False +# latex_show_pagerefs = False # If true, show URL addresses after external links. -#latex_show_urls = False +# latex_show_urls = False # Documents to append as an appendix to all manuals. -#latex_appendices = [] +# latex_appendices = [] # If false, no module index is generated. -#latex_domain_indices = True +# latex_domain_indices = True # -- Options for manual page output -------------------------------------------- # One entry per manual page. List of tuples # (source start file, name, description, authors, manual section). -man_pages = [ - ('contents', 'lld', u'lld Documentation', - [u'LLVM project'], 1) -] +man_pages = [("contents", "lld", "lld Documentation", ["LLVM project"], 1)] # If true, show URL addresses after external links. -#man_show_urls = False +# man_show_urls = False # -- Options for Texinfo output ------------------------------------------------ @@ -221,19 +215,25 @@ man_pages = [ # (source start file, target name, title, author, # dir menu entry, description, category) texinfo_documents = [ - ('contents', 'lld', u'lld Documentation', - u'LLVM project', 'lld', 'One line description of project.', - 'Miscellaneous'), + ( + "contents", + "lld", + "lld Documentation", + "LLVM project", + "lld", + "One line description of project.", + "Miscellaneous", + ), ] # Documents to append as an appendix to all manuals. -#texinfo_appendices = [] +# texinfo_appendices = [] # If false, no module index is generated. -#texinfo_domain_indices = True +# texinfo_domain_indices = True # How to display URL addresses: 'footnote', 'no', or 'inline'. -#texinfo_show_urls = 'footnote' +# texinfo_show_urls = 'footnote' # FIXME: Define intersphinx configuration. diff --git a/contrib/llvm-project/lld/docs/index.rst b/contrib/llvm-project/lld/docs/index.rst index ce6320333243..6281b6893cc1 100644 --- a/contrib/llvm-project/lld/docs/index.rst +++ b/contrib/llvm-project/lld/docs/index.rst @@ -22,10 +22,11 @@ Features machine, you can expect that LLD runs more than twice as fast as the GNU gold linker. Your mileage may vary, though. -- It supports various CPUs/ABIs including AArch64, AMDGPU, ARM, Hexagon, MIPS - 32/64 big/little-endian, PowerPC, PowerPC64, RISC-V, SPARC V9, x86-32 and - x86-64. Among these, AArch64, ARM (>= v6), PowerPC, PowerPC64, x86-32 and - x86-64 have production quality. MIPS seems decent too. +- It supports various CPUs/ABIs including AArch64, AMDGPU, ARM, Hexagon, + LoongArch, MIPS 32/64 big/little-endian, PowerPC, PowerPC64, RISC-V, + SPARC V9, x86-32 and x86-64. Among these, AArch64, ARM (>= v4), LoongArch, + PowerPC, PowerPC64, RISC-V, x86-32 and x86-64 have production quality. + MIPS seems decent too. - It is always a cross-linker, meaning that it always supports all the above targets however it was built. In fact, we don't provide a @@ -36,7 +37,7 @@ Features external linkers. All you have to do is to construct object files and command line arguments just like you would do to invoke an external linker and then call the linker's main function, - ``lld::elf::link``, from your code. + ``lld::lldMain``, from your code. - It is small. We are using LLVM libObject library to read from object files, so it is not a completely fair comparison, but as of February diff --git a/contrib/llvm-project/lld/docs/ld.lld.1 b/contrib/llvm-project/lld/docs/ld.lld.1 index edeb7c4bfe37..0a5e4293deda 100644 --- a/contrib/llvm-project/lld/docs/ld.lld.1 +++ b/contrib/llvm-project/lld/docs/ld.lld.1 @@ -4,7 +4,7 @@ .\" .\" This man page documents only lld's ELF linking support, obtained originally .\" from FreeBSD. -.Dd May 12, 2019 +.Dd Jul 25, 2023 .Dt LD.LLD 1 .Os .Sh NAME @@ -27,8 +27,8 @@ It accepts most of the same command line arguments and linker scripts as GNU linkers. .Pp .Nm -currently supports i386, x86-64, ARM, AArch64, PowerPC32, PowerPC64, -MIPS32, MIPS64, RISC-V, AMDGPU, Hexagon and SPARC V9 targets. +currently supports i386, x86-64, ARM, AArch64, LoongArch, PowerPC32, +PowerPC64, MIPS32, MIPS64, RISC-V, AMDGPU, Hexagon and SPARC V9 targets. .Nm acts as a Microsoft link.exe-compatible linker if invoked as .Nm lld-link @@ -88,6 +88,8 @@ Bind default visibility defined function symbols locally for .It Fl Bsymbolic-non-weak-functions Bind default visibility defined STB_GLOBAL function symbols locally for .Fl shared. +.It Fl --be8 +Write a Big Endian ELF File using BE8 format(AArch32 only) .It Fl -build-id Ns = Ns Ar value Generate a build ID note. .Ar value @@ -493,8 +495,25 @@ and .It Fl -pop-state Restore the states saved by .Fl -push-state. +.It Fl --relax-gp +Enable global pointer relaxation for RISC-V. .It Fl -relocatable , Fl r Create relocatable object file. +.It Fl -remap-inputs Ns = Ns Ar from-glob=to-file +Input files matching +.Cm from-glob +are mapped to +.Cm to-file. +Use +.Cm /dev/null +to ignore an input file. +.It Fl -remap-inputs-file Ns = Ns Ar file +Remap input files based on patterns in +.Ar file . +Each line in the remap file is of the format +.Cm from-glob=to-file +or a comment starting with +.Cm # . .It Fl -reproduce Ns = Ns Ar path Write a tar file to .Ar path, @@ -877,6 +896,22 @@ Create a segment. .El .El + +.Sh ENVIRONMENT VARIABLES +.Bl -tag -width LC_CTYPE +.It Ev LLD_REPRODUCE +Create a reproduce tarball with the specified filename. If +.Fl -reproduce +is specified, +.Fl -reproduce +takes precedence. +.It Ev LLD_VERSION +ld.lld creates a section named +.Cm .comment +containing the LLD version string. The version string can be overridden by this environment variable, +which is useful to eliminate differences in the binary caused by LLD version number differences. +.El + .Sh IMPLEMENTATION NOTES .Nm Ap s handing of archive files (those with a |
