summaryrefslogtreecommitdiff
path: root/test/Transforms/InstCombine/select.ll
diff options
context:
space:
mode:
authorDuncan Sands <baldrick@free.fr>2010-11-15 16:43:28 +0000
committerDuncan Sands <baldrick@free.fr>2010-11-15 16:43:28 +0000
commit503dcc982227893c532f03cbd6449e01a1739df3 (patch)
tree832b854dfd27ba29b7af59e867e986c655374d4c /test/Transforms/InstCombine/select.ll
parent94ed5fca3f5ab5acb74e70b8393b837131e7110c (diff)
downloadllvm-503dcc982227893c532f03cbd6449e01a1739df3.tar.gz
llvm-503dcc982227893c532f03cbd6449e01a1739df3.tar.bz2
llvm-503dcc982227893c532f03cbd6449e01a1739df3.tar.xz
Move PHI tests to phi.ll, out of select.ll.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119153 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms/InstCombine/select.ll')
-rw-r--r--test/Transforms/InstCombine/select.ll51
1 files changed, 2 insertions, 49 deletions
diff --git a/test/Transforms/InstCombine/select.ll b/test/Transforms/InstCombine/select.ll
index c1c1f08383..120d158aa6 100644
--- a/test/Transforms/InstCombine/select.ll
+++ b/test/Transforms/InstCombine/select.ll
@@ -500,59 +500,12 @@ define i1 @test40(i1 %cond) {
; CHECK: ret i1 false
}
-define i1 @test41(i1 %cond) {
- %zero = alloca i32
- %one = alloca i32
- br i1 %cond, label %true, label %false
-true:
- br label %ret
-false:
- br label %ret
-ret:
- %ptr = phi i32* [ %zero, %true ] , [ %one, %false ]
- %isnull = icmp eq i32* %ptr, null
- ret i1 %isnull
-; CHECK: @test41
-; CHECK: ret i1 false
-}
-
-define i1 @test42(i1 %cond, double %x) {
- br i1 %cond, label %true, label %false
-true:
- br label %ret
-false:
- br label %ret
-ret:
- %p = phi double [ %x, %true ], [ 0x7FF0000000000000, %false ]; RHS = +infty
- %cmp = fcmp ule double %x, %p
- ret i1 %cmp
-; CHECK: @test42
-; CHECK: ret i1 true
-}
-
-define i1 @test43(i1 %cond) {
- %a = alloca i32
- %b = alloca i32
- %c = alloca i32
- br i1 %cond, label %true, label %false
-true:
- br label %ret
-false:
- br label %ret
-ret:
- %p = phi i32* [ %a, %true ], [ %b, %false ]
- %r = icmp eq i32* %p, %c
- ret i1 %r
-; CHECK: @test43
-; CHECK: ret i1 false
-}
-
-define i32 @test44(i1 %cond, i32 %x, i32 %y) {
+define i32 @test41(i1 %cond, i32 %x, i32 %y) {
%z = and i32 %x, %y
%s = select i1 %cond, i32 %y, i32 %z
%r = and i32 %x, %s
ret i32 %r
-; CHECK: @test44
+; CHECK: @test41
; CHECK: %r = and i32 %x, %y
; CHECK: ret i32 %r
}