gcc/libgomp/testsuite/libgomp.oacc-c-c++-common/lib-4.c
Julian Brown 9fb5fd444b oacc-init.c (resolve_device): Add FAIL_IS_ERROR argument.
* oacc-init.c (resolve_device): Add FAIL_IS_ERROR argument. Update
	function comment. Only call gomp_fatal if new argument is true.
	(acc_dev_num_out_of_range): New function.
	(acc_init_1, acc_shutdown_1): Update call to resolve_device. Call
	acc_dev_num_out_of_range as appropriate.
	(acc_get_num_devices, acc_set_device_type, acc_get_device_type)
	(acc_get_device_num, acc_set_device_num): Update calls to resolve_device.
	* testsuite/libgomp.oacc-c-c++-common/lib-4.c: Update expected test
	output.

From-SVN: r223803
2015-05-28 10:35:39 +00:00

15 lines
204 B
C

/* { dg-do run } */
#include <openacc.h>
int
main (int argc, char **argv)
{
acc_init ((acc_device_t) 99);
return 0;
}
/* { dg-output "unknown device type \[0-9\]+" } */
/* { dg-shouldfail "" } */