Fix gcc.c-torture/execute/ieee/cdivchkf.c on hpux
[official-gcc.git] / libgomp / testsuite / libgomp.fortran / teams1.f90
blob886765ab0afae45bec668cee6221304dd6d46c11
1 ! { dg-additional-options "-Wno-deprecated-declarations" }
3 program teams1
4 use omp_lib
5 integer :: i
6 !$omp teams thread_limit (2)
7 !$omp distribute dist_schedule(static,1)
8 do i = 1, 1
9 if (omp_in_parallel ()) stop 1
10 if (omp_get_level () .ne. 0) stop 2
11 if (omp_get_ancestor_thread_num (0) .ne. 0) stop 3
12 if (omp_get_ancestor_thread_num (1) .ne. -1) stop 4
13 call omp_set_dynamic (.false.)
14 call omp_set_nested (.true.)
15 end do
16 !$omp parallel num_threads (2)
17 if (.not. omp_in_parallel ()) stop 5
18 if (omp_get_level () .ne. 1) stop 6
19 if (omp_get_ancestor_thread_num (0) .ne. 0) stop 7
20 if (omp_get_ancestor_thread_num (1) &
21 & .ne. omp_get_thread_num ()) stop 8
22 if (omp_get_ancestor_thread_num (2) .ne. -1) stop 9
23 !$omp end parallel
24 !$omp end teams
25 end program