Skip to content

Commit

Permalink
Update Kokkos_CudaSpace.cpp
Browse files Browse the repository at this point in the history
Improve error message
  • Loading branch information
diehlpk authored and cedricchevalier19 committed Jul 29, 2024
1 parent 1279c86 commit 1ec7be8
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion core/src/Cuda/Kokkos_CudaSpace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,10 @@ void *impl_allocate_common(const int device_id,
// device, but that requires CUDA 12.2
static_assert(CUDART_VERSION >= 12020,
"CUDA runtime version >=12.2 required when "
"Kokkos_ENABLE_IMPL_CUDA_UNIFIED_MEMORY is set");
"Kokkos_ENABLE_IMPL_CUDA_UNIFIED_MEMORY is set. "
"Please update your CUDA runtime version or "
"reconfigure with with "
"-D Kokkos_ENABLE_IMPL_CUDA_UNIFIED_MEMORY=OFF");
if (arg_alloc_size) { // cudaMemAdvise_v2 does not work with nullptr
error_code = cudaMallocManaged(&ptr, arg_alloc_size, cudaMemAttachGlobal);
if (error_code == cudaSuccess) {
Expand Down

0 comments on commit 1ec7be8

Please sign in to comment.