1 /* Verify that we refuse 'acc_map_data' when the "device address [...] is
4 /* { dg-skip-if "" { *-*-* } { "*" } { "-DACC_MEM_SHARED=0" } } */
16 char *h1
= (char *) malloc (N
);
18 void *d
= acc_create (h1
, N
);
21 char *h2
= (char *) malloc (N
);
23 /* Try to arrange a setting such that a later 'acc_unmap_data' would find the
24 device memory object still referenced elsewhere. This is not possible,
25 given the semantics of 'acc_map_data'. */
26 fprintf (stderr
, "CheCKpOInT\n");
27 acc_map_data (h2
, d
, N
);
33 /* { dg-output "CheCKpOInT(\n|\r\n|\r).*" } */
34 /* { dg-output "device address \\\[\[0-9a-fA-FxX\]+, \\\+132\\\] is already mapped" } */
35 /* { dg-shouldfail "" } */