OpenACC acc_on_device.
[official-gcc.git] / gcc / testsuite / gfortran.dg / goacc / acc_on_device-1.f95
blob9dfde26f76b98aab358c1abe6e2454ff6823a49c
1 ! Have to enable optimizations, as otherwise builtins won't be expanded.
2 ! { dg-additional-options "-O -fdump-rtl-expand" }
4 logical function f ()
5 implicit none
7 external acc_on_device
8 logical (4) acc_on_device
10 f = .false.
11 f = f .or. acc_on_device ()
12 f = f .or. acc_on_device (1, 2)
13 f = f .or. acc_on_device (3.14)
14 f = f .or. acc_on_device ("hello")
16 return
17 end function f
19 ! Unsuitable to be handled as a builtin, so we're expecting four calls.
20 ! { dg-final { scan-rtl-dump-times "\\\(call \[^\\n\]*\\\"acc_on_device" 4 "expand" } }
22 ! { dg-final { cleanup-rtl-dump "expand" } }