flang/test/Semantics/OpenACC/acc-routine-validity02.f90
raw| 1 | ! RUN: %python %S/../test_errors.py %s %flang -fopenacc |
| 2 | |
| 3 | ! Check acc routine in the top level. |
| 4 | |
| 5 | subroutine sub1(a, n) |
| 6 | integer :: n |
| 7 | real :: a(n) |
| 8 | end subroutine sub1 |
| 9 | |
| 10 | !$acc routine(sub1) |
| 11 | |
| 12 | !dir$ value=1 |
| 13 | program test |
| 14 | integer, parameter :: N = 10 |
| 15 | real :: a(N) |
| 16 | call sub1(a, N) |
| 17 | end program |