[llvm-commits] [llvm] r59117 - /llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp

Evan Cheng evan.cheng at apple.com
Wed Nov 12 00:21:12 PST 2008


Author: evancheng
Date: Wed Nov 12 02:21:12 2008
New Revision: 59117

URL: http://llvm.org/viewvc/llvm-project?rev=59117&view=rev
Log:
Address mode immediate offset has already been divided by 4.

Modified:
    llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp

Modified: llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp?rev=59117&r1=59116&r2=59117&view=diff

==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp (original)
+++ llvm/trunk/lib/Target/ARM/ARMCodeEmitter.cpp Wed Nov 12 02:21:12 2008
@@ -1195,8 +1195,7 @@
     if (unsigned ImmOffs = ARM_AM::getAM5Offset(Offset.getImm())) {
       if (ARM_AM::getAM5Op(Offset.getImm()) == ARM_AM::add)
         Binary |= 1 << ARMII::U_BitShift;
-      // Immediate offset is multiplied by 4.
-      Binary |= ImmOffs >> 2;
+      Binary |= ImmOffs;
       emitWordLE(Binary);
       return;
     }





More information about the llvm-commits mailing list