hanchenye-llvm-project/lld/ELF
Nico Weber cf1a11ded2 Make joined instances of JoinedOrSeparate flags point to the unaliased args, like all other arg types do
This fixes an 8-year-old regression. r105763 made it so that aliases
always refer to the unaliased option – but it missed the "joined" branch
of JoinedOrSeparate flags. (r162231 then made the Args classes
non-virtual, and r169344 moved them from clang to llvm.)

Back then, there was no JoinedOrSeparate flag that was an alias, so it
wasn't observable. Now /U in CLCompatOptions is a JoinedOrSeparate alias
in clang, and warn_slash_u_filename incorrectly used the aliased arg id
(using the unaliased one isn't really a regression since that warning
checks if the undefined macro contains slash or backslash and only then
emits the warning – and no valid use will pass "-Ufoo/bar" or similar).

Also, lld has many JoinedOrSeparate aliases, and due to this bug it had
to explicitly call `getUnaliasedOption()` in a bunch of places, even
though that shouldn't be necessary by design. After this fix in Option,
these calls really don't have an effect any more, so remove them.

No intended behavior change.

(I accidentally fixed this bug while working on PR29106 but then
wondered why the warn_slash_u_filename broke. When I figured it out, I
thought it would make sense to land this in a separate commit.)

Differential Revision: https://reviews.llvm.org/D64156

llvm-svn: 365186
2019-07-05 11:45:24 +00:00
..
Arch [ELF][RISCV] Support GD/LD/IE/LE TLS models 2019-07-01 17:12:26 +00:00
AArch64ErrataFix.cpp Use llvm::stable_sort 2019-04-23 02:42:06 +00:00
AArch64ErrataFix.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
CMakeLists.txt Fail early if an output file is not writable 2019-03-11 16:30:55 +00:00
CallGraphSort.cpp Use llvm::stable_sort 2019-04-23 02:42:06 +00:00
CallGraphSort.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
Config.h [Remarks] Extend -fsave-optimization-record to specify the format 2019-06-17 16:06:00 +00:00
DWARF.cpp Avoid identifiers that are different only in case. NFC. 2019-07-03 06:11:50 +00:00
DWARF.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
Driver.cpp Make joined instances of JoinedOrSeparate flags point to the unaliased args, like all other arg types do 2019-07-05 11:45:24 +00:00
Driver.h Move SymbolTable::addCombinedLTOObject() to LinkerDriver. 2019-05-23 09:26:27 +00:00
DriverUtils.cpp Make joined instances of JoinedOrSeparate flags point to the unaliased args, like all other arg types do 2019-07-05 11:45:24 +00:00
EhFrame.cpp [ELF][MachO][wasm] Simplify range-style std::find{,_if} with STLExtras.h utilities. NFC 2019-03-29 16:21:16 +00:00
EhFrame.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
ICF.cpp ELF: Add basic partition data structures and behaviours. 2019-05-29 03:55:20 +00:00
ICF.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
InputFiles.cpp Avoid identifiers that are different only in case. NFC. 2019-07-03 06:11:50 +00:00
InputFiles.h [PPC32] Improve the 32-bit PowerPC port 2019-06-06 17:03:00 +00:00
InputSection.cpp [ELF][RISCV] Error on R_RISCV_PCREL_LO12_[IS] that point to absolute symbols 2019-07-03 15:38:59 +00:00
InputSection.h ELF: Create synthetic sections for loadable partitions. 2019-06-07 17:57:58 +00:00
LTO.cpp [Remarks] Extend -fsave-optimization-record to specify the format 2019-06-17 16:06:00 +00:00
LTO.h [ELF] Reorder BitcodeFiles.empty() to call thinLTOCreateEmptyIndexFiles() in only one place 2019-05-07 10:40:26 +00:00
LinkerScript.cpp ELF: Create synthetic sections for loadable partitions. 2019-06-07 17:57:58 +00:00
LinkerScript.h [ELF] Deleted unused forward declarations. NFC 2019-05-24 09:25:47 +00:00
MapFile.cpp ELF: Add basic partition data structures and behaviours. 2019-05-29 03:55:20 +00:00
MapFile.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MarkLive.cpp ELF: Add basic partition data structures and behaviours. 2019-05-29 03:55:20 +00:00
MarkLive.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
Options.td [Remarks] Extend -fsave-optimization-record to specify the format 2019-06-17 16:06:00 +00:00
OutputSections.cpp ELF: Introduce a separate bit for tracking whether an output section has ever had an input section added to it. NFCI. 2019-06-03 20:14:25 +00:00
OutputSections.h ELF: Introduce a separate bit for tracking whether an output section has ever had an input section added to it. NFCI. 2019-06-03 20:14:25 +00:00
README.md
Relocations.cpp Avoid identifiers that are different only in case. NFC. 2019-07-03 06:11:50 +00:00
Relocations.h lld/elf: Deduplicate undefined symbol diagnostics 2019-06-20 18:25:57 +00:00
ScriptLexer.cpp [LLD][ELF] - Linkerscript: add a support for expressions for section's filling 2019-07-04 14:17:31 +00:00
ScriptLexer.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
ScriptParser.cpp [LLD][ELF] - Linkerscript: add a support for expressions for section's filling 2019-07-04 14:17:31 +00:00
ScriptParser.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SymbolTable.cpp ELF: Add basic partition data structures and behaviours. 2019-05-29 03:55:20 +00:00
SymbolTable.h Use SymbolTable::insert() to implement --trace. 2019-05-28 06:33:06 +00:00
Symbols.cpp [ELF] resolveUndefined: ignore undefined symbols in SharedFile for Undefined and SharedSymbol 2019-07-04 10:38:04 +00:00
Symbols.h [ELF] Only allow the binding of SharedSymbol to change for the first undef ref 2019-07-02 11:37:21 +00:00
SyntheticSections.cpp [ELF] Allow placing non-string SHF_MERGE sections with different alignments into the same MergeSyntheticSection 2019-07-04 13:33:27 +00:00
SyntheticSections.h [ELF][RISCV] Create dummy .sdata for __global_pointer$ if .sdata does not exist 2019-06-14 02:14:53 +00:00
Target.cpp [PPC64] toc-indirect to toc-relative relaxation 2019-05-07 04:26:05 +00:00
Target.h [ELF][PPC][X86] Use [-2**(n-1), 2**n) to check overflows for R_PPC_ADDR16, R_PPC64_ADDR{16,32}, R_X86_64_{8,16} 2019-06-24 05:37:20 +00:00
Thunks.cpp Avoid identifiers that are different only in case. NFC. 2019-07-03 07:08:27 +00:00
Thunks.h [PPC32] Improve the 32-bit PowerPC port 2019-06-06 17:03:00 +00:00
Writer.cpp lld/elf: Deduplicate undefined symbol diagnostics 2019-06-20 18:25:57 +00:00
Writer.h [ELF] Delete unused forward declarations and unused DynamicReloc::getInputSec(). NFC 2019-03-15 07:16:39 +00:00

README.md

See docs/NewLLD.rst