Support -std=f2018
[official-gcc.git] / libgomp / testsuite / libgomp.fortran / declare-target-2.f90
blobf8d3ab2b60649865bce93765fcd4372ee8b96fe1
1 ! Don't compile this anywhere, it is just auxiliary
2 ! file compiled together with declare-target-1.f90
3 ! to verify inter-CU module handling of omp declare target.
4 ! { dg-do compile { target { lp64 && { ! lp64 } } } }
6 subroutine foo
7 use declare_target_1_mod
9 var_x = 10
10 !$omp target update to(var_x)
12 !$omp target
13 var_x = var_x * 2;
14 !$omp end target
16 !$omp target update from(var_x)
17 if (var_x /= 20) call abort
18 end subroutine foo