Convert .cvsignore files
[oota-llvm.git] / test / Transforms / CorrelatedExprs / 2002-10-08-DominatorTest2.ll
1 ; Simple test to make sure dominators are updated properly
2 ; RUN: llvm-upgrade < %s | llvm-as | opt -cee
3
4 implementation   ; Functions:
5
6 int %test(int %A, int %B, bool %c0) {
7 Start:          ; No predecessors!
8         %c1 = seteq int %A, %B          ; <bool> [#uses=1]
9         br bool %c1, label %Eq, label %Start_crit_edge
10
11 Start_crit_edge:                ; preds = %Start
12         br label %Loop
13
14 Eq:             ; preds = %Start
15         br label %Loop
16
17 Loop:           ; preds = %Bottom, %Eq, %Start_crit_edge
18         %Z = phi int [ %A, %Start_crit_edge ], [ %B, %Eq ];, [ %Z, %Bottom ]            ; <int> [#uses=2]
19         %c2 = setge int %A, %B          ; <bool> [#uses=1]
20         br bool %c2, label %Forwarded, label %Loop_crit_edge
21
22 Loop_crit_edge:         ; preds = %Loop
23         %X = seteq int %Z, 7
24         br bool %X, label %Forwarded, label %Bottom
25
26 Forwarded:              ; preds = %Loop
27         %Z2 = phi int [ %Z, %Loop ], [%Z, %Loop_crit_edge]              ; <int> [#uses=1]
28         call int %test( int %Z, int %Z2, bool true )            ; <int>:0 [#uses=0]
29         br label %Bottom
30
31 Bottom:         ; preds = %Forwarded, %Loop_crit_edge
32         ret int %Z
33         ;br label %Loop
34 }