[llvm-commits] [llvm] r101172 - /llvm/trunk/lib/Target/ARM/ARMAddressingModes.h
Johnny Chen
johnny.chen at apple.com
Tue Apr 13 13:35:17 PDT 2010
Author: johnny
Date: Tue Apr 13 15:35:16 2010
New Revision: 101172
URL: http://llvm.org/viewvc/llvm-project?rev=101172&view=rev
Log:
Changed getSOImmValRotate()'s hunt retry logic to ignore the low order 6 bits,
instead of 7, because we are only looking for even rotate amount.
Modified:
llvm/trunk/lib/Target/ARM/ARMAddressingModes.h
Modified: llvm/trunk/lib/Target/ARM/ARMAddressingModes.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMAddressingModes.h?rev=101172&r1=101171&r2=101172&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMAddressingModes.h (original)
+++ llvm/trunk/lib/Target/ARM/ARMAddressingModes.h Tue Apr 13 15:35:16 2010
@@ -151,10 +151,10 @@
if ((rotr32(Imm, RotAmt) & ~255U) == 0)
return (32-RotAmt)&31; // HW rotates right, not left.
- // For values like 0xF000000F, we should ignore the low 7 bits, then
+ // For values like 0xF000000F, we should ignore the low 6 bits, then
// retry the hunt.
- if (Imm & 127U) {
- unsigned TZ2 = CountTrailingZeros_32(Imm & ~127U);
+ if (Imm & 63U) {
+ unsigned TZ2 = CountTrailingZeros_32(Imm & ~63U);
unsigned RotAmt2 = TZ2 & ~1;
if ((rotr32(Imm, RotAmt2) & ~255U) == 0)
return (32-RotAmt2)&31; // HW rotates right, not left.
More information about the llvm-commits
mailing list