Retro68/gcc/libgomp/testsuite/libgomp.oacc-c-c++-common/variable-not-offloaded.c
Wolfgang Thaller 6fbf4226da gcc-9.1
2019-06-20 20:10:10 +02:00

18 lines
255 B
C

/* { dg-do link } */
int var; /* { dg-error "'var' requires a 'declare' directive for use in a 'routine' function" } */
#pragma acc routine
void __attribute__((noinline, noclone))
foo (void)
{
var++;
}
int
main ()
{
#pragma acc parallel
foo ();
}