summaryrefslogtreecommitdiffstats
path: root/lld/ELF/InputSection.cpp
diff options
context:
space:
mode:
authorSean Fertile <sfertile@ca.ibm.com>2018-05-31 18:44:12 +0000
committerSean Fertile <sfertile@ca.ibm.com>2018-05-31 18:44:12 +0000
commit1a8343fce3bfff06864a86d33ec3c1acf58cc9b7 (patch)
tree4f2033c6d01059a42bb942417c198c4b58eb27fe /lld/ELF/InputSection.cpp
parent26fc531dbc652a7738f3c8a421b3023ca12ca1ad (diff)
downloadbcm5719-llvm-1a8343fce3bfff06864a86d33ec3c1acf58cc9b7.tar.gz
bcm5719-llvm-1a8343fce3bfff06864a86d33ec3c1acf58cc9b7.zip
[PPC64] Support R_PPC64_GOT_TLSLD16 relocations.
Add support for the R_PPC64_GOT_TLSLD16 relocations used to build the address of the tls_index struct used in local-dynamic tls. Differential Revision: https://reviews.llvm.org/D47538 llvm-svn: 333681
Diffstat (limited to 'lld/ELF/InputSection.cpp')
-rw-r--r--lld/ELF/InputSection.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lld/ELF/InputSection.cpp b/lld/ELF/InputSection.cpp
index ad8cbfa6880..09bc39eaed1 100644
--- a/lld/ELF/InputSection.cpp
+++ b/lld/ELF/InputSection.cpp
@@ -639,6 +639,8 @@ static uint64_t getRelocTargetVA(RelType Type, int64_t A, uint64_t P,
return InX::Got->getGlobalDynAddr(Sym) + A - P;
case R_TLSLD_GOT_FROM_END:
return InX::Got->getTlsIndexOff() + A - InX::Got->getSize();
+ case R_TLSLD_GOT:
+ return InX::Got->getTlsIndexOff() + A;
case R_TLSLD_PC:
return InX::Got->getTlsIndexVA() + A - P;
}
OpenPOWER on IntegriCloud