[SYCL 2020][USM] Add USM queue shortcuts, memcpy, memset, fill, prefetch, mem_advise stub, test cases #323
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
queue::parallel_for
)handler::memcpy
handler::memset
handler::fill
handler::prefetch
mem_advise
(stub only, see caveats below)Testing results:
Caveats:
prefetch
on HIP is there, but the actual call tohipMemPrefetchAsync()
is commented out because this function does not yet exist in HIP - likely because HIP doesn't have proper unified memory, so prefetching doesn't make sense.hipMemsetAsync()
does weird things causing thememset()
tests to fail on HIP. This is probably a bug in HIP/ROCm. Since I'm using an older ROCm, it's possible that this is already fixed - needs more investigation.mem_advise()
is currently only implemented as a stub that throws an exception when actually used.mem_advise
semantics in SYCL we need to launch a host task that then executescudaMemAdvise()
. For this we would first need to implement host tasks, which we don't have yet.hipMemAdvise()
at all - probably because of a similar reasoning as the missinghipMemPrefetchAsync()