mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-09 21:50:50 +00:00
Simplify the byte reordering logic slightly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121216 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
d8e351b96f
commit
255eafbd49
@ -131,10 +131,8 @@ static unsigned adjustFixupValue(unsigned Kind, uint64_t Value) {
|
||||
|
||||
// Same addressing mode as fixup_arm_pcrel_10, but with the bytes reordered.
|
||||
if (Kind == ARM::fixup_t2_pcrel_10) {
|
||||
uint64_t swapped = (Value & 0x00FF0000) >> 16;
|
||||
swapped |= (Value & 0xFF000000) >> 16;
|
||||
swapped |= (Value & 0x000000FF) << 16;
|
||||
swapped |= (Value & 0x0000FF00) << 16;
|
||||
uint64_t swapped = (Value & 0xFFFF0000) >> 16;
|
||||
swapped |= (Value & 0x0000FFFF) << 16;
|
||||
return swapped;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user