Debian Codegraph @

gcc/testsuite/gfortran.dg/gomp/scan-9.f90

raw
1 subroutine foo (c, d, a)
2 integer :: i, a, c(64), d(64)
3 !$omp do reduction (inscan, +: a)
4 !$omp tile sizes (2)
5 do i = 1, 64
6 a = a + c(i)
7 !$omp scan inclusive (a) ! { dg-error "Unexpected !\\\$OMP SCAN at \\\(1\\\) outside loop construct with 'inscan' REDUCTION clause" }
8 d(i) = a
9 end do
10 end subroutine foo
11
12 subroutine bar (c, d, a)
13 integer :: i, j, a, c(64, 64), d(64, 64)
14 !$omp do collapse (2) reduction (inscan, +: a)
15 do i = 1, 64
16 !$omp tile sizes (2)
17 do j = 1, 64
18 d(i, j) = a
19 !$omp scan exclusive (a) ! { dg-error "Unexpected !\\\$OMP SCAN at \\\(1\\\) outside loop construct with 'inscan' REDUCTION clause" }
20 a = a + c(i, j)
21 end do
22 end do
23 end subroutine bar
24
25 subroutine baz (c, d, a)
26 integer :: i, a, c(64), d(64)
27 !$omp do reduction (inscan, +: a)
28 !$omp unroll partial (2)
29 do i = 1, 64
30 d(i) = a
31 !$omp scan exclusive (a) ! { dg-error "Unexpected !\\\$OMP SCAN at \\\(1\\\) outside loop construct with 'inscan' REDUCTION clause" }
32 a = a + c(i)
33 end do
34 end subroutine baz
35
36 subroutine qux (c, d, a)
37 integer :: i, j, a, c(64, 64), d(64, 64)
38 !$omp do collapse (2) reduction (inscan, +: a)
39 do i = 1, 64
40 !$omp tile sizes (2)
41 do j = 1, 64
42 a = a + c(i, j)
43 !$omp scan inclusive (a) ! { dg-error "Unexpected !\\\$OMP SCAN at \\\(1\\\) outside loop construct with 'inscan' REDUCTION clause" }
44 d(i, j) = a
45 end do
46 end do
47 end subroutine qux