summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lld/ELF/Arch/X86.cpp2
-rw-r--r--lld/ELF/InputSection.cpp4
-rw-r--r--lld/ELF/Relocations.h2
3 files changed, 4 insertions, 4 deletions
diff --git a/lld/ELF/Arch/X86.cpp b/lld/ELF/Arch/X86.cpp
index 896d4fe333d..7001eb47194 100644
--- a/lld/ELF/Arch/X86.cpp
+++ b/lld/ELF/Arch/X86.cpp
@@ -161,7 +161,7 @@ RelExpr X86::adjustRelaxExpr(RelType Type, const uint8_t *Data,
default:
return Expr;
case R_RELAX_TLS_GD_TO_IE:
- return R_RELAX_TLS_GD_TO_IE_END;
+ return R_RELAX_TLS_GD_TO_IE_GOTPLT;
case R_RELAX_TLS_GD_TO_LE:
return R_RELAX_TLS_GD_TO_LE_NEG;
}
diff --git a/lld/ELF/InputSection.cpp b/lld/ELF/InputSection.cpp
index 0ed3a70156f..a32015f4b14 100644
--- a/lld/ELF/InputSection.cpp
+++ b/lld/ELF/InputSection.cpp
@@ -632,7 +632,7 @@ static uint64_t getRelocTargetVA(const InputFile *File, RelType Type, int64_t A,
case R_GOTPLTREL:
return Sym.getVA(A) - In.GotPlt->getVA();
case R_GOTPLT:
- case R_RELAX_TLS_GD_TO_IE_END:
+ case R_RELAX_TLS_GD_TO_IE_GOTPLT:
return Sym.getGotVA() + A - In.GotPlt->getVA();
case R_TLSLD_GOT_OFF:
case R_GOT_OFF:
@@ -908,7 +908,7 @@ void InputSectionBase::relocateAlloc(uint8_t *Buf, uint8_t *BufEnd) {
case R_RELAX_TLS_GD_TO_IE:
case R_RELAX_TLS_GD_TO_IE_ABS:
case R_RELAX_TLS_GD_TO_IE_GOT_OFF:
- case R_RELAX_TLS_GD_TO_IE_END:
+ case R_RELAX_TLS_GD_TO_IE_GOTPLT:
Target->relaxTlsGdToIe(BufLoc, Type, TargetVA);
break;
case R_PPC_CALL:
diff --git a/lld/ELF/Relocations.h b/lld/ELF/Relocations.h
index a3edea525f2..48ed3621a93 100644
--- a/lld/ELF/Relocations.h
+++ b/lld/ELF/Relocations.h
@@ -49,8 +49,8 @@ enum RelExpr {
R_RELAX_GOT_PC_NOPIC,
R_RELAX_TLS_GD_TO_IE,
R_RELAX_TLS_GD_TO_IE_ABS,
- R_RELAX_TLS_GD_TO_IE_END,
R_RELAX_TLS_GD_TO_IE_GOT_OFF,
+ R_RELAX_TLS_GD_TO_IE_GOTPLT,
R_RELAX_TLS_GD_TO_LE,
R_RELAX_TLS_GD_TO_LE_NEG,
R_RELAX_TLS_IE_TO_LE,
OpenPOWER on IntegriCloud