CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
215 lines
6.5 KiB
Fortran
215 lines
6.5 KiB
Fortran
! RUN: %python %S/../test_errors.py %s %flang -fopenmp
|
|
! OpenMP Version 4.5
|
|
! 2.7.1 Loop Construct restrictions on single directive.
|
|
|
|
|
|
program omp_do
|
|
|
|
integer n
|
|
integer i,j,k
|
|
!$omp do
|
|
do i=1,10
|
|
if( i == 5 ) then
|
|
cycle
|
|
end if
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do j=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end do
|
|
|
|
!$omp parallel do
|
|
do i=1,10
|
|
if( i == 9 ) then
|
|
end if
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do j=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end parallel do
|
|
|
|
!$omp parallel do simd
|
|
do i=1,10
|
|
if( i == 5 ) then
|
|
cycle
|
|
end if
|
|
!ERROR: The only OpenMP constructs that can be encountered during execution of a 'SIMD' region are the `ATOMIC` construct, the `LOOP` construct, the `SIMD` construct, the `SCAN` construct and the `ORDERED` construct with the `SIMD` clause.
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do j=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end parallel do simd
|
|
|
|
!WARNING: `DISTRIBUTE` must be dynamically enclosed in a `TEAMS` region.
|
|
!$omp distribute parallel do
|
|
do i=1,10
|
|
if( i == 3 ) then
|
|
cycle
|
|
end if
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do j=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end distribute parallel do
|
|
|
|
!WARNING: `DISTRIBUTE` must be dynamically enclosed in a `TEAMS` region.
|
|
!$omp distribute parallel do simd
|
|
do i=1,10
|
|
if( i == 3 ) then
|
|
cycle
|
|
end if
|
|
!ERROR: The only OpenMP constructs that can be encountered during execution of a 'SIMD' region are the `ATOMIC` construct, the `LOOP` construct, the `SIMD` construct, the `SCAN` construct and the `ORDERED` construct with the `SIMD` clause.
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do j=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end distribute parallel do simd
|
|
|
|
!$omp target parallel do
|
|
do i=1,10
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do j=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end target parallel do
|
|
|
|
!$omp target parallel do simd
|
|
do i=1,10
|
|
!ERROR: The only OpenMP constructs that can be encountered during execution of a 'SIMD' region are the `ATOMIC` construct, the `LOOP` construct, the `SIMD` construct, the `SCAN` construct and the `ORDERED` construct with the `SIMD` clause.
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do j=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end target parallel do simd
|
|
|
|
!$omp target teams distribute parallel do
|
|
do i=1,10
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do j=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end target teams distribute parallel do
|
|
|
|
!$omp target teams distribute parallel do simd
|
|
do i=1,10
|
|
!ERROR: The only OpenMP constructs that can be encountered during execution of a 'SIMD' region are the `ATOMIC` construct, the `LOOP` construct, the `SIMD` construct, the `SCAN` construct and the `ORDERED` construct with the `SIMD` clause.
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do j=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end target teams distribute parallel do simd
|
|
|
|
!$omp do
|
|
do i=1,10
|
|
!$omp task
|
|
do j=1,10
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do k=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end task
|
|
end do
|
|
!$omp end do
|
|
|
|
!$omp do
|
|
do i=1,10
|
|
!$omp parallel
|
|
do j=1,10
|
|
!$omp single
|
|
do k=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end parallel
|
|
end do
|
|
!$omp end do
|
|
|
|
!$omp do
|
|
do i=1,10
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do j=1,10
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do k=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
end do
|
|
!$omp end single
|
|
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
do k=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end single
|
|
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp do
|
|
do k=1,10
|
|
print *,"hello"
|
|
end do
|
|
!$omp end do
|
|
end do
|
|
!$omp end do
|
|
|
|
!$omp parallel default(shared)
|
|
!$omp do
|
|
do i = 1, n
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
call work(i, 1)
|
|
!$omp end single
|
|
end do
|
|
!$omp end do
|
|
!$omp end parallel
|
|
|
|
!$omp parallel default(shared)
|
|
!$omp do
|
|
do i = 1, n
|
|
!$omp task
|
|
do j=1,10
|
|
!ERROR: A worksharing region may not be closely nested inside a worksharing, explicit task, taskloop, critical, ordered, atomic, or master region
|
|
!$omp single
|
|
call work(i, 1)
|
|
!$omp end single
|
|
end do
|
|
!$omp end task
|
|
end do
|
|
!$omp end do
|
|
!$omp end parallel
|
|
|
|
end program omp_do
|