[llvm-commits] CVS: llvm/test/Regression/Transforms/IndVarsSimplify/loop_evaluate_1.ll
Chris Lattner
lattner at cs.uiuc.edu
Sat Apr 17 18:41:54 PDT 2004
Changes in directory llvm/test/Regression/Transforms/IndVarsSimplify:
loop_evaluate_1.ll added (r1.1)
---
Log message:
New testcase
---
Diffs of the changes: (+21 -0)
Index: llvm/test/Regression/Transforms/IndVarsSimplify/loop_evaluate_1.ll
diff -c /dev/null llvm/test/Regression/Transforms/IndVarsSimplify/loop_evaluate_1.ll:1.1
*** /dev/null Sat Apr 17 18:01:01 2004
--- llvm/test/Regression/Transforms/IndVarsSimplify/loop_evaluate_1.ll Sat Apr 17 18:00:51 2004
***************
*** 0 ****
--- 1,21 ----
+ ; RUN: llvm-as < %s | opt -indvars -adce -simplifycfg | llvm-dis | not grep br
+ ;
+ ; Testcase distilled from 256.bzip2
+
+ int %main() {
+ entry:
+ br label %loopentry
+
+ loopentry: ; preds = %entry, %loopentry
+ %indvar1 = phi uint [ 0, %entry ], [ %indvar.next2, %loopentry ] ; <uint> [#uses=1]
+ %h.0 = phi int [ %tmp.2, %loopentry ], [ 4, %entry ] ; <int> [#uses=1]
+ %tmp.1 = mul int %h.0, 3 ; <int> [#uses=1]
+ %tmp.2 = add int %tmp.1, 1 ; <int> [#uses=1]
+ %indvar.next2 = add uint %indvar1, 1 ; <uint> [#uses=2]
+ %exitcond3 = setne uint %indvar.next2, 4 ; <bool> [#uses=1]
+ br bool %exitcond3, label %loopentry, label %loopexit
+
+ loopexit: ; preds = %loopentry
+ ret int %tmp.2
+ }
+
More information about the llvm-commits
mailing list