brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.4 KiB · caa8f3f Raw
105 lines · plain
1! Testing the Semantics of nested Loop Transformation Constructs2 3!RUN: %python %S/../test_errors.py %s %flang -fopenmp -fopenmp-version=514 5subroutine loop_transformation_construct16  implicit none7 8  !ERROR: OpenMP loop construct cannot apply to a fully unrolled loop9  !$omp do10  !ERROR: OpenMP loop construct should contain a DO-loop or a loop-nest-generating OpenMP construct11  !$omp unroll12end subroutine13 14subroutine loop_transformation_construct215  implicit none16  integer, parameter :: i = 517  integer :: x18  integer :: v(i)19 20  !$omp do21  !ERROR: At least one of SIZES clause must appear on the TILE directive22  !$omp tile23  do x = 1, i24    v(x) = v(x) * 225  end do26  !$omp end tile27  !$omp end do28end subroutine29 30subroutine loop_transformation_construct331  implicit none32  integer, parameter :: i = 533  integer :: x34  integer :: v(i)35 36  !$omp do37  !ERROR: Only loop-transforming OpenMP constructs are allowed inside OpenMP loop constructs38  !$omp parallel do39  do x = 1, i40    v(x) = v(x) * 241  end do42end subroutine43 44subroutine loop_transformation_construct445  implicit none46  integer, parameter :: i = 547  integer :: x48  integer :: v(i)49 50  !$omp do51  do x = 1, i52    v(x) = v(x) * 253  end do54  !ERROR: OpenMP loop construct should contain a DO-loop or a loop-nest-generating OpenMP construct55  !ERROR: At least one of SIZES clause must appear on the TILE directive56  !$omp tile57end subroutine58 59subroutine loop_transformation_construct560  implicit none61  integer, parameter :: i = 562  integer :: x63  integer :: v(i)64 65  !$omp do66  !ERROR: OpenMP loop construct cannot apply to a fully unrolled loop67  !ERROR: At least one of SIZES clause must appear on the TILE directive68  !$omp tile69  !$omp unroll full70  do x = 1, i71    v(x) = v(x) * 272  end do73end subroutine74 75subroutine loop_transformation_construct676  implicit none77  integer, parameter :: i = 578  integer :: x79  integer :: v(i)80 81  !$omp do82  !ERROR: OpenMP loop construct cannot apply to a fully unrolled loop83  !ERROR: At least one of SIZES clause must appear on the TILE directive84  !$omp tile85  !$omp unroll86  do x = 1, i87    v(x) = v(x) * 288  end do89end subroutine90 91subroutine loop_transformation_construct792  implicit none93  integer, parameter :: i = 594  integer :: x95  integer :: v(i)96 97  !$omp do98  !ERROR: At least one of SIZES clause must appear on the TILE directive99  !$omp tile100  !$omp unroll partial(2)101  do x = 1, i102    v(x) = v(x) * 2103  end do104end subroutine105