[llvm-commits] [llvm] r120838 - in /llvm/trunk: lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp test/CodeGen/Thumb2/large-stack.ll test/MC/Disassembler/ARM/thumb-tests.txt
Jim Grosbach
grosbach at apple.com
Fri Dec 3 12:33:01 PST 2010
Author: grosbach
Date: Fri Dec 3 14:33:01 2010
New Revision: 120838
URL: http://llvm.org/viewvc/llvm-project?rev=120838&view=rev
Log:
When using the 'push' mnemonic for Thumb2 stmdb, be explicit when it's the
32-bit wide version by adding the .w suffix.
Modified:
llvm/trunk/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp
llvm/trunk/test/CodeGen/Thumb2/large-stack.ll
llvm/trunk/test/MC/Disassembler/ARM/thumb-tests.txt
Modified: llvm/trunk/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp?rev=120838&r1=120837&r2=120838&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp (original)
+++ llvm/trunk/lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp Fri Dec 3 14:33:01 2010
@@ -67,6 +67,8 @@
MI->getOperand(0).getReg() == ARM::SP) {
O << '\t' << "push";
printPredicateOperand(MI, 2, O);
+ if (Opcode == ARM::t2STMDB_UPD)
+ O << ".w";
O << '\t';
printRegisterList(MI, 4, O);
return;
@@ -77,6 +79,8 @@
MI->getOperand(0).getReg() == ARM::SP) {
O << '\t' << "pop";
printPredicateOperand(MI, 2, O);
+ if (Opcode == ARM::t2LDMIA_UPD)
+ O << ".w";
O << '\t';
printRegisterList(MI, 4, O);
return;
Modified: llvm/trunk/test/CodeGen/Thumb2/large-stack.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Thumb2/large-stack.ll?rev=120838&r1=120837&r2=120838&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Thumb2/large-stack.ll (original)
+++ llvm/trunk/test/CodeGen/Thumb2/large-stack.ll Fri Dec 3 14:33:01 2010
@@ -27,7 +27,7 @@
; DARWIN: sub.w sp, sp, #805306368
; DARWIN: sub sp, #20
; LINUX: test3:
-; LINUX: push {r4, r7, r11, lr}
+; LINUX: push.w {r4, r7, r11, lr}
; LINUX: sub.w sp, sp, #805306368
; LINUX: sub sp, #16
%retval = alloca i32, align 4
Modified: llvm/trunk/test/MC/Disassembler/ARM/thumb-tests.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/Disassembler/ARM/thumb-tests.txt?rev=120838&r1=120837&r2=120838&view=diff
==============================================================================
--- llvm/trunk/test/MC/Disassembler/ARM/thumb-tests.txt (original)
+++ llvm/trunk/test/MC/Disassembler/ARM/thumb-tests.txt Fri Dec 3 14:33:01 2010
@@ -46,10 +46,10 @@
# CHECK: pkhbt r2, r4, r6
0xc4 0xea 0x06 0x02
-# CHECK: pop {r2, r4, r6, r8, r10, r12}
+# CHECK: pop.w {r2, r4, r6, r8, r10, r12}
0xbd 0xe8 0x54 0x15
-# CHECK: push {r2, r4, r6, r8, r10, r12}
+# CHECK: push.w {r2, r4, r6, r8, r10, r12}
0x2d 0xe9 0x54 0x15
# CHECK: rsbs r0, r0, #0
More information about the llvm-commits
mailing list