| 1 |
module m0 |
| 2 |
integer :: x |
| 3 |
end module m0 |
| 4 |
|
| 5 |
module m ! { dg-error "has OpenMP device constructs/routines but does not set !.OMP REQUIRES UNIFIED_SHARED_MEMORY but other program units do" } |
| 6 |
!$omp requires reverse_offload |
| 7 |
contains |
| 8 |
subroutine foo |
| 9 |
interface |
| 10 |
subroutine bar2 |
| 11 |
!$omp requires dynamic_allocators |
| 12 |
end subroutine |
| 13 |
end interface |
| 14 |
!$omp target |
| 15 |
call bar2() |
| 16 |
!$omp end target |
| 17 |
end subroutine foo |
| 18 |
end module m |
| 19 |
|
| 20 |
subroutine bar ! { dg-error "has OpenMP device constructs/routines but does not set !.OMP REQUIRES REVERSE_OFFLOAD but other program units do" } |
| 21 |
!use m |
| 22 |
!$omp requires unified_shared_memory |
| 23 |
!$omp declare target |
| 24 |
end subroutine bar |
| 25 |
|
| 26 |
subroutine foobar ! { dg-error "has OpenMP device constructs/routines but does not set !.OMP REQUIRES REVERSE_OFFLOAD but other program units do" } |
| 27 |
use m0 |
| 28 |
!$omp requires unified_shared_memory |
| 29 |
!$omp target enter data map(to:x) |
| 30 |
end subroutine foobar |