From c02019141cfe4e2bacdfa67262e84eee838f2e38 Mon Sep 17 00:00:00 2001 From: Kiran Kumar T P <50909805+kiranktp@users.noreply.github.com> Date: Fri, 7 Mar 2025 11:15:22 +0530 Subject: [PATCH] [LLVM-FLANG] [OpenMP] [Taskloop] - Add test case with cancel construct inside taskloop (#129862) Added a test case with cancel construct inside taskloop. Currently taskloop lowering is not supported so below error is issued: "not yet implemented: Taskloop construct" Once the lowering patch is merged, todo error should be issued for cancel construct. "not yet implemented: OpenMPCancelConstruct" --- flang/test/Lower/OpenMP/Todo/taskloop-cancel.f90 | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 flang/test/Lower/OpenMP/Todo/taskloop-cancel.f90 diff --git a/flang/test/Lower/OpenMP/Todo/taskloop-cancel.f90 b/flang/test/Lower/OpenMP/Todo/taskloop-cancel.f90 new file mode 100644 index 000000000000..5045c621e4d7 --- /dev/null +++ b/flang/test/Lower/OpenMP/Todo/taskloop-cancel.f90 @@ -0,0 +1,14 @@ +! RUN: %not_todo_cmd bbc -emit-fir -fopenmp -o - %s -fopenmp-version=50 2>&1 | FileCheck %s +! RUN: %not_todo_cmd %flang_fc1 -emit-fir -fopenmp -o - %s -fopenmp-version=50 2>&1 | FileCheck %s + +! CHECK: not yet implemented: Taskloop construct +subroutine omp_taskloop +integer :: i +!$omp parallel + !$omp taskloop + do i = 1, 10 + !$omp cancel taskgroup + end do + !$omp end taskloop +!$omp end parallel +end subroutine omp_taskloop