As part of preparing for the switch to HLFIR lowering, all OpenMP FIR lowering tests are moved to a subdirectory in the OpenMP directory. Copies of these tests that work with HLFIR will be created during this week. After the switch the FIR lowering tests will be removed. All new tests should be added with the HLFIR flow.
13 lines
554 B
Fortran
13 lines
554 B
Fortran
!RUN: %flang_fc1 -emit-fir -fopenmp %s -o - | FileCheck %s --check-prefixes=HOST,ALL
|
|
!RUN: %flang_fc1 -emit-fir -fopenmp -fopenmp-is-target-device %s -o - | FileCheck %s --check-prefix=ALL
|
|
|
|
PROGRAM main
|
|
! HOST-DAG: %0 = fir.alloca f32 {bindc_name = "i", uniq_name = "_QFEi"}
|
|
REAL :: I
|
|
! ALL-DAG: fir.global internal @_QFEi {omp.declare_target = #omp.declaretarget<device_type = (any), capture_clause = (to)>} : f32 {
|
|
! ALL-DAG: %0 = fir.undefined f32
|
|
! ALL-DAG: fir.has_value %0 : f32
|
|
! ALL-DAG: }
|
|
!$omp declare target(I)
|
|
END
|