Index: ELF/Arch/PPC.cpp =================================================================== --- ELF/Arch/PPC.cpp +++ ELF/Arch/PPC.cpp @@ -33,6 +33,10 @@ switch (Type) { case R_PPC_REL24: case R_PPC_REL32: + // This allows local symbols to relocate after LLVM started to use PLT + // relocations by default (see D38554). Non-local symbols will need a + // full PLT implementation. + case R_PPC_PLTREL24: return R_PC; default: return R_ABS; @@ -54,6 +58,7 @@ case R_PPC_REL32: write32be(Loc, Val); break; + case R_PPC_PLTREL24: case R_PPC_REL24: write32be(Loc, read32be(Loc) | (Val & 0x3FFFFFC)); break;