[llvm-commits] [llvm] r118151 - /llvm/trunk/lib/Target/ARM/ARMMCCodeEmitter.cpp

Bill Wendling isanbard at gmail.com
Tue Nov 2 21:57:44 PDT 2010


Author: void
Date: Tue Nov  2 23:57:44 2010
New Revision: 118151

URL: http://llvm.org/viewvc/llvm-project?rev=118151&view=rev
Log:
Put the PC encoding in the correct bit position.

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

Modified: llvm/trunk/lib/Target/ARM/ARMMCCodeEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMMCCodeEmitter.cpp?rev=118151&r1=118150&r2=118151&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMMCCodeEmitter.cpp (original)
+++ llvm/trunk/lib/Target/ARM/ARMMCCodeEmitter.cpp Tue Nov  2 23:57:44 2010
@@ -240,7 +240,7 @@
   EncodeAddrModeOpValues(MI, OpIdx, Reg, Imm8);
 
   if (Reg == ARM::PC)
-    return ARM::PC << 13;       // Rn is PC;
+    return ARM::PC << 9;        // Rn is PC;
 
   uint32_t Binary = ARM_AM::getAM5Offset(Imm8);
   // Immediate is always encoded as positive. The 'U' bit controls add vs sub.





More information about the llvm-commits mailing list