[llvm-commits] [llvm] r74321 - in /llvm/trunk: lib/Target/ARM/ARMInstrThumb2.td test/CodeGen/Thumb2/carry.ll test/CodeGen/Thumb2/thumb2-adc.ll test/CodeGen/Thumb2/thumb2-adc2.ll
David Goodwin
david_goodwin at apple.com
Fri Jun 26 13:45:56 PDT 2009
Author: david_goodwin
Date: Fri Jun 26 15:45:56 2009
New Revision: 74321
URL: http://llvm.org/viewvc/llvm-project?rev=74321&view=rev
Log:
Use "adcs/sbcs" only when the carry-out is live, otherwise use "adc/sbc".
Modified:
llvm/trunk/lib/Target/ARM/ARMInstrThumb2.td
llvm/trunk/test/CodeGen/Thumb2/carry.ll
llvm/trunk/test/CodeGen/Thumb2/thumb2-adc.ll
llvm/trunk/test/CodeGen/Thumb2/thumb2-adc2.ll
Modified: llvm/trunk/lib/Target/ARM/ARMInstrThumb2.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMInstrThumb2.td?rev=74321&r1=74320&r2=74321&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMInstrThumb2.td (original)
+++ llvm/trunk/lib/Target/ARM/ARMInstrThumb2.td Fri Jun 26 15:45:56 2009
@@ -236,19 +236,19 @@
multiclass T2I_adde_sube_irs<string opc, PatFrag opnode, bit Commutable = 0> {
// shifted imm
def ri : T2sI<(outs GPR:$dst), (ins GPR:$lhs, t2_so_imm:$rhs),
- opc, "s $dst, $lhs, $rhs",
+ opc, " $dst, $lhs, $rhs",
[(set GPR:$dst, (opnode GPR:$lhs, t2_so_imm:$rhs))]>,
Requires<[IsThumb, HasThumb2, CarryDefIsUnused]>;
// register
def rr : T2sI<(outs GPR:$dst), (ins GPR:$lhs, GPR:$rhs),
- opc, "s $dst, $lhs, $rhs",
+ opc, " $dst, $lhs, $rhs",
[(set GPR:$dst, (opnode GPR:$lhs, GPR:$rhs))]>,
Requires<[IsThumb, HasThumb2, CarryDefIsUnused]> {
let isCommutable = Commutable;
}
// shifted register
def rs : T2sI<(outs GPR:$dst), (ins GPR:$lhs, t2_so_reg:$rhs),
- opc, "s $dst, $lhs, $rhs",
+ opc, " $dst, $lhs, $rhs",
[(set GPR:$dst, (opnode GPR:$lhs, t2_so_reg:$rhs))]>,
Requires<[IsThumb, HasThumb2, CarryDefIsUnused]>;
// Carry setting variants
Modified: llvm/trunk/test/CodeGen/Thumb2/carry.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Thumb2/carry.ll?rev=74321&r1=74320&r2=74321&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Thumb2/carry.ll (original)
+++ llvm/trunk/test/CodeGen/Thumb2/carry.ll Fri Jun 26 15:45:56 2009
@@ -1,6 +1,6 @@
; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2 | grep "subs r" | count 2
-; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2 | grep "adcs r"
-; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2 | grep "sbcs r" | count 2
+; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2 | grep "adc r"
+; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2 | grep "sbc r" | count 2
define i64 @f1(i64 %a, i64 %b) {
entry:
Modified: llvm/trunk/test/CodeGen/Thumb2/thumb2-adc.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Thumb2/thumb2-adc.ll?rev=74321&r1=74320&r2=74321&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Thumb2/thumb2-adc.ll (original)
+++ llvm/trunk/test/CodeGen/Thumb2/thumb2-adc.ll Fri Jun 26 15:45:56 2009
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2 | grep {adcs\\W*r\[0-9\],\\W*r\[0-9\],\\W*#\[0-9\]*} | grep {#171\\|#1179666\\|#872428544\\|#1448498774\\|#66846720} | count 5
+; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2 | grep {adc\\W*r\[0-9\],\\W*r\[0-9\],\\W*#\[0-9\]*} | grep {#171\\|#1179666\\|#872428544\\|#1448498774\\|#66846720} | count 5
; 734439407617 = 0x000000ab00000001
define i64 @f1(i64 %a) {
Modified: llvm/trunk/test/CodeGen/Thumb2/thumb2-adc2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Thumb2/thumb2-adc2.ll?rev=74321&r1=74320&r2=74321&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Thumb2/thumb2-adc2.ll (original)
+++ llvm/trunk/test/CodeGen/Thumb2/thumb2-adc2.ll Fri Jun 26 15:45:56 2009
@@ -1,4 +1,4 @@
-; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2 | grep {adcs\\W*r\[0-9\],\\W*r\[0-9\],\\W*r\[0-9\]*} | count 1
+; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2 | grep {adc\\W*r\[0-9\],\\W*r\[0-9\],\\W*r\[0-9\]*} | count 1
define i64 @f1(i64 %a, i64 %b) {
%tmp = add i64 %a, %b
More information about the llvm-commits
mailing list