Skip to main content

cuda_device_count

Function cuda_device_count 

Source
pub fn cuda_device_count() -> Result<i32>
Expand description

Number of CUDA devices visible to this process.

Never loads libcuda and never calls cuInit. The rdmaxcel_cu* wrappers adopt an already-resident driver via dlopen(RTLD_NOLOAD) and otherwise report CUDA_ERROR_NOT_INITIALIZED, so a process that has not touched CUDA pays only a failed symbol lookup and never gains a CUDA context – and gets an error here.