|
Revision tags: llvmorg-20.1.0, llvmorg-20.1.0-rc3, llvmorg-20.1.0-rc2, llvmorg-20.1.0-rc1, llvmorg-21-init, llvmorg-19.1.7, llvmorg-19.1.6, llvmorg-19.1.5, llvmorg-19.1.4, llvmorg-19.1.3, llvmorg-19.1.2, llvmorg-19.1.1, llvmorg-19.1.0, llvmorg-19.1.0-rc4, llvmorg-19.1.0-rc3, llvmorg-19.1.0-rc2, llvmorg-19.1.0-rc1, llvmorg-20-init, llvmorg-18.1.8, llvmorg-18.1.7, llvmorg-18.1.6, llvmorg-18.1.5, llvmorg-18.1.4, llvmorg-18.1.3, llvmorg-18.1.2, llvmorg-18.1.1, llvmorg-18.1.0, llvmorg-18.1.0-rc4, llvmorg-18.1.0-rc3, llvmorg-18.1.0-rc2, llvmorg-18.1.0-rc1, llvmorg-19-init, llvmorg-17.0.6, llvmorg-17.0.5, llvmorg-17.0.4, llvmorg-17.0.3, llvmorg-17.0.2, llvmorg-17.0.1, llvmorg-17.0.0, llvmorg-17.0.0-rc4, llvmorg-17.0.0-rc3, llvmorg-17.0.0-rc2, llvmorg-17.0.0-rc1, llvmorg-18-init, llvmorg-16.0.6, llvmorg-16.0.5, llvmorg-16.0.4, llvmorg-16.0.3, llvmorg-16.0.2, llvmorg-16.0.1, llvmorg-16.0.0, llvmorg-16.0.0-rc4, llvmorg-16.0.0-rc3, llvmorg-16.0.0-rc2, llvmorg-16.0.0-rc1, llvmorg-17-init, llvmorg-15.0.7, llvmorg-15.0.6, llvmorg-15.0.5, llvmorg-15.0.4, llvmorg-15.0.3, llvmorg-15.0.2, llvmorg-15.0.1, llvmorg-15.0.0, llvmorg-15.0.0-rc3, llvmorg-15.0.0-rc2, llvmorg-15.0.0-rc1, llvmorg-16-init, llvmorg-14.0.6, llvmorg-14.0.5, llvmorg-14.0.4, llvmorg-14.0.3, llvmorg-14.0.2, llvmorg-14.0.1, llvmorg-14.0.0, llvmorg-14.0.0-rc4, llvmorg-14.0.0-rc3, llvmorg-14.0.0-rc2 |
|
| #
c5fb05f6 |
| 16-Feb-2022 |
Peter Kasting <[email protected]> |
Reland: Make lld-link work in a non-MSVC shell, add /winsysroot:
This relands 73e585e44d (and 0574b5fc657451), with a fix for the failing test (by using Optional<StringRef>s instead of making String
Reland: Make lld-link work in a non-MSVC shell, add /winsysroot:
This relands 73e585e44d (and 0574b5fc657451), with a fix for the failing test (by using Optional<StringRef>s instead of making StringRef::empty() mean absence of value).
Differential Revision: https://reviews.llvm.org/D118070
show more ...
|
| #
437d4e01 |
| 12-Feb-2022 |
Douglas Yung <[email protected]> |
Revert "try to fix windows build after 73e585e44d" and Revert "Reland "[lld/coff] Make lld-link work in a non-MSVC shell, add /winsysroot:""
This reverts commit 0574b5fc657451c9d13d3f6d8fe14ea15c23a
Revert "try to fix windows build after 73e585e44d" and Revert "Reland "[lld/coff] Make lld-link work in a non-MSVC shell, add /winsysroot:""
This reverts commit 0574b5fc657451c9d13d3f6d8fe14ea15c23a681 and 73e585e44d68cf77e2e3274e98c9615156a7d909.
This change is causing the test Driver/cl-options.c to fail on Windows buildbots. https://lab.llvm.org/staging/#/builders/204/builds/1343
show more ...
|
| #
73e585e4 |
| 11-Feb-2022 |
Nico Weber <[email protected]> |
Reland "[lld/coff] Make lld-link work in a non-MSVC shell, add /winsysroot:"
This relands commit b3b2538df100ec, except that the new files in Support are instead in a new library WindowsDriver.
|
| #
baac665a |
| 11-Feb-2022 |
Adrian Prantl <[email protected]> |
Revert "[lld/coff] Make lld-link work in a non-MSVC shell, add /winsysroot:"
This reverts commit b3b2538df100ec7f6587b0ee70819a3c8ee2c27e, it introduced a cycklic module depenency that broke the -DL
Revert "[lld/coff] Make lld-link work in a non-MSVC shell, add /winsysroot:"
This reverts commit b3b2538df100ec7f6587b0ee70819a3c8ee2c27e, it introduced a cycklic module depenency that broke the -DLLVM_ENABLE_MODULES=1 build.
show more ...
|
| #
b3b2538d |
| 11-Feb-2022 |
Peter Kasting <[email protected]> |
[lld/coff] Make lld-link work in a non-MSVC shell, add /winsysroot:
Makes lld-link work in a non-MSVC shell by autodetecting MSVC toolchain. Also adds support for /winsysroot and a few other switche
[lld/coff] Make lld-link work in a non-MSVC shell, add /winsysroot:
Makes lld-link work in a non-MSVC shell by autodetecting MSVC toolchain. Also adds support for /winsysroot and a few other switches.
All this is done by refactoring to share code with clang-cl's existing support for the same.
Differential Revision: https://reviews.llvm.org/D118070
show more ...
|
|
Revision tags: llvmorg-14.0.0-rc1, llvmorg-15-init, llvmorg-13.0.1, llvmorg-13.0.1-rc3 |
|
| #
83d59e05 |
| 20-Jan-2022 |
Alexandre Ganea <[email protected]> |
Re-land [LLD] Remove global state in lldCommon
Move all variables at file-scope or function-static-scope into a hosting structure (lld::CommonLinkerContext) that lives at lldMain()-scope. Drivers wi
Re-land [LLD] Remove global state in lldCommon
Move all variables at file-scope or function-static-scope into a hosting structure (lld::CommonLinkerContext) that lives at lldMain()-scope. Drivers will inherit from this structure and add their own global state, in the same way as for the existing COFFLinkerContext.
See discussion in https://lists.llvm.org/pipermail/llvm-dev/2021-June/151184.html
The previous land f860fe362282ed69b9d4503a20e5d20b9a041189 caused issues in https://lab.llvm.org/buildbot/#/builders/123/builds/8383, fixed by 22ee510dac9440a74b2e5b3fe3ff13ccdbf55af3.
Differential Revision: https://reviews.llvm.org/D108850
show more ...
|
| #
e6b15394 |
| 16-Jan-2022 |
Alexandre Ganea <[email protected]> |
Revert [LLD] Remove global state in lldCommon
It seems to be causing issues on https://lab.llvm.org/buildbot/#/builders/123/builds/8383
|
| #
f860fe36 |
| 16-Jan-2022 |
Alexandre Ganea <[email protected]> |
[LLD] Remove global state in lldCommon
Move all variables at file-scope or function-static-scope into a hosting structure (lld::CommonLinkerContext) that lives at lldMain()-scope. Drivers will inher
[LLD] Remove global state in lldCommon
Move all variables at file-scope or function-static-scope into a hosting structure (lld::CommonLinkerContext) that lives at lldMain()-scope. Drivers will inherit from this structure and add their own global state, in the same way as for the existing COFFLinkerContext.
See discussion in https://lists.llvm.org/pipermail/llvm-dev/2021-June/151184.html
Differential Revision: https://reviews.llvm.org/D108850
show more ...
|
|
Revision tags: llvmorg-13.0.1-rc2 |
|
| #
d496abbe |
| 04-Jan-2022 |
Fangrui Song <[email protected]> |
[lld-link] Replace LazyObjFile with lazy ObjFile/BitcodeFile
Similar to ELF 3a5fb57393c3bc77be9e7afc2ec9d4ec3c9bbf70.
* previously when a LazyObjFile was extracted, a new ObjFile/BitcodeFile was cr
[lld-link] Replace LazyObjFile with lazy ObjFile/BitcodeFile
Similar to ELF 3a5fb57393c3bc77be9e7afc2ec9d4ec3c9bbf70.
* previously when a LazyObjFile was extracted, a new ObjFile/BitcodeFile was created; now the file is reused, just with `lazy` cleared * avoid the confusing transfer of `symbols` from LazyObjFile to the new file * simpler code, smaller executable (5200+ bytes smaller on x86-64) * make eager parsing feasible (for parallel section/symbol table initialization)
Reviewed By: aganea, rnk
Differential Revision: https://reviews.llvm.org/D116434
show more ...
|
| #
fb6b103d |
| 13-Dec-2021 |
Noah Shutty <[email protected]> |
[lld] Replace Symbolize.h with DIContext.h in lld's COFF lib
lld only needs DIContext.h which it gets through Symbolize.h -> SymbolizableModule.h -> DIContext.h. This replaces it with a direct inclu
[lld] Replace Symbolize.h with DIContext.h in lld's COFF lib
lld only needs DIContext.h which it gets through Symbolize.h -> SymbolizableModule.h -> DIContext.h. This replaces it with a direct include of DIContext.h to avoid any confusion and pulling in unnecessary headers.
Reviewed By: phosek
Differential Revision: https://reviews.llvm.org/D115659
show more ...
|
|
Revision tags: llvmorg-13.0.1-rc1 |
|
| #
4da38c14 |
| 28-Oct-2021 |
Sam Clegg <[email protected]> |
[lld] Rename addCombinedLTOObjects to match ELF driver. NFC
This function was renamed in https://reviews.llvm.org/D62291. The new name seems more accurate and also its good to maintain some consiste
[lld] Rename addCombinedLTOObjects to match ELF driver. NFC
This function was renamed in https://reviews.llvm.org/D62291. The new name seems more accurate and also its good to maintain some consistency between these methods in the different drivers.
Differential Revision: https://reviews.llvm.org/D112719
show more ...
|
| #
f09dce56 |
| 12-Oct-2021 |
Nico Weber <[email protected]> |
[lld] fix typos to cycle bots
|
|
Revision tags: llvmorg-13.0.0, llvmorg-13.0.0-rc4 |
|
| #
6f7483b1 |
| 16-Sep-2021 |
Amy Huang <[email protected]> |
Reland "[LLD] Remove global state in lld/COFF" after fixing asan and msan test failures
Original commit description:
[LLD] Remove global state in lld/COFF
This patch removes globals from the l
Reland "[LLD] Remove global state in lld/COFF" after fixing asan and msan test failures
Original commit description:
[LLD] Remove global state in lld/COFF
This patch removes globals from the lldCOFF library, by moving globals into a context class (COFFLinkingContext) and passing it around wherever it's needed.
See https://lists.llvm.org/pipermail/llvm-dev/2021-June/151184.html for context about removing globals from LLD.
I also haven't moved the `driver` or `config` variables yet.
Differential Revision: https://reviews.llvm.org/D109634
This reverts commit a2fd05ada9030eab2258fff25e77a05adccae128.
Original commits were b4fa71eed34d967195514fe9b0a5211fca2bc5bc and e03c7e367adb8f228332e3c2ef8f45484597b719.
show more ...
|
| #
a2fd05ad |
| 16-Sep-2021 |
Amy Huang <[email protected]> |
Temporarily revert "[LLD] Remove global state in lld/COFF" and "[lld] Add test to check for timer output"
Seems to be causing a number of asan test failures.
This reverts commit b4fa71eed34d9671955
Temporarily revert "[LLD] Remove global state in lld/COFF" and "[lld] Add test to check for timer output"
Seems to be causing a number of asan test failures.
This reverts commit b4fa71eed34d967195514fe9b0a5211fca2bc5bc and e03c7e367adb8f228332e3c2ef8f45484597b719.
show more ...
|
|
Revision tags: llvmorg-13.0.0-rc3 |
|
| #
b4fa71ee |
| 03-Sep-2021 |
Amy Huang <[email protected]> |
[LLD] Remove global state in lld/COFF
This patch removes globals from the lldCOFF library, by moving globals into a context class (COFFLinkingContext) and passing it around wherever it's needed.
Se
[LLD] Remove global state in lld/COFF
This patch removes globals from the lldCOFF library, by moving globals into a context class (COFFLinkingContext) and passing it around wherever it's needed.
See https://lists.llvm.org/pipermail/llvm-dev/2021-June/151184.html for context about removing globals from LLD.
I also haven't moved the `driver` or `config` variables yet.
Differential Revision: https://reviews.llvm.org/D109634
show more ...
|
|
Revision tags: llvmorg-13.0.0-rc2, llvmorg-13.0.0-rc1, llvmorg-14-init, llvmorg-12.0.1, llvmorg-12.0.1-rc4, llvmorg-12.0.1-rc3 |
|
| #
ce211c50 |
| 17-Jun-2021 |
Martin Storsjö <[email protected]> |
[LLD] [COFF] Fix up missing stdcall decorations in MinGW mode
If linking directly against a DLL without an import library, the DLL export symbols might not contain stdcall decorations.
If we have a
[LLD] [COFF] Fix up missing stdcall decorations in MinGW mode
If linking directly against a DLL without an import library, the DLL export symbols might not contain stdcall decorations.
If we have an undefined symbol with decoration, and we happen to have a matching undecorated symbol (which either is lazy and can be loaded, or already defined), then alias it against that instead.
This matches what's done in reverse, when we have a def file declaring to export a symbol without decoration, but we only have a defined decorated symbol. In that case we do a fuzzy match (SymbolTable::findMangle). This case is more straightforward; if we have a decorated undefined symbol, just strip the decoration and look for the corresponding undecorated symbol name.
Add warnings and options for either silencing the warning or disabling the whole feature, corresponding to how ld.bfd does it.
(This feature works for any symbol decoration mismatch, not only when linking against a DLL directly; ld.bfd also tolerates it anywhere, and also fixes up mismatches in the other direction, like SymbolTable::findMangle, for any symbol, not only exports. But in practice, at least for lld, it would primarily end up used for linking against DLLs.)
Differential Revision: https://reviews.llvm.org/D104532
show more ...
|
|
Revision tags: llvmorg-12.0.1-rc2 |
|
| #
a9ff1ce1 |
| 16-Jun-2021 |
Martin Storsjö <[email protected]> |
[LLD] [COFF] Support linking directly against DLLs in MinGW mode
GNU ld.bfd supports linking directly against DLLs without using an import library, and some projects have picked up on this habit. (T
[LLD] [COFF] Support linking directly against DLLs in MinGW mode
GNU ld.bfd supports linking directly against DLLs without using an import library, and some projects have picked up on this habit. (There's no one single unsurmountable issue with using import libraries, but this is a regularly surfacing missing feature.)
As long as one is linking by name (instead of by ordinal), the DLL export table contains most of the information needed. (One can inspect what section a symbol points at, to see if it's a function or data symbol. The practical implementation of this loops over all sections for each symbol, but as long as they're not very many, that should hopefully be tolerable performance wise.)
One exception where the information in the DLL isn't entirely enough is on i386 with stdcall functions; depending on how they're done, the exported function name can be a plain undecorated name, while the import library would contain the full decorated symbol name. This issue is addressed separately in a different patch.
This is implemented mimicing the structure of a regular import library, with one InputFile corresponding to the static archive that just adds lazy symbols, which then are fetched when they are needed. When such a symbol is fetched, we synthesize a coff_import_header structure in memory and create a regular ImportFile out of it.
The implementation could be even smaller by just creating ImportFiles for every symbol available immediately, but that would have the drawback of actually ending up importing all symbols unless running with GC enabled (and mingw mode defaults to having it disabled for historical reasons).
Differential Revision: https://reviews.llvm.org/D104530
show more ...
|
|
Revision tags: llvmorg-12.0.1-rc1, llvmorg-12.0.0, llvmorg-12.0.0-rc5, llvmorg-12.0.0-rc4, llvmorg-12.0.0-rc3, llvmorg-12.0.0-rc2, llvmorg-11.1.0, llvmorg-11.1.0-rc3, llvmorg-12.0.0-rc1, llvmorg-13-init, llvmorg-11.1.0-rc2, llvmorg-11.1.0-rc1, llvmorg-11.0.1, llvmorg-11.0.1-rc2, llvmorg-11.0.1-rc1, llvmorg-11.0.0, llvmorg-11.0.0-rc6 |
|
| #
3785a413 |
| 06-Oct-2020 |
Martin Storsjö <[email protected]> |
Reapply [LLD] [COFF] Implement a GNU/ELF like -wrap option
Add a simple forwarding option in the MinGW frontend, and implement the private -wrap option in the COFF linker.
The feature in lld-link i
Reapply [LLD] [COFF] Implement a GNU/ELF like -wrap option
Add a simple forwarding option in the MinGW frontend, and implement the private -wrap option in the COFF linker.
The feature in lld-link isn't gated by the -lldmingw option, but the option is left as a private, undocumented option primarily used by the MinGW driver.
The implementation is significantly based on the support for --wrap in the ELF linker, but many small nuance details are different between the ELF and COFF linkers, ending up with more than a few implementation differences.
This fixes https://bugs.llvm.org/show_bug.cgi?id=47384.
Differential Revision: https://reviews.llvm.org/D89004
Reapplied with the bitfield member canInline fixed so it doesn't break builds targeting windows.
show more ...
|
| #
3d338f68 |
| 15-Oct-2020 |
Arthur Eubanks <[email protected]> |
Revert "[LLD] [COFF] Implement a GNU/ELF like -wrap option"
This reverts commit a012c704b5e5b60f9d2a7304d27cbc84a3619571.
Breaks Windows builds.
C:\src\llvm-mint\lld\COFF\Symbols.cpp(26,1): error:
Revert "[LLD] [COFF] Implement a GNU/ELF like -wrap option"
This reverts commit a012c704b5e5b60f9d2a7304d27cbc84a3619571.
Breaks Windows builds.
C:\src\llvm-mint\lld\COFF\Symbols.cpp(26,1): error: static_assert failed due to requirement 'sizeof(lld::coff::SymbolUnion) <= 48' "symbols should be optimized for memory usage" static_assert(sizeof(SymbolUnion) <= 48,
show more ...
|
| #
a012c704 |
| 06-Oct-2020 |
Martin Storsjö <[email protected]> |
[LLD] [COFF] Implement a GNU/ELF like -wrap option
Add a simple forwarding option in the MinGW frontend, and implement the private -wrap option in the COFF linker.
The feature in lld-link isn't gat
[LLD] [COFF] Implement a GNU/ELF like -wrap option
Add a simple forwarding option in the MinGW frontend, and implement the private -wrap option in the COFF linker.
The feature in lld-link isn't gated by the -lldmingw option, but the option is left as a private, undocumented option primarily used by the MinGW driver.
The implementation is significantly based on the support for --wrap in the ELF linker, but many small nuance details are different between the ELF and COFF linkers, ending up with more than a few implementation differences.
This fixes https://bugs.llvm.org/show_bug.cgi?id=47384.
Differential Revision: https://reviews.llvm.org/D89004
show more ...
|
| #
9803cf57 |
| 07-Oct-2020 |
Martin Storsjö <[email protected]> |
[LLD] [COFF] Fix a condition that was missed in 7f0e6c31c255. NFC.
This should fix cases when e.g. auto import is enabled without mingw mode in total being enabled.
Differential Revision: https://r
[LLD] [COFF] Fix a condition that was missed in 7f0e6c31c255. NFC.
This should fix cases when e.g. auto import is enabled without mingw mode in total being enabled.
Differential Revision: https://reviews.llvm.org/D89006
show more ...
|
|
Revision tags: llvmorg-11.0.0-rc5, llvmorg-11.0.0-rc4, llvmorg-11.0.0-rc3, llvmorg-11.0.0-rc2, llvmorg-11.0.0-rc1, llvmorg-12-init |
|
| #
3a108ab2 |
| 09-Jul-2020 |
Sylvain Audi <[email protected]> |
[LLD][COFF] Skip computation of the undefined symbols references that are not shown
The "undefined symbol" error message from lld-link displays up to 3 references to that symbol, and the number of e
[LLD][COFF] Skip computation of the undefined symbols references that are not shown
The "undefined symbol" error message from lld-link displays up to 3 references to that symbol, and the number of extra references not shown.
This patch removes the computation of the strings for those extra references.
It fixes a freeze of lld-link we accidentally encountered when activating asan on a large project, without linking with the asan library. In that case, __asan_report_load8 was referenced more than 2 million times, causing the computation of that many display strings, of which only 3 were used.
Differential Revision: https://reviews.llvm.org/D83510
show more ...
|
|
Revision tags: llvmorg-10.0.1, llvmorg-10.0.1-rc4, llvmorg-10.0.1-rc3, llvmorg-10.0.1-rc2, llvmorg-10.0.1-rc1 |
|
| #
7f0e6c31 |
| 25-Apr-2020 |
Martin Storsjö <[email protected]> |
[LLD] [COFF] Add options for disabling auto import and runtime pseudo relocs
Allow disabling either the full auto import feature, or just forbidding the cases that require runtime fixups.
As long a
[LLD] [COFF] Add options for disabling auto import and runtime pseudo relocs
Allow disabling either the full auto import feature, or just forbidding the cases that require runtime fixups.
As long as all auto imported variables are referenced from separate .refptr$<name> sections, we can alias them on top of the IAT entries and don't actually need any runtime fixups via pseudo relocations. LLVM generates references to variables in .refptr stubs, if it isn't known that the variable for sure is defined in the same object module. Runtime pseudo relocs are needed if the addresses of auto imported variables are used in constant initializers though.
Fixing up runtime pseudo relocations requires the use of VirtualProtect (which is disallowed in WinStore/UWP apps) or VirtualProtectFromApp. To allow any risk of ambiguity, allow rejecting cases that would require this at the linker stage.
This adds support for the --disable-runtime-pseudo-reloc and --disable-auto-import options in the MinGW driver (matching GNU ld.bfd) with corresponding lld private options in the COFF driver.
Differential Revision: https://reviews.llvm.org/D78923
show more ...
|
| #
91a6bfed |
| 15-Apr-2020 |
Reid Kleckner <[email protected]> |
[COFF] Assign unique identifiers to ObjFiles from LTO
Use the unique filenames that are used when /lldsavetemps is passed. After this change, module names for LTO blobs in PDBs will be unique. Visua
[COFF] Assign unique identifiers to ObjFiles from LTO
Use the unique filenames that are used when /lldsavetemps is passed. After this change, module names for LTO blobs in PDBs will be unique. Visual Studio and probably other debuggers expect module names to be unique.
Revert some changes from 1e0b158db (2017) that are no longer necessary after removing MSVC LTO support.
Reviewed By: MaskRay
Differential Revision: https://reviews.llvm.org/D78221
show more ...
|
| #
20eb719f |
| 29-Mar-2020 |
Nico Weber <[email protected]> |
lld: Reduce number of references to undefined printed from 10 to 3.
As of a while ago, lld groups all undefined references to a single symbol in a single diagnostic. Back then, I made it so that we
lld: Reduce number of references to undefined printed from 10 to 3.
As of a while ago, lld groups all undefined references to a single symbol in a single diagnostic. Back then, I made it so that we print up to 10 references to each undefined symbol.
Having used this for a while, I never wished there were more references, but I sometimes found that this can print a lot of output. lld prints up to 10 diagnostics by default, and if each has 10 references (which I've seen in practice), and each undefined symbol produces 2 (possibly very long) lines of output, that's over 200 lines of error output.
Let's try it with just 3 references for a while and see how that feels in practice.
Differential Revision: https://reviews.llvm.org/D77017
show more ...
|