gcc/libgomp/testsuite/libgomp.oacc-c-c++-common/lib-10.c
Thomas Schwinge ecd4fd4382 libgomp testsuite: Remove some explicit acc_device_nvidia usage.
libgomp/
	* testsuite/libgomp.oacc-c-c++-common/lib-1.c: Remove explicit
	acc_device_nvidia usage.
	* testsuite/libgomp.oacc-c-c++-common/lib-10.c: Likewise.
	* testsuite/libgomp.oacc-c-c++-common/lib-2.c: Likewise.
	* testsuite/libgomp.oacc-c-c++-common/lib-9.c: Likewise.

From-SVN: r229381
2015-10-26 17:24:54 +01:00

52 lines
664 B
C

/* { dg-do run } */
#include <stdlib.h>
#include <openacc.h>
int
main (int argc, char **argv)
{
void *d;
acc_device_t devtype = acc_device_default;
acc_init (devtype);
d = acc_malloc (0);
if (d != NULL)
abort ();
acc_free (0);
acc_shutdown (devtype);
acc_set_device_type (devtype);
d = acc_malloc (0);
if (d != NULL)
abort ();
acc_shutdown (devtype);
acc_init (devtype);
d = acc_malloc (1024);
if (d == NULL)
abort ();
acc_free (d);
acc_shutdown (devtype);
acc_set_device_type (devtype);
d = acc_malloc (1024);
if (d == NULL)
abort ();
acc_free (d);
acc_shutdown (devtype);
return 0;
}