repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
* config/arm/arm.c (arm_reorg): Skip Thumb reorg pass for thunks.
[official-gcc.git]
/
libgomp
/
testsuite
/
libgomp.oacc-c-c++-common
/
host_data-4.c
blob
0ab5a3569127cfef2c51a333dfa3107912ae0e42
1
/* { dg-do run { target openacc_nvidia_accel_selected } } */
2
3
#include <openacc.h>
4
#include <stdlib.h>
5
6
#define N 1024
7
8
int
main
(
int
argc
,
char
*
argv
[])
9
{
10
int
x
[
N
], *
xp2
;
11
12
#pragma acc data copyin (x[0:N])
13
{
14
int
*
xp
;
15
#pragma acc host_data use_device (x)
16
{
17
#pragma acc data
18
{
19
xp
=
x
;
20
}
21
xp2
=
x
;
22
}
23
24
if
(
xp
!=
acc_deviceptr
(
x
) ||
xp2
!=
xp
)
25
abort
();
26
}
27
28
return
0
;
29
}