3 ! RUN: bbc -emit-fir -hlfir=false %s -o - | FileCheck %s
5 !*** Test forall targeted by label
6 subroutine test4_forall_construct()
11 if (a(1) > 3) goto 200
14 end subroutine test4_forall_construct
16 ! CHECK-LABEL: func @_QPtest4_forall_construct
18 ! CHECK: ^bb1: // 2 preds: ^bb0, ^bb2
19 ! CHECK: %{{.*}} = fir.do_loop
20 ! CHECK: cf.cond_br %{{.*}}, ^bb2, ^bb3
21 ! CHECK: ^bb2: // pred: ^bb1
23 ! CHECK: ^bb3: // pred: ^bb1
25 ! CHECK: ^bb4: // pred: ^bb3
28 subroutine test4_forall_construct2()
30 100 forall (i
=1:2) a(i
) = a(i
) + 1
31 if (a(1) > 3) goto 200
34 end subroutine test4_forall_construct2
36 ! CHECK-LABEL: func @_QPtest4_forall_construct2
38 ! CHECK: ^bb1: // 2 preds: ^bb0, ^bb2
39 ! CHECK: %{{.*}} = fir.do_loop
40 ! CHECK: cf.cond_br %{{.*}}, ^bb2, ^bb3
41 ! CHECK: ^bb2: // pred: ^bb1
43 ! CHECK: ^bb3: // pred: ^bb1
45 ! CHECK: ^bb4: // pred: ^bb3