1 // RUN: %libomptarget-compile-run-and-check-generic
2 // RUN: %libomptarget-compileopt-run-and-check-generic
10 // Allocates device managed memory that is shared between the host and device.
12 omp_alloc(N
* sizeof(int), llvm_omp_target_shared_mem_alloc
);
14 #pragma omp target teams distribute parallel for is_device_ptr(shared_ptr)
15 for (int i
= 0; i
< N
; ++i
) {
20 for (int i
= 0; i
< N
; ++i
)
27 omp_free(shared_ptr
, llvm_omp_target_shared_mem_alloc
);