Break circular dependency between FIR dialect and utilities
[llvm-project.git] / flang / test / Semantics / doconcurrent02.f90
blob2473b3ee0b7458205b9cf4f6874c2d77936899a5
1 ! when the loops are not DO CONCURRENT
3 ! RUN: not %flang_fc1 -fdebug-unparse-with-symbols %s 2>&1 | FileCheck %s
4 ! CHECK-NOT: image control statement not allowed in DO CONCURRENT
5 ! CHECK-NOT: RETURN not allowed in DO CONCURRENT
6 ! CHECK-NOT: call to impure procedure in DO CONCURRENT not allowed
7 ! CHECK-NOT: IEEE_GET_FLAG not allowed in DO CONCURRENT
8 ! CHECK-NOT: ADVANCE specifier not allowed in DO CONCURRENT
9 ! CHECK-NOT: SYNC ALL
10 ! CHECK-NOT: SYNC IMAGES
12 module ieee_exceptions
13 interface
14 subroutine ieee_get_flag(i, j)
15 integer :: i, j
16 end subroutine ieee_get_flag
17 end interface
18 end module ieee_exceptions
20 subroutine do_concurrent_test1(i,n)
21 implicit none
22 integer :: i, n
23 do 10 i = 1,n
24 SYNC ALL
25 SYNC IMAGES (*)
26 return
27 10 continue
28 end subroutine do_concurrent_test1
30 subroutine do_concurrent_test2(i,j,n,flag)
31 use ieee_exceptions
32 implicit none
33 integer :: i, j, n, flag, flag2
34 do i = 1,n
35 change team (j)
36 call ieee_get_flag(flag, flag2)
37 end team
38 write(*,'(a35)',advance='no')
39 end do
40 end subroutine do_concurrent_test2