1 // RUN: %libomptarget-compile-run-and-check-generic
11 void init(double vertexx
[]) {
12 #pragma omp target map(vertexx[0 : 100])
14 printf("In init: %lf, expected 100.0\n", vertexx
[77]);
19 void change(DV
*dvptr
) {
20 #pragma omp target map(dvptr->dataptr[0 : 100])
22 printf("In change: %lf, expected 77.0\n", dvptr
->dataptr
[77]);
23 dvptr
->dataptr
[77] += 1.0;
32 dv
.dataptr
= &vertexx
[0];
34 #pragma omp target enter data map(to : vertexx[0 : 100])
39 #pragma omp target exit data map(from : vertexx[0 : 100])
42 printf("Final: %lf\n", vertexx
[77]);