Changes in directory llvm/lib/Target/ARM:
ARMISelLowering.cpp updated: 1.41 -> 1.42 --- Log message: restore support for negative strides --- Diffs of the changes: (+5 -3) ARMISelLowering.cpp | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-) Index: llvm/lib/Target/ARM/ARMISelLowering.cpp diff -u llvm/lib/Target/ARM/ARMISelLowering.cpp:1.41 llvm/lib/Target/ARM/ARMISelLowering.cpp:1.42 --- llvm/lib/Target/ARM/ARMISelLowering.cpp:1.41 Mon Apr 9 18:33:39 2007 +++ llvm/lib/Target/ARM/ARMISelLowering.cpp Mon Apr 9 22:48:29 2007 @@ -1372,6 +1372,7 @@ return false; default: + int Scale = AM.Scale; switch (getValueType(Ty)) { default: return false; case MVT::i1: @@ -1381,14 +1382,15 @@ // This assumes i64 is legalized to a pair of i32. If not (i.e. // ldrd / strd are used, then its address mode is same as i16. // r + r - if (AM.Scale == 1) + if (Scale < 0) Scale = -Scale; + if (Scale == 1) return true; // r + r << imm - if (!isPowerOf2_32(AM.Scale & ~1)) + if (!isPowerOf2_32(Scale & ~1)) return false; case MVT::i16: // r + r - if (((unsigned)AM.HasBaseReg + AM.Scale) <= 2) + if (((unsigned)AM.HasBaseReg + Scale) <= 2) return true; case MVT::isVoid: _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits