aboutsummaryrefslogtreecommitdiffstats
path: root/test/Transforms/FunctionAttrs
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2013-02-11 08:34:57 +0000
committerBill Wendling <isanbard@gmail.com>2013-02-11 08:34:57 +0000
commit595ef3e314e4c40b1f8b6b4f90b418a30a637242 (patch)
tree628e3436e0d25a4f7f8239713e8cd5fe6acece00 /test/Transforms/FunctionAttrs
parentab39afa9d9b99c61842c8e3d0eb706bd16efdcf3 (diff)
downloadexternal_llvm-595ef3e314e4c40b1f8b6b4f90b418a30a637242.zip
external_llvm-595ef3e314e4c40b1f8b6b4f90b418a30a637242.tar.gz
external_llvm-595ef3e314e4c40b1f8b6b4f90b418a30a637242.tar.bz2
FileCheck-ize the tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174865 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms/FunctionAttrs')
-rw-r--r--test/Transforms/FunctionAttrs/2008-09-03-ReadNone.ll6
-rw-r--r--test/Transforms/FunctionAttrs/2008-09-03-ReadOnly.ll8
2 files changed, 10 insertions, 4 deletions
diff --git a/test/Transforms/FunctionAttrs/2008-09-03-ReadNone.ll b/test/Transforms/FunctionAttrs/2008-09-03-ReadNone.ll
index 946453f..2e88a13 100644
--- a/test/Transforms/FunctionAttrs/2008-09-03-ReadNone.ll
+++ b/test/Transforms/FunctionAttrs/2008-09-03-ReadNone.ll
@@ -1,17 +1,21 @@
-; RUN: opt < %s -basicaa -functionattrs -S | grep readnone | count 4
+; RUN: opt < %s -basicaa -functionattrs -S | FileCheck %s
@x = global i32 0
+; CHECK: declare i32 @e() readnone
declare i32 @e() readnone
+; CHECK: define i32 @f() readnone
define i32 @f() {
%tmp = call i32 @e( ) ; <i32> [#uses=1]
ret i32 %tmp
}
+; CHECK: define i32 @g() readnone
define i32 @g() readonly {
ret i32 0
}
+; CHECK: define i32 @h() readnone
define i32 @h() readnone {
%tmp = load i32* @x ; <i32> [#uses=1]
ret i32 %tmp
diff --git a/test/Transforms/FunctionAttrs/2008-09-03-ReadOnly.ll b/test/Transforms/FunctionAttrs/2008-09-03-ReadOnly.ll
index 22eca13..0b03fc8 100644
--- a/test/Transforms/FunctionAttrs/2008-09-03-ReadOnly.ll
+++ b/test/Transforms/FunctionAttrs/2008-09-03-ReadOnly.ll
@@ -1,9 +1,11 @@
-; RUN: opt < %s -basicaa -functionattrs -S | grep readonly | count 2
+; RUN: opt < %s -basicaa -functionattrs -S | FileCheck %s
+; CHECK: define i32 @f() readonly
define i32 @f() {
entry:
- %tmp = call i32 @e( ) ; <i32> [#uses=1]
- ret i32 %tmp
+ %tmp = call i32 @e( )
+ ret i32 %tmp
}
+; CHECK: declare i32 @e() readonly
declare i32 @e() readonly