[llvm-commits] [llvm] r144679 - in /llvm/trunk: lib/Target/ARM/AsmParser/ARMAsmParser.cpp test/MC/ARM/basic-thumb2-instructions.s
Jim Grosbach
grosbach at apple.com
Tue Nov 15 11:29:45 PST 2011
Author: grosbach
Date: Tue Nov 15 13:29:45 2011
New Revision: 144679
URL: http://llvm.org/viewvc/llvm-project?rev=144679&view=rev
Log:
Thumb2 assembly parsing for mul.w in IT block fix.
When the 3rd operand is not a low-register, and the first two operands are
the same low register, the parser was incorrectly trying to use the 16-bit
instruction encoding.
rdar://10449281
Modified:
llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
llvm/trunk/test/MC/ARM/basic-thumb2-instructions.s
Modified: llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp?rev=144679&r1=144678&r2=144679&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp (original)
+++ llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp Tue Nov 15 13:29:45 2011
@@ -4098,6 +4098,7 @@
// remove the cc_out operand.
(!isARMLowRegister(static_cast<ARMOperand*>(Operands[3])->getReg()) ||
!isARMLowRegister(static_cast<ARMOperand*>(Operands[4])->getReg()) ||
+ !isARMLowRegister(static_cast<ARMOperand*>(Operands[5])->getReg()) ||
!inITBlock() ||
(static_cast<ARMOperand*>(Operands[3])->getReg() !=
static_cast<ARMOperand*>(Operands[5])->getReg() &&
Modified: llvm/trunk/test/MC/ARM/basic-thumb2-instructions.s
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/MC/ARM/basic-thumb2-instructions.s?rev=144679&r1=144678&r2=144679&view=diff
==============================================================================
--- llvm/trunk/test/MC/ARM/basic-thumb2-instructions.s (original)
+++ llvm/trunk/test/MC/ARM/basic-thumb2-instructions.s Tue Nov 15 13:29:45 2011
@@ -1228,12 +1228,16 @@
mul r3, r4, r6
it eq
muleq r3, r4, r5
+ it le
+ mulle r4, r4, r8
@ CHECK: muls r3, r4, r3 @ encoding: [0x63,0x43]
@ CHECK: mul r3, r4, r3 @ encoding: [0x04,0xfb,0x03,0xf3]
@ CHECK: mul r3, r4, r6 @ encoding: [0x04,0xfb,0x06,0xf3]
@ CHECK: it eq @ encoding: [0x08,0xbf]
@ CHECK: muleq r3, r4, r5 @ encoding: [0x04,0xfb,0x05,0xf3]
+@ CHECK: it le @ encoding: [0xd8,0xbf]
+@ CHECK: mulle r4, r4, r8 @ encoding: [0x04,0xfb,0x08,0xf4]
@------------------------------------------------------------------------------
More information about the llvm-commits
mailing list