llvm-project/lld/ELF
George Rimar 3368643f5e [ELF] - Set sh_info and sh_link for .rela.plt sections.
This is https://bugs.llvm.org/show_bug.cgi?id=37538,

Currently, LLD may set both sh_link and sh_info for
.rela.plt section to zero when we have only .rela.iplt section part used.

ELF spec (https://docs.oracle.com/cd/E19683-01/816-1386/chapter6-94076/index.html)
says that for SHT_REL and SHT_RELA, sh_link references the associated symbol table
and sh_info the "section to which the relocation applies."

When we set the sh_link field, for the regular case we use the .dynsym index.
For .rela.iplt sections, it is unclear what is the associated symbol table,
because R_*_RELATIVE relocations do not use symbol names and we might have no
.dynsym section at all so this patch uses .symtab section index.

Differential revision: https://reviews.llvm.org/D52830

llvm-svn: 344226
2018-10-11 08:25:35 +00:00
..
Arch Calculate an offset only once. NFC. 2018-10-09 20:29:24 +00:00
AArch64ErrataFix.cpp Avoid unnecessary buffer allocation and memcpy for compressed sections. 2018-10-08 16:58:59 +00:00
AArch64ErrataFix.h Consistent (non) use of empty lines in include blocks 2018-02-20 21:53:18 +00:00
Bits.h Move bit operations to a new file, ELF/Bits.h. 2017-10-26 21:37:17 +00:00
CMakeLists.txt Rename GdbIndex.{cpp,h} -> DWARF.{cpp,h}. 2018-09-14 23:51:05 +00:00
CallGraphSort.cpp [LLD][ELF] - Simplify Call-Chain Clustering implementation a bit. 2018-08-28 08:49:40 +00:00
CallGraphSort.h [ELF] Add profile guided section layout 2018-04-17 23:30:05 +00:00
Config.h Introduce a flag to warn when ifunc symbols are used with text relocations. 2018-10-02 20:30:22 +00:00
DWARF.cpp Avoid unnecessary buffer allocation and memcpy for compressed sections. 2018-10-08 16:58:59 +00:00
DWARF.h [LLD] - Do not crash when reporting errors when .debug_line_str (DWARF5) is used 2018-10-03 08:59:46 +00:00
Driver.cpp Avoid unnecessary buffer allocation and memcpy for compressed sections. 2018-10-08 16:58:59 +00:00
Driver.h Add TARGET(foo) linker script directive. 2018-08-06 21:29:41 +00:00
DriverUtils.cpp Eliminate dependency to formatv(). NFC. 2018-10-10 20:29:29 +00:00
EhFrame.cpp Avoid unnecessary buffer allocation and memcpy for compressed sections. 2018-10-08 16:58:59 +00:00
EhFrame.h De-template EhReader. NFC. 2017-10-27 03:14:09 +00:00
Filesystem.cpp s/LLVM_ON_WIN32/_WIN32/, lld 2018-04-10 13:15:21 +00:00
Filesystem.h Add a missing #include. 2017-11-17 08:17:21 +00:00
ICF.cpp Avoid unnecessary buffer allocation and memcpy for compressed sections. 2018-10-08 16:58:59 +00:00
ICF.h Consistent use of header file for ICF and MarkLive 2018-02-20 22:09:59 +00:00
InputFiles.cpp Avoid unnecessary buffer allocation and memcpy for compressed sections. 2018-10-08 16:58:59 +00:00
InputFiles.h [ELF] Read the call graph profile from object files. 2018-10-02 00:17:15 +00:00
InputSection.cpp Attempt to fix ubsan. 2018-10-09 21:41:53 +00:00
InputSection.h Avoid unnecessary buffer allocation and memcpy for compressed sections. 2018-10-08 16:58:59 +00:00
LTO.cpp Simplify. 2018-09-11 14:37:27 +00:00
LTO.h Simplify. 2018-09-11 14:37:27 +00:00
LinkerScript.cpp Reset input section pointers to null on each linker invocation. 2018-09-25 19:26:58 +00:00
LinkerScript.h [ELF] - Eliminate the AssertCommand. 2018-04-25 11:16:31 +00:00
MapFile.cpp Reset input section pointers to null on each linker invocation. 2018-09-25 19:26:58 +00:00
MapFile.h Implement --cref. 2018-03-14 20:29:45 +00:00
MarkLive.cpp Avoid unnecessary buffer allocation and memcpy for compressed sections. 2018-10-08 16:58:59 +00:00
MarkLive.h Consistent use of header file for ICF and MarkLive 2018-02-20 22:09:59 +00:00
Options.td Introduce a flag to warn when ifunc symbols are used with text relocations. 2018-10-02 20:30:22 +00:00
OutputSections.cpp Reset input section pointers to null on each linker invocation. 2018-09-25 19:26:58 +00:00
OutputSections.h [ELF] - Implement linker script OVERLAYs. 2018-06-27 08:08:12 +00:00
README.md Update the documents of the new LLD. 2016-03-12 06:06:40 +00:00
Relocations.cpp Avoid unnecessary buffer allocation and memcpy for compressed sections. 2018-10-08 16:58:59 +00:00
Relocations.h [ELF][HEXAGON] Add support for GOT relocations. 2018-10-04 14:54:17 +00:00
ScriptLexer.cpp [LLD][ELD] - Do not reject INFO output section type when used with a start address. 2018-08-28 08:39:21 +00:00
ScriptLexer.h [LLD][ELD] - Do not reject INFO output section type when used with a start address. 2018-08-28 08:39:21 +00:00
ScriptParser.cpp [LLD][ELD] - Do not reject INFO output section type when used with a start address. 2018-08-28 08:39:21 +00:00
ScriptParser.h [ELF] Support expressions with -defsym option 2017-11-04 02:03:58 +00:00
SymbolTable.cpp Make a member function private and rename it to avoid function overloading. 2018-10-10 22:49:29 +00:00
SymbolTable.h Make a member function private and rename it to avoid function overloading. 2018-10-10 22:49:29 +00:00
Symbols.cpp [ELF] Don't warn on undefined symbols if UnresolvedPolicy::Ignore is used 2018-10-10 22:48:57 +00:00
Symbols.h Simplify. NFC. 2018-10-09 20:16:16 +00:00
SyntheticSections.cpp [ELF] - Set sh_info and sh_link for .rela.plt sections. 2018-10-11 08:25:35 +00:00
SyntheticSections.h Avoid unnecessary buffer allocation and memcpy for compressed sections. 2018-10-08 16:58:59 +00:00
Target.cpp Support RISC-V 2018-08-09 17:59:56 +00:00
Target.h [ELF] - Do not fail on R_*_NONE relocations when parsing the debug info. 2018-09-26 08:11:34 +00:00
Thunks.cpp [ELF] [ARM] Don't mix 'ip' and 'r12' as names for the same register in comments. NFC. 2018-08-31 08:03:33 +00:00
Thunks.h ELF: Allow thunks to change size. NFCI. 2018-03-29 22:32:13 +00:00
Writer.cpp [ELF] llvm::sort(C.begin(), C.end(), ...) -> llvm::sort(C, ...) 2018-09-26 20:54:42 +00:00
Writer.h ELF: Do not ICF two sections with different output sections. 2018-05-23 01:58:43 +00:00

README.md

See docs/NewLLD.rst