[nvptx] Remove use of CUDA unified memory in libgomp
commit2049befdd04a745048fa545a32319b4e2b7af6d0
authorCesar Philippidis <cesar@codesourcery.com>
Tue, 18 Sep 2018 15:41:54 +0000 (18 08:41 -0700)
committerCesar Philippidis <cesar@gcc.gnu.org>
Tue, 18 Sep 2018 15:41:54 +0000 (18 08:41 -0700)
tree3350da1c21938ab90a1821d66840698bf9e0be1b
parent5e594075c8e0f05741b3c961959bf3a4c1f42e9b
[nvptx] Remove use of CUDA unified memory in libgomp

libgomp/
* plugin/plugin-nvptx.c (struct cuda_map): New.
(struct ptx_stream): Replace d, h, h_begin, h_end, h_next, h_prev,
h_tail with (cuda_map *) map.
(cuda_map_create): New function.
(cuda_map_destroy): New function.
(map_init): Update to use a linked list of cuda_map objects.
(map_fini): Likewise.
(map_pop): Likewise.
(map_push): Likewise.  Return CUdeviceptr instead of void.
(init_streams_for_device): Remove stales references to ptx_stream
members.
(select_stream_for_async): Likewise.
(nvptx_exec): Update call to map_init.

From-SVN: r264397
libgomp/ChangeLog
libgomp/plugin/plugin-nvptx.c