https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87725
Bug ID: 87725 Summary: OpenMP 4.5 clause schedule(simd,monotonic:static) not understood Product: gcc Version: 9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libgomp Assignee: unassigned at gcc dot gnu.org Reporter: as at cmplx dot uk CC: jakub at gcc dot gnu.org Target Milestone: --- OpenMP 4.5 specifications say that schedule clause can have 2 modifiers, specifically this should be valid: !$omp do schedule(simd,monotonic:static) But gfortran9 rejects this with: 21 | !$omp do schedule(simd,monotonic:static, n/nthr ) | 1 Error: Unclassifiable OpenMP directive at (1) Intel Fortran 18 does accept the above construct with 2 schedule modifiers. Using only a single modifier is accepted by gfortran9, i.e: !$omp do schedule( simd:static ) !$omp do schedule( monotonic:static ) are both fine. I guess this just hasn't been implemented yet? A complete program: use, intrinsic :: iso_fortran_env use :: omp_lib implicit none integer :: i, val, tid, nthr, sum, part, n write (*,*) "OMP version:", openmp_version n = 2**30 sum = 0 !$omp parallel default( none ) & !$omp private( tid, i, part, nthr ) & !$omp shared( sum, n ) part = 0 nthr = omp_get_num_threads() tid = omp_get_thread_num() write (*,*) tid, nthr ! !$omp do schedule(simd,monotonic:static, n/nthr ) !$omp do schedule(simd:static, n/nthr ) ! !$omp do schedule(monotonic:static, n/nthr ) do i=1,n part = part + 1 end do !$omp end do nowait !$omp atomic sum = sum + part !$omp end atomic !$omp end parallel write (*,*) sum, ( sum .eq. n ) end