Skip to content

Commit de18f5e

Browse files
authored
[flang][OpenMP] Remove allocate from taskgroup in test (#92173)
Remove the `allocate`, because it needs to be used together with a privatizing clause. The only such clause for `taskgroup` is `task_reduction`, but it's not yet supported.
1 parent 3c3f6d8 commit de18f5e

File tree

1 file changed

+7
-10
lines changed

1 file changed

+7
-10
lines changed

flang/test/Lower/OpenMP/taskgroup.f90

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,14 @@
1-
! REQUIRES: openmp_runtime
2-
31
!RUN: %flang_fc1 -emit-hlfir -fopenmp %s -o - | FileCheck %s
42

3+
! The "allocate" clause has been removed, because it needs to be used
4+
! together with a privatizing clause. The only such clause for "taskgroup"
5+
! is "task_reduction", but it's not yet supported.
6+
57
!CHECK-LABEL: @_QPomp_taskgroup
68
subroutine omp_taskgroup
7-
use omp_lib
8-
integer :: allocated_x
9-
!CHECK: %[[ALLOC_X_REF:.*]] = fir.alloca i32 {bindc_name = "allocated_x", uniq_name = "_QFomp_taskgroupEallocated_x"}
10-
!CHECK-NEXT: %[[ALLOC_X_DECL:.*]]:2 = hlfir.declare %[[ALLOC_X_REF]] {uniq_name = "_QFomp_taskgroupEallocated_x"} : (!fir.ref<i32>) -> (!fir.ref<i32>, !fir.ref<i32>)
11-
!CHECK: %[[C4:.*]] = arith.constant 4 : i64
12-
13-
!CHECK: omp.taskgroup allocate(%[[C4]] : i64 -> %[[ALLOC_X_DECL]]#1 : !fir.ref<i32>)
14-
!$omp taskgroup allocate(omp_high_bw_mem_alloc: allocated_x)
9+
!CHECK: omp.taskgroup
10+
!$omp taskgroup
11+
!CHECK: omp.task
1512
!$omp task
1613
!CHECK: fir.call @_QPwork() {{.*}}: () -> ()
1714
call work()

0 commit comments

Comments
 (0)