aboutsummaryrefslogtreecommitdiffstats
path: root/test/Transforms/JumpThreading/crash.ll
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-12-01 06:04:43 +0000
committerChris Lattner <sabre@nondot.org>2009-12-01 06:04:43 +0000
commit46875c0bfb77880ba4120eeed7caca7f1f7c1f69 (patch)
tree64085c809aadf89c23d16bab28ce4d8ec2fad43f /test/Transforms/JumpThreading/crash.ll
parent18518603f1acc26768eba40c53bcfc0e2fa85fec (diff)
downloadexternal_llvm-46875c0bfb77880ba4120eeed7caca7f1f7c1f69.zip
external_llvm-46875c0bfb77880ba4120eeed7caca7f1f7c1f69.tar.gz
external_llvm-46875c0bfb77880ba4120eeed7caca7f1f7c1f69.tar.bz2
fix PR5640 by tracking whether a block is the header of a loop more
precisely, which prevents us from infinitely peeling the loop. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@90211 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms/JumpThreading/crash.ll')
-rw-r--r--test/Transforms/JumpThreading/crash.ll20
1 files changed, 20 insertions, 0 deletions
diff --git a/test/Transforms/JumpThreading/crash.ll b/test/Transforms/JumpThreading/crash.ll
index 7e2a2a0..b2b9d69 100644
--- a/test/Transforms/JumpThreading/crash.ll
+++ b/test/Transforms/JumpThreading/crash.ll
@@ -192,3 +192,23 @@ bb61:
ret void
}
+
+; PR5640
+define fastcc void @test6(i1 %tmp, i1 %tmp1) nounwind ssp {
+entry:
+ br i1 %tmp, label %bb12, label %bb14
+
+bb12:
+ br label %bb14
+
+bb14:
+ %A = phi i1 [ %A, %bb13 ], [ true, %bb12 ], [%tmp1, %entry]
+ br label %bb13
+
+bb13:
+ br i1 %A, label %bb14, label %bb61
+
+
+bb61:
+ ret void
+}