summaryrefslogtreecommitdiff
path: root/test/Transforms/InstCombine/phi.ll
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2012-04-27 17:50:22 +0000
committerDan Gohman <gohman@apple.com>2012-04-27 17:50:22 +0000
commit03e091f0b5f43beee12170efc00bbab86ffeb0dc (patch)
tree97aeaf6db27484a1e58a35584582d14a6ac89f71 /test/Transforms/InstCombine/phi.ll
parent04a09a461beb4ec629fe53e601b7665547ac35c3 (diff)
downloadllvm-03e091f0b5f43beee12170efc00bbab86ffeb0dc.tar.gz
llvm-03e091f0b5f43beee12170efc00bbab86ffeb0dc.tar.bz2
llvm-03e091f0b5f43beee12170efc00bbab86ffeb0dc.tar.xz
Reapply r155682, making constant folding more consistent, with a fix to work
properly with how the code handles all-undef PHI nodes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@155721 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms/InstCombine/phi.ll')
-rw-r--r--test/Transforms/InstCombine/phi.ll10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/Transforms/InstCombine/phi.ll b/test/Transforms/InstCombine/phi.ll
index 219545c2ea..1c307d430f 100644
--- a/test/Transforms/InstCombine/phi.ll
+++ b/test/Transforms/InstCombine/phi.ll
@@ -620,3 +620,13 @@ end:
; CHECK-NOT: phi i32
; CHECK: ret i1 %z
}
+
+; CHECK: @test27(
+; CHECK: ret i32 undef
+define i32 @test27(i1 %b) {
+entry:
+ br label %done
+done:
+ %y = phi i32 [ undef, %entry ]
+ ret i32 %y
+}