llvm-project/lld/ELF
Fangrui Song 1092fc9057 [ELF] Allow sh_entsize to be unrelated to sh_addralign and not a power of 2
Summary:
This implements Rui Ueyama's idea in PR39044.
I've checked that ld.bfd and gold do not have the power-of-2 requirement
and do not require sh_entsize to be a multiple of sh_align.

Now on the updated test merge-entsize.s, all the 3 linkers happily
create .rodata that is not 3-byte aligned.

This has a use case in Linux arch/x86/crypto/sha512-avx2-asm.S
It uses sh_entsize of 640, which is not a power of 2.
See https://github.com/ClangBuiltLinux/linux/issues/417

Reviewers: ruiu, espindola

Reviewed By: ruiu

Subscribers: nickdesaulniers, E5ten, emaste, arichardson, llvm-commits

Tags: #llvm

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

llvm-svn: 356428
2019-03-18 23:49:18 +00:00
..
Arch [mips] Create LA25 thunks for MIPS R6 code 2019-02-19 11:11:12 +00:00
AArch64ErrataFix.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +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 Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +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 Reland "[Remarks] Add -foptimization-record-passes to filter remark emission" 2019-03-12 21:22:27 +00:00
DWARF.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +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 [ELF] De-virtualize findOrphanPos, excludeLibs and handleARMTlsRelocation 2019-03-17 13:53:42 +00:00
Driver.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
DriverUtils.cpp Remove a function from header and move the implementation to a .cpp file. NFC. 2019-02-22 23:59:43 +00:00
EhFrame.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +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 COFF, ELF: ICF: Perform 2 rounds of relocation hash propagation. 2019-01-22 23:54:49 +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 [ELF] Print a better error for an archive containing a non-ELF file. 2019-03-12 01:24:39 +00:00
InputFiles.h LLD/AMDGPU: Preserve ABI version during linking ELF for AMDGPU 2019-02-14 23:59:44 +00:00
InputSection.cpp ELF: Use bump pointer allocator for uncompressed section buffers. NFCI. 2019-03-12 20:32:30 +00:00
InputSection.h ELF: Use bump pointer allocator for uncompressed section buffers. NFCI. 2019-03-12 20:32:30 +00:00
LTO.cpp Reland "[Remarks] Add -foptimization-record-passes to filter remark emission" 2019-03-12 21:22:27 +00:00
LTO.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
LinkerScript.cpp ELF: Simplify. NFCI. 2019-03-12 19:19:23 +00:00
LinkerScript.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MapFile.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +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] De-template wrapSymbols, isReserved and addGotEntry. NFC 2019-03-15 06:58:23 +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 Reland "[Remarks] Add -foptimization-record-passes to filter remark emission" 2019-03-12 21:22:27 +00:00
OutputSections.cpp ELF: Remove dead code. NFCI. 2019-03-12 02:18:03 +00:00
OutputSections.h [ELF] Delete unused forward declarations and unused DynamicReloc::getInputSec(). NFC 2019-03-15 07:16:39 +00:00
README.md Update the documents of the new LLD. 2016-03-12 06:06:40 +00:00
Relocations.cpp [ELF] De-virtualize findOrphanPos, excludeLibs and handleARMTlsRelocation 2019-03-17 13:53:42 +00:00
Relocations.h Sort enum members so that arch-dependent members are at the right place. NFC. 2019-02-20 00:01:21 +00:00
ScriptLexer.cpp Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +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 Recover elf32-bigmips and elf32-powerpc support in LLD 2019-02-13 18:51:15 +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] Support --{,no-}allow-shlib-undefined 2019-02-01 02:25:05 +00:00
SymbolTable.h [ELF] Support --{,no-}allow-shlib-undefined 2019-02-01 02:25:05 +00:00
Symbols.cpp [ELF] Emit weak-undef symbols in .dynsym of a PIE binary only if linked against shared libs. 2019-03-18 15:32:57 +00:00
Symbols.h [ELF] Delete unused forward declarations and unused DynamicReloc::getInputSec(). NFC 2019-03-15 07:16:39 +00:00
SyntheticSections.cpp [ELF] Allow sh_entsize to be unrelated to sh_addralign and not a power of 2 2019-03-18 23:49:18 +00:00
SyntheticSections.h [ELF] Delete unused forward declarations and unused DynamicReloc::getInputSec(). NFC 2019-03-15 07:16:39 +00:00
Target.cpp ELF: Write .eh_frame_hdr explicitly after writing .eh_frame. 2019-02-28 23:11:35 +00:00
Target.h [PPC64] Sort .toc sections accessed with small code model relocs. 2019-02-12 15:35:49 +00:00
Thunks.cpp [mips] Remove redundant setup of less-significant bit. NFC 2019-03-13 16:00:35 +00:00
Thunks.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
Writer.cpp [ELF] De-virtualize findOrphanPos, excludeLibs and handleARMTlsRelocation 2019-03-17 13:53:42 +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