[llvm-commits] [llvm] r85210 - in /llvm/trunk/test/CodeGen/Thumb2: thumb2-bfc.ll thumb2-clz.ll thumb2-cmn2.ll thumb2-eor2.ll thumb2-str_post.ll
Bob Wilson
bob.wilson at apple.com
Mon Oct 26 23:31:02 PDT 2009
Author: bwilson
Date: Tue Oct 27 01:31:02 2009
New Revision: 85210
URL: http://llvm.org/viewvc/llvm-project?rev=85210&view=rev
Log:
Fix Thumb2 failures by converting them to FileCheck.
Modified:
llvm/trunk/test/CodeGen/Thumb2/thumb2-bfc.ll
llvm/trunk/test/CodeGen/Thumb2/thumb2-clz.ll
llvm/trunk/test/CodeGen/Thumb2/thumb2-cmn2.ll
llvm/trunk/test/CodeGen/Thumb2/thumb2-eor2.ll
llvm/trunk/test/CodeGen/Thumb2/thumb2-str_post.ll
Modified: llvm/trunk/test/CodeGen/Thumb2/thumb2-bfc.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Thumb2/thumb2-bfc.ll?rev=85210&r1=85209&r2=85210&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Thumb2/thumb2-bfc.ll (original)
+++ llvm/trunk/test/CodeGen/Thumb2/thumb2-bfc.ll Tue Oct 27 01:31:02 2009
@@ -1,25 +1,32 @@
-; RUN: llc < %s -march=thumb -mattr=+thumb2 | grep "bfc " | count 3
+; RUN: llc < %s -march=thumb -mattr=+thumb2 | FileCheck %s
; 4278190095 = 0xff00000f
define i32 @f1(i32 %a) {
+; CHECK: f1:
+; CHECK: bfc r
%tmp = and i32 %a, 4278190095
ret i32 %tmp
}
; 4286578688 = 0xff800000
define i32 @f2(i32 %a) {
+; CHECK: f2:
+; CHECK: bfc r
%tmp = and i32 %a, 4286578688
ret i32 %tmp
}
; 4095 = 0x00000fff
define i32 @f3(i32 %a) {
+; CHECK: f3:
+; CHECK: bfc r
%tmp = and i32 %a, 4095
ret i32 %tmp
}
; 2147483646 = 0x7ffffffe not implementable w/ BFC
define i32 @f4(i32 %a) {
+; CHECK: f4:
%tmp = and i32 %a, 2147483646
ret i32 %tmp
}
Modified: llvm/trunk/test/CodeGen/Thumb2/thumb2-clz.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Thumb2/thumb2-clz.ll?rev=85210&r1=85209&r2=85210&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Thumb2/thumb2-clz.ll (original)
+++ llvm/trunk/test/CodeGen/Thumb2/thumb2-clz.ll Tue Oct 27 01:31:02 2009
@@ -1,6 +1,8 @@
-; RUN: llc < %s -march=thumb -mattr=+thumb2,+v7a | grep "clz " | count 1
+; RUN: llc < %s -march=thumb -mattr=+thumb2,+v7a | FileCheck %s
define i32 @f1(i32 %a) {
+; CHECK: f1:
+; CHECK: clz r
%tmp = tail call i32 @llvm.ctlz.i32(i32 %a)
ret i32 %tmp
}
Modified: llvm/trunk/test/CodeGen/Thumb2/thumb2-cmn2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Thumb2/thumb2-cmn2.ll?rev=85210&r1=85209&r2=85210&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Thumb2/thumb2-cmn2.ll (original)
+++ llvm/trunk/test/CodeGen/Thumb2/thumb2-cmn2.ll Tue Oct 27 01:31:02 2009
@@ -1,25 +1,33 @@
-; RUN: llc < %s -march=thumb -mattr=+thumb2 | grep "cmn\\.w " | grep {#187\\|#11141290\\|#-872363008\\|#1114112} | count 4
+; RUN: llc < %s -march=thumb -mattr=+thumb2 | FileCheck %s
; -0x000000bb = 4294967109
define i1 @f1(i32 %a) {
+; CHECK: f1:
+; CHECK: cmn.w {{r.*}}, #187
%tmp = icmp ne i32 %a, 4294967109
ret i1 %tmp
}
; -0x00aa00aa = 4283826006
define i1 @f2(i32 %a) {
+; CHECK: f2:
+; CHECK: cmn.w {{r.*}}, #11141290
%tmp = icmp eq i32 %a, 4283826006
ret i1 %tmp
}
; -0xcc00cc00 = 872363008
define i1 @f3(i32 %a) {
+; CHECK: f3:
+; CHECK: cmn.w {{r.*}}, #-872363008
%tmp = icmp ne i32 %a, 872363008
ret i1 %tmp
}
; -0x00110000 = 4293853184
define i1 @f4(i32 %a) {
+; CHECK: f4:
+; CHECK: cmn.w {{r.*}}, #1114112
%tmp = icmp eq i32 %a, 4293853184
ret i1 %tmp
}
Modified: llvm/trunk/test/CodeGen/Thumb2/thumb2-eor2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Thumb2/thumb2-eor2.ll?rev=85210&r1=85209&r2=85210&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Thumb2/thumb2-eor2.ll (original)
+++ llvm/trunk/test/CodeGen/Thumb2/thumb2-eor2.ll Tue Oct 27 01:31:02 2009
@@ -1,31 +1,41 @@
-; RUN: llc < %s -march=thumb -mattr=+thumb2 | grep "eor " | grep {#187\\|#11141290\\|#-872363008\\|#1114112\\|#-572662307} | count 5
+; RUN: llc < %s -march=thumb -mattr=+thumb2 | FileCheck %s
; 0x000000bb = 187
define i32 @f1(i32 %a) {
+; CHECK: f1:
+; CHECK: eor {{.*}}#187
%tmp = xor i32 %a, 187
ret i32 %tmp
}
; 0x00aa00aa = 11141290
define i32 @f2(i32 %a) {
+; CHECK: f2:
+; CHECK: eor {{.*}}#11141290
%tmp = xor i32 %a, 11141290
ret i32 %tmp
}
; 0xcc00cc00 = 3422604288
define i32 @f3(i32 %a) {
+; CHECK: f3:
+; CHECK: eor {{.*}}#-872363008
%tmp = xor i32 %a, 3422604288
ret i32 %tmp
}
; 0xdddddddd = 3722304989
define i32 @f4(i32 %a) {
+; CHECK: f4:
+; CHECK: eor {{.*}}#-572662307
%tmp = xor i32 %a, 3722304989
ret i32 %tmp
}
; 0x00110000 = 1114112
define i32 @f5(i32 %a) {
+; CHECK: f5:
+; CHECK: eor {{.*}}#1114112
%tmp = xor i32 %a, 1114112
ret i32 %tmp
}
Modified: llvm/trunk/test/CodeGen/Thumb2/thumb2-str_post.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/Thumb2/thumb2-str_post.ll?rev=85210&r1=85209&r2=85210&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/Thumb2/thumb2-str_post.ll (original)
+++ llvm/trunk/test/CodeGen/Thumb2/thumb2-str_post.ll Tue Oct 27 01:31:02 2009
@@ -1,9 +1,8 @@
-; RUN: llc < %s -march=thumb -mattr=+thumb2 | \
-; RUN: grep {strh .*\\\[.*\], #-4} | count 1
-; RUN: llc < %s -march=thumb -mattr=+thumb2 | \
-; RUN: grep {str .*\\\[.*\],} | count 1
+; RUN: llc < %s -march=thumb -mattr=+thumb2 | FileCheck %s
define i16 @test1(i32* %X, i16* %A) {
+; CHECK: test1:
+; CHECK: strh {{.*}}[{{.*}}], #-4
%Y = load i32* %X ; <i32> [#uses=1]
%tmp1 = trunc i32 %Y to i16 ; <i16> [#uses=1]
store i16 %tmp1, i16* %A
@@ -13,6 +12,8 @@
}
define i32 @test2(i32* %X, i32* %A) {
+; CHECK: test2:
+; CHECK: str {{.*}}[{{.*}}],
%Y = load i32* %X ; <i32> [#uses=1]
store i32 %Y, i32* %A
%tmp1 = ptrtoint i32* %A to i32 ; <i32> [#uses=1]
More information about the llvm-commits
mailing list