Skip to main content

get_device

Function get_device 

Source
pub fn get_device() -> CudaRtResult<u32>
Expand description

Returns the ordinal of the current CUDA device for the calling thread.

Mirrors cudaGetDevice.

ยงErrors

Returns CudaRtError::DeviceNotSet if no device has been selected.