brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.3 KiB · ec6a3bd Raw
42 lines · plain
1!RUN: %python %S/../test_errors.py %s %flang -fopenmp2! OpenMP Version 4.53! 2.7.1 Collapse Clause4program omp_doCollapse5  integer:: i,j6  !ERROR: The value of the parameter in the COLLAPSE or ORDERED clause must not be larger than the number of nested loops following the construct.7  !$omp do collapse(3)8  do i = 1,109    do j = 1, 1010      print *, "hello"11    end do12  end do13  !$omp end do14 15  do i = 1,1016    do j = 1, 1017      !ERROR: The value of the parameter in the COLLAPSE or ORDERED clause must not be larger than the number of nested loops following the construct.18      !$omp do collapse(2)19      do k = 1, 1020        print *, "hello"21      end do22      !$omp end do23    end do24  end do25 26  !$omp parallel do collapse(2)27    do i = 1, 328      !ERROR: Loop control is not present in the DO LOOP29      !ERROR: The associated loop of a loop-associated directive cannot be a DO without control.30      do31      end do32    end do33 34  !ERROR: The value of the parameter in the COLLAPSE or ORDERED clause must not be larger than the number of nested loops following the construct.35  !ERROR: At most one COLLAPSE clause can appear on the SIMD directive36  !$omp simd collapse(2) collapse(1)37  do i = 1, 438    j = j + i + 139  end do40  !$omp end simd41end program omp_doCollapse42