| 1 |
! This test checks the lowering of REQUIRES inside of an unnamed BLOCK DATA. |
| 2 |
! The symbol of the `symTab` scope of the `BlockDataUnit` PFT node is null in |
| 3 |
! this case, resulting in the inability to store the REQUIRES flags gathered in |
| 4 |
! it. |
| 5 |
|
| 6 |
! RUN: %flang_fc1 -emit-fir -fopenmp %s -o - | FileCheck %s |
| 7 |
! RUN: %flang_fc1 -emit-fir -fopenmp -fopenmp-is-target-device %s -o - | FileCheck %s |
| 8 |
! RUN: bbc -fopenmp -emit-fir %s -o - | FileCheck %s |
| 9 |
! RUN: bbc -fopenmp -fopenmp-is-target-device -emit-fir %s -o - | FileCheck %s |
| 10 |
! XFAIL: * |
| 11 |
|
| 12 |
!CHECK: module attributes { |
| 13 |
!CHECK-SAME: omp.requires = #omp<clause_requires unified_shared_memory> |
| 14 |
block data |
| 15 |
!$omp requires unified_shared_memory |
| 16 |
integer :: x |
| 17 |
common /block/ x |
| 18 |
data x / 10 / |
| 19 |
end |
| 20 |
|
| 21 |
subroutine f |
| 22 |
!$omp declare target |
| 23 |
end subroutine f |