1 ! RUN: bbc -fdebug-dump-pre-fir %s 2>&1 | FileCheck %s
3 ! Note: PFT dump output is fairly stable, including node indexes and
4 ! annotations, so all output is CHECKed.
6 ! CHECK: 1 Program <anonymous>
7 ! CHECK: 1 PrintStmt: print*
10 ! CHECK: <<DoConstruct>> -> 8
11 ! CHECK: 2 NonLabelDoStmt -> 7: do i = 1, 5
12 ! CHECK: <<IfConstruct>> -> 7
13 ! CHECK: 3 ^IfStmt [negate] -> 7: if(i <= 1 .or. i >= 5) cycle
14 ! CHECK: 6 ^PrintStmt: print*, i
16 ! CHECK: <<End IfConstruct>>
17 ! CHECK: 7 EndDoStmt -> 2: end do
18 ! CHECK: <<End DoConstruct>>
20 if (i
<= 1 .or
. i
>= 5) cycle
24 ! CHECK: 8 PrintStmt: print*
27 ! CHECK: <<DoConstruct>> -> 15
28 ! CHECK: 9 NonLabelDoStmt -> 14: do i = 1, 5
29 ! CHECK: <<IfConstruct>> -> 14
30 ! CHECK: 10 ^IfStmt [negate] -> 14: if(i <= 1 .or. i >= 5) cycle
31 ! CHECK: 13 ^PrintStmt: print*, i
33 ! CHECK: <<End IfConstruct>>
34 ! CHECK: 14 EndDoStmt -> 9: 2 end do
35 ! CHECK: <<End DoConstruct>>
37 if (i
<= 1 .or
. i
>= 5) cycle
41 ! CHECK: 15 PrintStmt: print*
44 ! CHECK:<<DoConstruct!>> -> 30
45 ! CHECK: 16 NonLabelDoStmt -> 29: outer: do i = 1, 3
46 ! CHECK: <<DoConstruct!>> -> 29
47 ! CHECK: 17 ^NonLabelDoStmt -> 28: inner: do j = 1, 5
48 ! CHECK: <<IfConstruct!>> -> 28
49 ! CHECK: 18 ^IfStmt [negate] -> 28: if(j <= 1 .or. j >= 5) cycle inner
50 ! CHECK: <<IfConstruct!>> -> 28
51 ! CHECK: 21 ^IfStmt [negate] -> 28: if(j == 3) goto 3
52 ! CHECK: <<IfConstruct!>> -> 27
53 ! CHECK: 24 ^IfStmt -> 27: if(j == 4) cycle outer
54 ! CHECK: 25 ^CycleStmt! -> 29: cycle outer
56 ! CHECK: <<End IfConstruct!>>
57 ! CHECK: 27 ^PrintStmt: print*, j
59 ! CHECK: <<End IfConstruct!>>
61 ! CHECK: <<End IfConstruct!>>
62 ! CHECK: 28 ^EndDoStmt -> 17: 3 end do inner
63 ! CHECK: <<End DoConstruct!>>
64 ! CHECK: 29 ^EndDoStmt -> 16: end do outer
65 ! CHECK:<<End DoConstruct!>>
68 if (j
<= 1 .or
. j
>= 5) cycle inner
70 if (j
== 4) cycle outer
75 ! CHECK: 30 ^PrintStmt: print*
78 ! CHECK:<<DoConstruct>> -> 40
79 ! CHECK: 31 NonLabelDoStmt -> 39: do i = 1, 5
80 ! CHECK: <<IfConstruct>> -> 39
81 ! CHECK: 32 ^IfStmt [negate] -> 39: if(i == 3) goto 4
82 ! CHECK: <<IfConstruct>> -> 39
83 ! CHECK: 35 ^IfStmt [negate] -> 39: if(i <= 1 .or. i >= 5) cycle
84 ! CHECK: 38 ^PrintStmt: print*, i
86 ! CHECK: <<End IfConstruct>>
88 ! CHECK: <<End IfConstruct>>
89 ! CHECK: 39 EndDoStmt -> 31: 4 end do
90 ! CHECK:<<End DoConstruct>>
93 if (i
<= 1 .or
. i
>= 5) cycle