2010-12-20 Tobias Burnus <burnus@net-b.de>
[official-gcc.git] / gcc / testsuite / gfortran.dg / gomp / pr43337.f90
blobf07ccb441bedb118830af040b8f5d1b589a2ce11
1 ! PR middle-end/43337
2 ! { dg-do compile }
3 ! { dg-options "-fopenmp -O2 -g" }
5 subroutine pr43337
6 integer :: a, b(10)
7 call foo (b)
8 call bar (b)
9 contains
10 subroutine foo (b)
11 integer :: b(10)
12 !$omp parallel if (.false.)
13 !$omp task if (.false.) shared(b)
14 do a = 1, 10
15 b(a) = 1
16 end do
17 !$omp end task
18 !$omp end parallel
19 end subroutine foo
20 subroutine bar (b)
21 integer :: b(10)
22 !$omp parallel if (.false.)
23 !$omp parallel if (.false.)
24 do a = 1, 10
25 b(a) = 1
26 end do
27 !$omp end parallel
28 !$omp end parallel
29 end subroutine bar
30 end subroutine pr43337