Added async memcpy driver api for nvcc backend
Change-Id: If401fc949b834c883cff9de74adb0d532a0fd942
[ROCm/hip commit: 1cb90bdd6a]
This commit is contained in:
@@ -232,6 +232,24 @@ inline static hipError_t hipMemcpyDtoD(hipDeviceptr_t dst,
|
||||
return hipCUResultTohipError(cuMemcpyDtoD(dst, src, size));
|
||||
}
|
||||
|
||||
inline static hipError_t hipMemcpyHtoDAsync(hipDeviceptr_t dst,
|
||||
void* src, size_t size, hipStream_t stream)
|
||||
{
|
||||
return hipCUResultTohipError(cuMemcpyHtoDAsync(dst, src, size, stream));
|
||||
}
|
||||
|
||||
inline static hipError_t hipMemcpyDtoHAsync(void* dst,
|
||||
hipDeviceptr_t src, size_t size, hipStream_t stream)
|
||||
{
|
||||
return hipCUResultTohipError(cuMemcpyDtoH(dst, src, size, stream));
|
||||
}
|
||||
|
||||
inline static hipError_t hipMemcpyDtoDAsync(hipDeviceptr_t dst,
|
||||
hipDeviceptr_t src, size_t size, hipStream_t stream)
|
||||
{
|
||||
return hipCUResultTohipError(cuMemcpyDtoD(dst, src, size, stream));
|
||||
}
|
||||
|
||||
inline static hipError_t hipMemcpy(void* dst, const void* src, size_t sizeBytes, hipMemcpyKind copyKind) {
|
||||
return hipCUDAErrorTohipError(cudaMemcpy(dst, src, sizeBytes, hipMemcpyKindToCudaMemcpyKind(copyKind)));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user