From 47b1005aac316af3376f24f308e80af2f2f41ad9 Mon Sep 17 00:00:00 2001 From: Satyanvesh Dittakavi Date: Tue, 24 Nov 2020 06:58:04 -0500 Subject: [PATCH] Fix hipLaunchCooperativeKernel failure on nvidia platform SWDEV-262064 - compilation fails when hipLaunchCooperativeKernel C++ routine is invoked on nvcc path. Change-Id: Icde35dd1a7008b406401bb3996c06d7acfb27d8d [ROCm/hip commit: 44d6914ef3075e377cd7683973420f1b872d9e70] --- projects/hip/include/hip/nvcc_detail/hip_runtime_api.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/hip/include/hip/nvcc_detail/hip_runtime_api.h b/projects/hip/include/hip/nvcc_detail/hip_runtime_api.h index faf66d4efa..257d795cf3 100755 --- a/projects/hip/include/hip/nvcc_detail/hip_runtime_api.h +++ b/projects/hip/include/hip/nvcc_detail/hip_runtime_api.h @@ -2001,7 +2001,7 @@ template inline static hipError_t hipLaunchCooperativeKernel(T f, dim3 gridDim, dim3 blockDim, void** kernelParams, unsigned int sharedMemBytes, hipStream_t stream) { return hipCUDAErrorTohipError( - cudaLaunchCooperativeKernel(f, gridDim, blockDim, kernelParams, sharedMemBytes, stream)); + cudaLaunchCooperativeKernel(reinterpret_cast(f), gridDim, blockDim, kernelParams, sharedMemBytes, stream)); } inline static hipError_t hipTexRefSetAddressMode(hipTexRef hTexRef, int dim, hipAddress_mode am){