]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - test/Analysis/ScalarEvolution/2008-02-11-ReversedCondition.ll
Update LLVM to 93512.
[FreeBSD/FreeBSD.git] / test / Analysis / ScalarEvolution / 2008-02-11-ReversedCondition.ll
1 ; RUN: opt < %s -scalar-evolution -analyze -disable-output | grep {Loop %header: backedge-taken count is (0 smax %n)}
2
3 define void @foo(i32 %n) {
4 entry:
5         br label %header
6 header:
7         %i = phi i32 [ 0, %entry ], [ %i.inc, %next ]
8         %cond = icmp sgt i32 %n, %i
9         br i1 %cond, label %next, label %return
10 next:
11         %i.inc = add i32 %i, 1
12         br label %header
13 return:
14         ret void
15 }