1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
! PR fortran/40878
! { dg-do compile }
! { dg-options "-fopenmp" }
subroutine test1
integer :: j, k
integer :: m = 2
!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "Constant expression required" }
do k = 1, 2
do j = 1, 6
enddo
enddo
!$omp end parallel do
end
subroutine test2
integer :: j, k
integer :: m
m = 2
!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "Constant expression required" }
do k = 1, 2
do j = 1, 6
enddo
enddo
!$omp end parallel do
end
subroutine test3
integer :: j, k
integer, parameter :: m = 0
!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "not constant positive integer" }
do k = 1, 2
do j = 1, 6
enddo
enddo
!$omp end parallel do
end
subroutine test4
integer :: j, k
integer, parameter :: m = -2
!$omp parallel do collapse(m) schedule (static,1) ! { dg-error "not constant positive integer" }
do k = 1, 2
do j = 1, 6
enddo
enddo
!$omp end parallel do
end
subroutine test5
integer :: j, k
!$omp parallel do collapse(0) schedule (static,1) ! { dg-error "not constant positive integer" }
do k = 1, 2
do j = 1, 6
enddo
enddo
!$omp end parallel do
end
subroutine test6
integer :: j, k
!$omp parallel do collapse(-1) schedule (static,1) ! { dg-error "not constant positive integer" }
do k = 1, 2
do j = 1, 6
enddo
enddo
!$omp end parallel do
end
|