[Libomptarget] Implement the host memory allocator with fine grained memory
authorJoseph Huber <jhuber6@vols.utk.edu>
Fri, 10 Feb 2023 20:37:20 +0000 (14:37 -0600)
committerJoseph Huber <jhuber6@vols.utk.edu>
Mon, 20 Feb 2023 14:44:09 +0000 (08:44 -0600)
commit5d560b6966b722e45085f010bb98d2b081c461c7
tree9a687b0f8cc44ba356c5b06f6750a125f9038793
parent5216a9bfb002705fcaee7a078cbbb538e806eea1
[Libomptarget] Implement the host memory allocator with fine grained memory

This patch should enable the "Host" allocation using fine-grained
memory. As far as I understand, this is HSA managed memory that is
availible to the host, but can be accessed by the device as well.
The original patch that introduced these extensions just stipulated that
it's "non-migratable" memory, which is most likely true because it's
managed by the host but accessible by the device. This should work
sufficiently well for what we expect the "host" allocation to do.

Depends on D143771

Reviewed By: kevinsala

Differential Revision: https://reviews.llvm.org/D143775
openmp/libomptarget/plugins-nextgen/amdgpu/src/rtl.cpp
openmp/libomptarget/test/api/omp_host_pinned_memory.c
openmp/libomptarget/test/api/omp_host_pinned_memory_alloc.c