summaryrefslogtreecommitdiffstats
path: root/lld/ELF/Relocations.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lld/ELF/Relocations.cpp')
-rw-r--r--lld/ELF/Relocations.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/lld/ELF/Relocations.cpp b/lld/ELF/Relocations.cpp
index 48fb403b50e..d2f0272ed42 100644
--- a/lld/ELF/Relocations.cpp
+++ b/lld/ELF/Relocations.cpp
@@ -251,7 +251,8 @@ template <class ELFT> static bool isAbsolute(const SymbolBody &Body) {
}
static bool needsPlt(RelExpr Expr) {
- return Expr == R_PLT_PC || Expr == R_PPC_PLT_OPD || Expr == R_PLT;
+ return Expr == R_PLT_PC || Expr == R_PPC_PLT_OPD || Expr == R_PLT ||
+ Expr == R_PLT_PAGE_PC;
}
// True if this expression is of the form Sym - X, where X is a position in the
@@ -311,6 +312,8 @@ static RelExpr toPlt(RelExpr Expr) {
return R_PPC_PLT_OPD;
if (Expr == R_PC)
return R_PLT_PC;
+ if (Expr == R_PAGE_PC)
+ return R_PLT_PAGE_PC;
if (Expr == R_ABS)
return R_PLT;
return Expr;
OpenPOWER on IntegriCloud