summaryrefslogtreecommitdiffstats
path: root/lld/ELF/InputSection.cpp
diff options
context:
space:
mode:
authorSimon Atanasyan <simon@atanasyan.com>2019-07-24 11:37:13 +0000
committerSimon Atanasyan <simon@atanasyan.com>2019-07-24 11:37:13 +0000
commit5adbfdda2db97811e5e8f34a86d730d90e25ca15 (patch)
tree62ad183226ee7824066ddad91e58ff1331c0aa79 /lld/ELF/InputSection.cpp
parent3daefb07448ae14ce7a4141b21cfe6ed1242e244 (diff)
downloadbcm5719-llvm-5adbfdda2db97811e5e8f34a86d730d90e25ca15.tar.gz
bcm5719-llvm-5adbfdda2db97811e5e8f34a86d730d90e25ca15.zip
[mips] Assign R_TLS type to the R_MIPS_TLS_TPREL_XXX relocations. NFC
That allows to remove duplicated code which subtracts 0x7000 from the R_MIPS_TLS_TPREL_XXX relocations values in the `MIPS::relocateOne` function. llvm-svn: 366888
Diffstat (limited to 'lld/ELF/InputSection.cpp')
-rw-r--r--lld/ELF/InputSection.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/lld/ELF/InputSection.cpp b/lld/ELF/InputSection.cpp
index a024ac307b0..c9a02c91c84 100644
--- a/lld/ELF/InputSection.cpp
+++ b/lld/ELF/InputSection.cpp
@@ -619,6 +619,7 @@ static int64_t getTlsTpOffset(const Symbol &s) {
case EM_X86_64:
// Variant 2. The TLS segment is located just before the thread pointer.
return s.getVA(0) - alignTo(Out::tlsPhdr->p_memsz, Out::tlsPhdr->p_align);
+ case EM_MIPS:
case EM_PPC:
case EM_PPC64:
// The thread pointer points to a fixed offset from the start of the
OpenPOWER on IntegriCloud