Debian Codegraph @

flang/test/Semantics/OpenMP/device-clause01.f90

raw
1 ! RUN: %python %S/../test_errors.py %s %flang -fopenmp
2 ! OpenMP Version 5.2
3 ! 13.2 Device clause
4
5 subroutine foo
6
7 integer :: a
8
9 !$omp target device(ancestor:0)
10 !$omp end target
11 !$omp target device(device_num:0)
12 !$omp end target
13
14 !ERROR: The ANCESTOR device-modifier must not appear on the DEVICE clause on any directive other than the TARGET construct. Found on TARGET DATA construct.
15 !$omp target data device(ancestor:0) map(tofrom:a)
16 !$omp end target data
17 !$omp target data device(device_num:0) map(tofrom:a)
18 !$omp end target data
19
20
21 !ERROR: The ANCESTOR device-modifier must not appear on the DEVICE clause on any directive other than the TARGET construct. Found on TARGET ENTER DATA construct.
22 !$omp target enter data device(ancestor:0) map(to:a)
23 !$omp target exit data map(from:a)
24 !$omp target enter data device(device_num:0) map(to:a)
25 !$omp target exit data map(from:a)
26
27 !ERROR: The ANCESTOR device-modifier must not appear on the DEVICE clause on any directive other than the TARGET construct. Found on TARGET UPDATE construct.
28 !$omp target update device(ancestor:0) to(a)
29 !$omp target update device(device_num:0) to(a)
30
31 end subroutine foo