summaryrefslogtreecommitdiff
path: root/test/Transforms/LoopSimplify/hardertest.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/Transforms/LoopSimplify/hardertest.ll')
-rw-r--r--test/Transforms/LoopSimplify/hardertest.ll15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/Transforms/LoopSimplify/hardertest.ll b/test/Transforms/LoopSimplify/hardertest.ll
new file mode 100644
index 000000000000..6ee0567dbc81
--- /dev/null
+++ b/test/Transforms/LoopSimplify/hardertest.ll
@@ -0,0 +1,15 @@
+; RUN: llvm-as < %s | opt -loopsimplify
+
+define void @foo(i1 %C) {
+ br i1 %C, label %T, label %F
+T: ; preds = %0
+ br label %Loop
+F: ; preds = %0
+ br label %Loop
+Loop: ; preds = %L2, %Loop, %F, %T
+ %Val = phi i32 [ 0, %T ], [ 1, %F ], [ 2, %Loop ], [ 3, %L2 ] ; <i32> [#uses=0]
+ br i1 %C, label %Loop, label %L2
+L2: ; preds = %Loop
+ br label %Loop
+}
+