Skip to content

Commit d85c8db

Browse files
committed
Merge branch 'cuda_memadvise' of https://github.com/t4c1/llvm into cuda_memadvise
2 parents 856e634 + 34fba4a commit d85c8db

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

sycl/plugins/cuda/pi_cuda.cpp

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4716,12 +4716,10 @@ pi_result cuda_piextUSMEnqueueMemAdvise(pi_queue queue, const void *ptr,
47164716
case PI_MEM_ADVICE_CUDA_UNSET_PREFERRED_LOCATION:
47174717
case PI_MEM_ADVICE_CUDA_SET_ACCESSED_BY:
47184718
case PI_MEM_ADVICE_CUDA_UNSET_ACCESSED_BY:
4719-
result = PI_CHECK_ERROR(
4720-
cuMemAdvise((CUdeviceptr)ptr,
4721-
length,
4722-
(CUmem_advise)(
4723-
advice - PI_MEM_ADVICE_CUDA_SET_READ_MOSTLY + 1),
4724-
queue->get_context()->get_device()->get()));
4719+
result = PI_CHECK_ERROR(cuMemAdvise(
4720+
(CUdeviceptr)ptr, length,
4721+
(CUmem_advise)(advice - PI_MEM_ADVICE_CUDA_SET_READ_MOSTLY + 1),
4722+
queue->get_context()->get_device()->get()));
47254723
break;
47264724
case PI_MEM_ADVICE_CUDA_SET_PREFERRED_LOCATION_HOST:
47274725
case PI_MEM_ADVICE_CUDA_UNSET_PREFERRED_LOCATION_HOST:

0 commit comments

Comments
 (0)