- Aug 19, 2016
-
-
George Rimar authored
This patch is opposite to D19024, which made this symbols to be hidden by default. Unfortunately FreeBSD loader wants to see start_set_modmetadata_set/stop_set_modmetadata_set in the dynamic symbol table. They were not placed there because had hidden visibility. Patch makes them to have default visibility again. Differential revision: https://reviews.llvm.org/D23552 llvm-svn: 279262
-
George Rimar authored
Previously DT_PREINIT_ARRAYSZ, DT_INIT_ARRAYSZ and DT_FINI_ARRAYSZ were set to zero when lincerscript was used becase sections sizes are calculated later that were taken. Patch delays values calculation for these entries. Testcase is provided. Differential revision: https://reviews.llvm.org/D23663 llvm-svn: 279258
-
George Rimar authored
You can force input section alignment within an output section by using SUBALIGN. The value specified overrides any alignment given by input sections, whether larger or smaller. SUBALIGN is used in many projects in the wild. Differential revision: https://reviews.llvm.org/D23063 llvm-svn: 279256
-
George Rimar authored
llvm-svn: 279236
-
George Rimar authored
Spec says "A hidden symbol contained in a relocatable object must be either removed or converted to STB_LOCAL binding by the link-editor when the relocatable object is included in an executable file or shared object". But we previously converted symbols to STB_LOCAL even when -r was specified. Broken binary was produced, this is PR28967, patch fixes the issue. Differential revision: https://reviews.llvm.org/D23514 llvm-svn: 279220
-
- Aug 18, 2016
-
-
Petr Hosek authored
We should always include symbol name when reporting relocations error to simplify debugging of these issues. Without symbol names users have to manually investigate which of the libraries contain invalid relocations which can be cumbersome when linking multiple libraries. Differential Revision: https://reviews.llvm.org/D23690 llvm-svn: 279162
-
Simon Atanasyan authored
llvm-svn: 279119
-
Simon Atanasyan authored
llvm-svn: 279118
-
George Rimar authored
llvm-svn: 279060
-
George Rimar authored
llvm-svn: 279059
-
Ed Maste authored
Differential Revision: https://reviews.llvm.org/D23124 llvm-svn: 279058
-
Eugene Leviant authored
llvm-svn: 279036
-
Petr Hosek authored
We only support assignments inside SECTIONS, but this does not match the behavior of GNU linker which also allows them outside SECTIONS. The only restriction on assignments outside SECTIONS is that they cannot reference . (they have to be absolute expressions). Differential Revision: https://reviews.llvm.org/D23598 llvm-svn: 279033
-
Petr Hosek authored
This option can be used to specify the stack size of the PT_GNU_STACK segment. Differential Revision: https://reviews.llvm.org/D23538 llvm-svn: 279013
-
- Aug 17, 2016
-
-
Rui Ueyama authored
Now that they are identical. llvm-svn: 278953
-
George Rimar authored
llvm-svn: 278931
-
George Rimar authored
Attemp to fix linux build bot after r278911 ("[ELF] - linkerscript AT keyword (in output section description) implemented.") http://lab.llvm.org:8011/builders/lld-x86_64-darwin13/builds/26289/steps/build_Lld/logs/stdio llvm-svn: 278914
-
George Rimar authored
The linker will normally set the LMA equal to the VMA. You can change that by using the AT keyword. The expression lma that follows the AT keyword specifies the load address of the section. Patch implements this keyword. Differential revision: https://reviews.llvm.org/D19272 llvm-svn: 278911
-
Michael J. Spencer authored
The FreeBSD kernel relies on this behavior to not overwrite the boot loader. llvm-svn: 278889
-
- Aug 16, 2016
-
-
Davide Italiano authored
llvm-svn: 278834
-
Ed Maste authored
llvm-svn: 278819
-
George Rimar authored
Previously lld showed version number and returned, that is different from ld and PR28999. Patch fixed that. llvm-svn: 278797
-
Eugene Leviant authored
llvm-svn: 278781
-
Petr Hosek authored
This add support for HIDDEN command which can be used to define a symbol that will be hidden and won't be exported. Differential Revision: https://reviews.llvm.org/D23534 llvm-svn: 278770
-
- Aug 15, 2016
-
-
Eugene Leviant authored
llvm-svn: 278663
-
Eugene Leviant authored
llvm-svn: 278657
-
- Aug 12, 2016
-
-
George Rimar authored
Previously we searched output section by name to assign VA. That did not work in the case when multiple output sections with different constraints were defined in script. Testcase shows the possible issue scenario, patch fixes the issue. Differential revision: https://reviews.llvm.org/D23451 llvm-svn: 278561
-
George Rimar authored
After latest changes we combine input sections with different attributes into single output section. Problem here is that regular output sections does not support adding mergeable input sections (and vise versa). Patch just temporarily disables merging for now at the same way we do for -O0 for example. This change helps for linking FreeBSD kernel. Differential revision: https://reviews.llvm.org/D23447 llvm-svn: 278555
-
George Rimar authored
After 278461 "Create only one section for a name in LinkerScript." this loop is excessive. Patch also reorders code slightly to use early return. Differential revision: https://reviews.llvm.org/D23442 llvm-svn: 278554
-
George Rimar authored
We found that GNU assembler 2.17.50 [FreeBSD] 2007-07-03 could generate broken objects. STT_SECTION symbols can be associated with SHT_REL[A]/SHT_SYMTAB/SHT_STRTAB sections. This is PR28868, patch fixes handling of such files. Differential revision: https://reviews.llvm.org/D23201 llvm-svn: 278550
-
Duncan P. N. Exon Smith authored
Use ilist_half_embedded_sentinel_traits for the list of lld::mach_o::normalized::TrieEdge, rather than duplicating the code. llvm-svn: 278523
-
Duncan P. N. Exon Smith authored
Avoid custom code for sentinel traits in SimpleReference (the ilist node for references to a SimpleDefinedAtom), since they'll soon/eventually disappear from ilist entirely. Rather than using a BumpPtrAllocator, this drops the lazy sentinel characteristics and stores the sentinel directly in the ilist. This unconditionally allocates the sentinel. At first glance, this looks like it might increase memory usage slightly, since an unreferenced SimpleDefinedAtom pays for a 6-pointer-sized sentinel even when its list of references is empty. In practice, the sentinel was being lazily allocated at the first call to DefinedAtom::begin/end anyway. I don't expect any real memory effects here. Moreover, this is an intermediate state. The ilist_*sentinel_traits are being phased out. As a preview of the final state: in lieu of a NodeTy sentinel, the ilist will have a single, untemplated list_node_base that has next/prev pointers. This base node will serve both as a sentinel and as a pointer to the head of the list (the same memory layout as ilist_half_embedded_sentinel_traits, but without the UB). llvm-svn: 278521
-
Davide Italiano authored
The code in lib/ could use a lot of love :( llvm-svn: 278506
-
Davide Italiano authored
llvm-svn: 278505
-
George Rimar authored
Previously filtering that was used worked incorrectly. For example for next script it would just remove both sections completely: SECTIONS { . = 0x1000; .aaa : ONLY_IF_RW { *(.aaa.*) } . = 0x2000; .aaa : ONLY_IF_RO { *(.aaa.*) } } Patch fixes above issues and adds testcase showing the issue. Testcase is a subset of FreeBSD script which has: .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) } ... .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) } Differential revision: https://reviews.llvm.org/D23326 llvm-svn: 278486
-
Simon Atanasyan authored
This section supersedes .reginfo and .MIPS.options sections. But for now we have to support all three sections for ABI transition period. llvm-svn: 278482
-
Simon Atanasyan authored
llvm-svn: 278480
-
Rui Ueyama authored
llvm-svn: 278473
-
Rui Ueyama authored
We have getSectionSize for SIZEOF command. So, I think getHeaderSize is a better name for SIZEOF_HEADERS. llvm-svn: 278470
-
Duncan P. N. Exon Smith authored
There's nothing special about the _next/_prev pointers in SimpleReference, so just use ilist_node to do the work. llvm-svn: 278468
-