| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously, the methods to get symbol addresses were somewhat scattered
in many places. You can use getEntryAddr returns the address of the symbol,
but if you want to get the GOT address for the symbol, you needed to call
Out<ELFT>::Got->getEntryAddr(Sym). This change adds new functions, getVA,
getGotVA, getGotPltVA, and getPltVA to SymbolBody, so that you can use
SymbolBody as the central place to ask about symbols.
http://reviews.llvm.org/D16710
llvm-svn: 259404
|
|
|
|
|
|
|
|
|
|
|
| |
.dynsym table.
Main executable did not export symbols that exist both in the main executable and in DSOs before this patch.
Symbols from object files that override symbols in DSO should be added to .dynsym table.
Differential revision: http://reviews.llvm.org/D16405
llvm-svn: 258672
|
|
|
|
|
|
| |
Thanks to Rui for the suggestion.
llvm-svn: 258189
|
|
|
|
|
|
|
| |
It is not needed now that we resolve symbols is shared libraries
correctly.
llvm-svn: 258104
|
|
|
|
|
|
| |
This matches the behavior of gold and bfd ld.
llvm-svn: 258102
|
|
|
|
|
|
| |
Thanks for Ed Maste for the suggestion.
llvm-svn: 257685
|
|
|
|
| |
llvm-svn: 257678
|
|
|
|
|
|
|
|
| |
It seems that __cxa_demangle function on the buildbot tried to demangle
a variable "tlsvar" as a C++ symbol. Do not call that function unless
it does not start with "_Z" which is the prefix of mangled names.
llvm-svn: 257661
|
|
|
|
| |
llvm-svn: 257647
|
|
|
|
|
|
|
| |
Also rename Ignored -> IgnoredWeak and IgnoredStrong -> Ignored,
since strong symbol is a norm.
llvm-svn: 257507
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On MIPS O32 ABI, _gp_disp is a magic symbol designates offset between
start of function and gp pointer into GOT. To make seal with such symbol
we add new method addIgnoredStrong(). It adds ignored symbol with global
binding to prevent the symbol substitution. The addIgnored call is not
enough here because this call adds a weak symbol which might be
substituted by symbol from shared library.
Differential Revision: http://reviews.llvm.org/D16084
llvm-svn: 257449
|
|
|
|
| |
llvm-svn: 256970
|
|
|
|
|
|
|
| |
createELFFile looked complex because of its use of template,
so I want to keep it private within this file.
llvm-svn: 256880
|
|
|
|
|
|
|
|
| |
This patch moves statically-allocated Elf_Sym objects out
of DefinedRegular class, so that the class definition becomes
smaller.
llvm-svn: 256408
|
|
|
|
|
|
|
| |
Since the only missing bit was the size, I just replaced the Elf_Sym
with the size.
llvm-svn: 256384
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There are 3 symbol types that a .bc can provide during lto: defined,
undefined, common.
Defined and undefined symbols have already been refactored. I was
working on common and noticed that absolute symbols would become an
oddity: They would be the only symbol type present in a .o but not in
a.bc.
Looking a bit more, other than the special section number they were only
used for special rules for computing values. In that way they are
similar to TLS, and we don't have a DefinedTLS.
This patch deletes it. With it we have a reasonable rule of the thumb
for having a symbol kind: It exists if it has special resolution
semantics.
llvm-svn: 256383
|
|
|
|
|
|
|
| |
This is similar to what was done for Undefined and opens the way for
having a symbol defined in bitcode.
llvm-svn: 256354
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I am working on adding LTO support to the new ELF lld.
In order to do that, it will be necessary to represent defined and
undefined symbols that are not from ELF files. One way to do it is to
change the symbol hierarchy to look like
Defined : SymbolBody
Undefined : SymbolBody
DefinedElf<ELFT> : Defined
UndefinedElf<ELFT> : Undefined
Another option would be to use bogus Elf_Sym, but I think that is
getting a bit too hackish.
This patch does the Undefined/UndefinedElf. Split. The next one
will do the Defined/DefinedElf split.
llvm-svn: 256289
|
|
|
|
| |
llvm-svn: 255853
|
|
|
|
|
|
|
|
|
|
| |
These symbols are expected to point to the end of the data segment.
Implements http://llvm.org/pr25528.
Differential Revision: http://reviews.llvm.org/D14833
llvm-svn: 253637
|
|
|
|
|
|
|
| |
The previous code is too clever that that needs a bit more
brain power than this new code.
llvm-svn: 250934
|
|
|
|
|
|
| |
The previous name was too long.
llvm-svn: 250920
|
|
|
|
| |
llvm-svn: 249645
|
|
|
|
|
|
|
| |
I'm going to use them in other patches, and the names feel too long
despite their narrow scope.
llvm-svn: 249642
|
|
|
|
| |
llvm-svn: 249636
|
|
|
|
| |
llvm-svn: 248381
|
|
|
|
| |
llvm-svn: 248226
|
|
|
|
| |
llvm-svn: 247168
|
|
|
|
| |
llvm-svn: 247165
|
|
|
|
| |
llvm-svn: 247019
|
|
|
|
| |
llvm-svn: 246886
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The ELF spec says:
... if any reference to or definition of a name is a symbol with a
non-default visibility attribute, the visibility attribute must be
propagated to the resolving symbol in the linked object. If different
visibility attributes are specified for distinct references to or
definitions of a symbol, the most constraining visibility attribute
must be propagated to the resolving symbol in the linked object. The
attributes, ordered from least to most constraining, are:
STV_PROTECTED, STV_HIDDEN and STV_INTERNAL.
llvm-svn: 246603
|
|
|
|
| |
llvm-svn: 246517
|
|
|
|
|
|
|
| |
This requires templating some functions over ELFT, but that opens other cleanup
opportunities for future patches.
llvm-svn: 246405
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Now that we print a symbol table and all symbol kinds are at least declared,
we can test all combinations that don't produce an error.
This also includes a few fixes to keep the test passing:
* Keep the strong symbol in a weak X strong pair
* Handle common symbols.
The common X common case will be finished in a followup patch.
llvm-svn: 246401
|
|
|
|
|
|
|
| |
On ELF being weak is independent of what we call the kind of the symbol. So
this also makes the code simpler.
llvm-svn: 246326
|
|
|
|
| |
llvm-svn: 246147
|
|
|
|
|
|
|
| |
Tested with a weak undefined. Testing with a plain undefined will have to wait
for support for -shared.
llvm-svn: 245069
|
|
|
|
| |
llvm-svn: 244701
|
|
|
|
| |
llvm-svn: 244640
|
|
|
|
| |
llvm-svn: 244639
|
|
|
|
| |
llvm-svn: 244636
|
|
|
|
|
|
| |
With this clang notices that switches are fully covered.
llvm-svn: 244632
|
|
|
|
|
|
|
|
| |
This was using a hard coded string table and getting it for every symbol.
The symbol name was already available.
llvm-svn: 244220
|
|
|
|
| |
llvm-svn: 244219
|
|
|
|
| |
llvm-svn: 244040
|
|
|
|
| |
llvm-svn: 243496
|
|
|
|
| |
llvm-svn: 243323
|
|
|
|
|
|
| |
This is to make it consistent with COFF.
llvm-svn: 243321
|
|
|
|
|
|
| |
Differential Revision: http://reviews.llvm.org/D11188
llvm-svn: 243161
|