- Jun 08, 2016
-
-
Rui Ueyama authored
llvm-svn: 272146
-
George Rimar authored
It was one line global static function that looks nicer to inline, patch do that. llvm-svn: 272137
-
George Rimar authored
llvm-svn: 272134
-
George Rimar authored
That made few places in code a bit shorter. llvm-svn: 272133
-
George Rimar authored
llvm-svn: 272131
-
George Rimar authored
llvm-svn: 272130
-
George Rimar authored
llvm-svn: 272129
-
- Jun 07, 2016
-
-
Rui Ueyama authored
llvm-svn: 272046
-
Rui Ueyama authored
llvm-svn: 272034
-
Rui Ueyama authored
llvm-svn: 272032
-
Rui Ueyama authored
llvm-svn: 272030
-
Peter Smith authored
Add support for an ARM Target and the initial set of relocations and PLT entries that are necessary for an ARM only hello world to link. This has been tested against an ARM only sysroot from the 4.2.0 CodeSourcery Lite release. Tests have been added to test/ELF for the support that has been implemented. Main limitations: - No Thumb support - Relocations incomplete - No C++ exceptions support - No TLS support - No range extension or interworking veneer (thunk) support - No Build Attribute support - No Big-endian support The deprecated relocations R_ARM_PLT32 and R_ARM_PC24 have been implemented as these are used by the 4.2.0 CodeSourcery Lite release. llvm-svn: 271993
-
Rafael Espindola authored
Reduced from a firefox build. llvm-svn: 271950
-
- Jun 06, 2016
-
-
Rui Ueyama authored
Differential Revision: http://reviews.llvm.org/D21008 llvm-svn: 271901
-
George Rimar authored
.gnu.version should have sh_link field initialized with index of DynSymTab section. GNU documentation looks misses that, but Sun docs mention it, according to https://docs.oracle.com/cd/E19120-01/open.solaris/819-0690/chapter6-54676/index.html versym sh_link is indeed supposed to point to the .dynsym section. Binutils readelf tool also relies on that: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=blob;f=binutils/readelf.c;h=b6454d353279dc57745cd5a2d68b5f3f69f8e17c;hb=5522f910cb539905d6adfdceab208ddfa5e84557#l9988 Both gold/bfd do the same + after this patch I am able to see this section in readelf output, was unable before in my case. Differential revision: http://reviews.llvm.org/D20956 llvm-svn: 271874
-
- Jun 05, 2016
-
-
Rafael Espindola authored
With that we can have local symbols with a tls gd index. llvm-svn: 271852
-
Rafael Espindola authored
llvm-svn: 271829
-
Rafael Espindola authored
llvm-svn: 271815
-
Rafael Espindola authored
This remove some EM_386 specific code from InputSection.cpp and opens the way for more relaxations. llvm-svn: 271814
-
Rafael Espindola authored
It will also be used for GT_TO_IE relaxations. llvm-svn: 271813
-
Rafael Espindola authored
It will be used for more than just gots. llvm-svn: 271812
-
- Jun 04, 2016
-
-
Rafael Espindola authored
We were not handling page relative relocations. llvm-svn: 271798
-
- Jun 03, 2016
-
-
Benjamin Kramer authored
No functionality change intended. llvm-svn: 271686
-
Davide Italiano authored
Differential Revision: http://reviews.llvm.org/D20888 llvm-svn: 271605
-
- Jun 02, 2016
-
-
Rafael Espindola authored
This is mostly extracted from http://reviews.llvm.org/D18960. The general idea for tlsdesc is that the two GD got entries are used for a function pointer and its argument. The dynamic linker sets both. In the non-dlopen case the dynamic linker sets the function to the identity and the argument to the offset in the tls block. All that the static linker has to do in the non-dlopen case is relocate the code to point to the got entries and create a dynamic relocation. The dlopen case is more complicated, but can be implemented in another patch. llvm-svn: 271569
-
Rafael Espindola authored
llvm-svn: 271525
-
Rafael Espindola authored
updateAArch64Add takes care of masking. llvm-svn: 271524
-
Rafael Espindola authored
llvm-svn: 271523
-
Rafael Espindola authored
AArch64 uses TLSDESC, so these are dead. llvm-svn: 271517
-
George Rimar authored
Patch adds relaxGotNoPic() method to handle no-PIC path. llvm-svn: 271506
-
- Jun 01, 2016
-
-
George Rimar authored
Patch implements next relaxation from latest ABI: "Convert memory operand of test and binop into immediate operand, where binop is one of adc, add, and, cmp, or, sbb, sub, xor instructions, when position-independent code is disabled." It is described in System V Application Binary Interface AMD64 Architecture Processor Supplement Draft Version 0.99.8 (https://github.com/hjl-tools/x86-psABI/wiki/x86-64-psABI-r249.pdf, B.2 "B.2 Optimize GOTPCRELX Relocations"). Differential revision: http://reviews.llvm.org/D20793 llvm-svn: 271405
-
Davide Italiano authored
When we undefine, we also preserve type of symbol so that we get it right in the combined LTO object. Differential Revision: http://reviews.llvm.org/D20851 llvm-svn: 271403
-
Rafael Espindola authored
We were not reading it or including in the --reproduce archive. llvm-svn: 271367
-
Rafael Espindola authored
This reverts commit r271365. Sorry, wrong branch. llvm-svn: 271366
-
Rafael Espindola authored
llvm-svn: 271365
-
- May 29, 2016
-
-
Davide Italiano authored
Differential Revision: http://reviews.llvm.org/D20777 llvm-svn: 271148
-
- May 28, 2016
-
-
Rui Ueyama authored
llvm-svn: 271133
-
Simon Atanasyan authored
In case of MIPS, GP-relative relocations always resolve to a definition in a regular input file, ignoring the one-definition rule. Such relocations are used to setup GP relative offsets in a function's prologue. So we, for example, should not attempt to create a dynamic relocation even if the target symbol is preemptible. Fixes bug 27880. Differential Revision: http://reviews.llvm.org/D20664 llvm-svn: 271100
-
- May 27, 2016
-
-
Rui Ueyama authored
MergedInputSection::getOffset is the busiest function in LLD if string merging is enabled and input files have lots of mergeable sections. It is usually the case when creating executable with debug info, so it is pretty common. The reason why it is slow is because it has to do faily complex computations. For non-mergeable sections, section contents are contiguous in output, so in order to compute an output offset, we only have to add the output section's base address to an input offset. But for mergeable strings, section contents are split for merging, so they are not contigous. We've got to do some lookups. We used to do binary search on the list of section pieces. It is slow because I think it's hostile to branch prediction. This patch replaces it with hash table lookup. Seems it's working pretty well. Below is "perf stat -r10" output when linking clang with debug info. In this case this patch speeds up about 4%. Before: 6584.153205 task-clock (msec) # 1.001 CPUs utilized ( +- 0.09% ) 238 context-switches # 0.036 K/sec ( +- 6.59% ) 0 cpu-migrations # 0.000 K/sec ( +- 50.92% ) 1,067,675 page-faults # 0.162 M/sec ( +- 0.15% ) 18,369,931,470 cycles # 2.790 GHz ( +- 0.09% ) 9,640,680,143 stalled-cycles-frontend # 52.48% frontend cycles idle ( +- 0.18% ) <not supported> stalled-cycles-backend 21,206,747,787 instructions # 1.15 insns per cycle # 0.45 stalled cycles per insn ( +- 0.04% ) 3,817,398,032 branches # 579.786 M/sec ( +- 0.04% ) 132,787,249 branch-misses # 3.48% of all branches ( +- 0.02% ) 6.579106511 seconds time elapsed ( +- 0.09% ) After: 6312.317533 task-clock (msec) # 1.001 CPUs utilized ( +- 0.19% ) 221 context-switches # 0.035 K/sec ( +- 4.11% ) 1 cpu-migrations # 0.000 K/sec ( +- 45.21% ) 1,280,775 page-faults # 0.203 M/sec ( +- 0.37% ) 17,611,539,150 cycles # 2.790 GHz ( +- 0.19% ) 10,285,148,569 stalled-cycles-frontend # 58.40% frontend cycles idle ( +- 0.30% ) <not supported> stalled-cycles-backend 18,794,779,900 instructions # 1.07 insns per cycle # 0.55 stalled cycles per insn ( +- 0.03% ) 3,287,450,865 branches # 520.799 M/sec ( +- 0.03% ) 72,259,605 branch-misses # 2.20% of all branches ( +- 0.01% ) 6.307411828 seconds time elapsed ( +- 0.19% ) Differential Revision: http://reviews.llvm.org/D20645 llvm-svn: 270999
-
Peter Collingbourne authored
Differential Revision: http://reviews.llvm.org/D20704 llvm-svn: 270968
-