[lld] r362883 - [ELF] [PPC] Fix a typo from SVN r362721
Martin Storsjo via llvm-commits
llvm-commits at lists.llvm.org
Sat Jun 8 11:26:27 PDT 2019
Author: mstorsjo
Date: Sat Jun 8 11:26:27 2019
New Revision: 362883
URL: http://llvm.org/viewvc/llvm-project?rev=362883&view=rev
Log:
[ELF] [PPC] Fix a typo from SVN r362721
Apparently no test covers this exact codepath, but GCC produced a
warning about it.
Modified:
lld/trunk/ELF/Arch/PPC.cpp
Modified: lld/trunk/ELF/Arch/PPC.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/Arch/PPC.cpp?rev=362883&r1=362882&r2=362883&view=diff
==============================================================================
--- lld/trunk/ELF/Arch/PPC.cpp (original)
+++ lld/trunk/ELF/Arch/PPC.cpp Sat Jun 8 11:26:27 2019
@@ -180,7 +180,7 @@ uint32_t PPC::getThunkSectionSpacing() c
bool PPC::inBranchRange(RelType Type, uint64_t Src, uint64_t Dst) const {
uint64_t Offset = Dst - Src;
- if (Type == R_PPC_REL24 || R_PPC_PLTREL24)
+ if (Type == R_PPC_REL24 || Type == R_PPC_PLTREL24)
return isInt<26>(Offset);
llvm_unreachable("unsupported relocation type used in branch");
}
More information about the llvm-commits
mailing list