diff --git a/lld/ELF/Arch/PPC64.cpp b/lld/ELF/Arch/PPC64.cpp index e367535dc7a12..06dd863f31b2a 100644 --- a/lld/ELF/Arch/PPC64.cpp +++ b/lld/ELF/Arch/PPC64.cpp @@ -1259,17 +1259,7 @@ void PPC64::relocate(uint8_t *loc, const Relocation &rel, uint64_t val) const { case R_PPC64_DTPREL64: write64(loc, val - dynamicThreadPointerOffset); break; - case R_PPC64_PCREL34: { - const uint64_t si0Mask = 0x00000003ffff0000; - const uint64_t si1Mask = 0x000000000000ffff; - const uint64_t fullMask = 0x0003ffff0000ffff; - checkInt(loc, val, 34, rel); - - uint64_t instr = readPrefixedInstruction(loc) & ~fullMask; - writePrefixedInstruction(loc, instr | ((val & si0Mask) << 16) | - (val & si1Mask)); - break; - } + case R_PPC64_PCREL34: case R_PPC64_GOT_PCREL34: case R_PPC64_GOT_TPREL_PCREL34: case R_PPC64_TPREL34: {