hanchenye-llvm-project/lld/ELF
Fangrui Song 3e0a54e9da [ELF] Use llvm::toLower instead of libc call tolower
tolower() has some overhead because current locale is considered (though in lld the default "C" locale is used which does not matter too much). llvm::toLower is more efficient as it compiles to a compare and a conditional jump, as opposed to a libc call if tolower is used.

Disregarding locale also matches gdb's behavior (gdb/minsyms.h):

    #define SYMBOL_HASH_NEXT(hash, c)			\
      ((hash) * 67 + TOLOWER ((unsigned char) (c)) - 113)

where TOLOWER (include/safe-ctype.h) is a macro that uses a lookup table under the hood which is similar to llvm::toLower.

Reviewers: ruiu, espindola

Subscribers: emaste, arichardson, llvm-commits

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

llvm-svn: 342342
2018-09-15 23:59:13 +00:00
..
Arch [PPC64] Fix DQ-form instruction handling and emit error for misalignment. 2018-08-28 15:16:01 +00:00
AArch64ErrataFix.cpp [ELF] Guard --fix-cortex-a53-843419 against --just-syms 2018-09-13 15:49:13 +00:00
AArch64ErrataFix.h Consistent (non) use of empty lines in include blocks 2018-02-20 21:53:18 +00:00
Bits.h
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 lld: add -z interpose support 2018-09-14 14:25:37 +00:00
DWARF.cpp Rename GdbIndex.{cpp,h} -> DWARF.{cpp,h}. 2018-09-14 23:51:05 +00:00
DWARF.h Style fix. NFC. 2018-09-14 23:51:17 +00:00
Driver.cpp lld: add -z interpose support 2018-09-14 14:25:37 +00:00
Driver.h Add TARGET(foo) linker script directive. 2018-08-06 21:29:41 +00:00
DriverUtils.cpp [ELF] Use search paths for --version-script= 2018-07-25 21:53:18 +00:00
EhFrame.cpp [ELF] Simplify read32. NFC 2018-03-30 23:13:00 +00:00
EhFrame.h
Filesystem.cpp s/LLVM_ON_WIN32/_WIN32/, lld 2018-04-10 13:15:21 +00:00
Filesystem.h
ICF.cpp ELF: Don't examine values of linker script symbols during ICF. 2018-08-29 23:43:38 +00:00
ICF.h Consistent use of header file for ICF and MarkLive 2018-02-20 22:09:59 +00:00
InputFiles.cpp [ELF] Check if LinkSec is nullptr when initializing SHF_LINK_ORDER sections 2018-09-07 00:18:07 +00:00
InputFiles.h Change how we handle -wrap. 2018-08-22 07:02:26 +00:00
InputSection.cpp When a relocation to an undefined symbol is an R_X86_64_PC32, an input 2018-09-04 21:06:59 +00:00
InputSection.h Revert r342297: Discard uncompressed buffer after creating .gdb_index contents. 2018-09-14 23:28:13 +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 ELF: Don't examine values of linker script symbols during ICF. 2018-08-29 23:43:38 +00:00
LinkerScript.h [ELF] - Eliminate the AssertCommand. 2018-04-25 11:16:31 +00:00
MapFile.cpp [ELF] - Change dyn_cast to cast. NFC. 2018-07-02 08:26:20 +00:00
MapFile.h Implement --cref. 2018-03-14 20:29:45 +00:00
MarkLive.cpp [ELF] Pass callables by function_ref 2018-06-16 12:11:34 +00:00
MarkLive.h Consistent use of header file for ICF and MarkLive 2018-02-20 22:09:59 +00:00
Options.td [docs] Update ld.lld.1 2018-07-30 17:36:38 +00:00
OutputSections.cpp [ELF] Pass callables by function_ref 2018-06-16 12:11:34 +00:00
OutputSections.h [ELF] - Implement linker script OVERLAYs. 2018-06-27 08:08:12 +00:00
README.md
Relocations.cpp [PPC64] Add TLS initial exec to local exec relaxation 2018-08-21 15:13:53 +00:00
Relocations.h [PPC64] Add TLS initial exec to local exec relaxation 2018-08-21 15:13:53 +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
SymbolTable.cpp Change how we handle -wrap. 2018-08-22 07:02:26 +00:00
SymbolTable.h Change how we handle -wrap. 2018-08-22 07:02:26 +00:00
Symbols.cpp [ELF] Revert "Also demote lazy symbols." 2018-09-11 23:00:36 +00:00
Symbols.h [ELF] Revert "Also demote lazy symbols." 2018-09-11 23:00:36 +00:00
SyntheticSections.cpp [ELF] Use llvm::toLower instead of libc call tolower 2018-09-15 23:59:13 +00:00
SyntheticSections.h Rename GdbIndex.{cpp,h} -> DWARF.{cpp,h}. 2018-09-14 23:51:05 +00:00
Target.cpp Support RISC-V 2018-08-09 17:59:56 +00:00
Target.h [ELF] Add support for Armv5 and Armv6 compatible Thunks 2018-08-20 09:37:50 +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 Style fix. 2018-09-11 13:41:58 +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