pub struct CudaDeviceProp {Show 37 fields
pub name: String,
pub total_global_mem: usize,
pub shared_mem_per_block: usize,
pub regs_per_block: u32,
pub warp_size: u32,
pub mem_pitch: usize,
pub max_threads_per_block: u32,
pub max_threads_dim: [u32; 3],
pub max_grid_size: [u32; 3],
pub clock_rate: u32,
pub total_const_mem: usize,
pub major: u32,
pub minor: u32,
pub texture_alignment: usize,
pub texture_pitch_alignment: usize,
pub device_overlap: bool,
pub multi_processor_count: u32,
pub ecc_enabled: bool,
pub integrated: bool,
pub can_map_host_memory: bool,
pub unified_addressing: bool,
pub memory_clock_rate: u32,
pub memory_bus_width: u32,
pub l2_cache_size: u32,
pub max_threads_per_multi_processor: u32,
pub stream_priorities_supported: bool,
pub shared_mem_per_multiprocessor: usize,
pub regs_per_multiprocessor: u32,
pub managed_memory: bool,
pub is_multi_gpu_board: bool,
pub multi_gpu_board_group_id: u32,
pub host_native_atomic_supported: bool,
pub cooperative_launch: bool,
pub cooperative_multi_device_launch: bool,
pub max_blocks_per_multi_processor: u32,
pub shared_mem_per_block_optin: usize,
pub cluster_launch: bool,
}Expand description
Subset of cudaDeviceProp exposed by the Runtime API.
Field names intentionally match the CUDA Runtime documentation so that code
written against cudaGetDeviceProperties compiles with minimal changes.
Fields§
§name: StringASCII name of the device, e.g. "NVIDIA GeForce RTX 4090".
total_global_mem: usizeTotal amount of global memory in bytes.
Shared memory per block in bytes.
regs_per_block: u3232-bit registers per block.
warp_size: u32Warp size (threads per warp).
mem_pitch: usizeMaximum pitch in bytes for cudaMallocPitch.
max_threads_per_block: u32Maximum number of threads per block.
max_threads_dim: [u32; 3]Maximum size of each dimension of a block [x, y, z].
max_grid_size: [u32; 3]Maximum size of each dimension of a grid [x, y, z].
clock_rate: u32Clock frequency in kilohertz.
total_const_mem: usizeTotal constant memory available on device in bytes.
major: u32Major revision number of device’s compute capability.
minor: u32Minor revision number of device’s compute capability.
texture_alignment: usizeAlignment requirement for textures (in bytes).
texture_pitch_alignment: usizePitch alignment requirement for texture references (in bytes).
device_overlap: booltrue if device can concurrently copy and execute a kernel.
multi_processor_count: u32Number of multiprocessors on device.
ecc_enabled: booltrue if device has ECC support enabled.
integrated: booltrue if device is an integrated (on-chip) GPU.
can_map_host_memory: booltrue if device can map host memory.
unified_addressing: booltrue if device supports unified virtual addressing.
memory_clock_rate: u32Peak memory clock frequency in kilohertz.
memory_bus_width: u32Global memory bus width in bits.
l2_cache_size: u32Size of the L2 cache in bytes (0 if not applicable).
max_threads_per_multi_processor: u32Maximum number of resident threads per multiprocessor.
stream_priorities_supported: boolDevice supports stream priorities.
Shared memory per multiprocessor in bytes.
regs_per_multiprocessor: u3232-bit registers per multiprocessor.
managed_memory: boolDevice supports allocating managed memory.
is_multi_gpu_board: boolDevice is on a multi-GPU board.
multi_gpu_board_group_id: u32Unique identifier for a group of devices on the same multi-GPU board.
host_native_atomic_supported: boolLink between the device and the host supports native atomic operations.
cooperative_launch: booltrue if the device supports Cooperative Launch.
cooperative_multi_device_launch: booltrue if the device supports Multi-Device Cooperative Launch.
max_blocks_per_multi_processor: u32Maximum number of blocks per multiprocessor.
Per-device maximum shared memory per block usable without opt-in.
cluster_launch: booltrue if device supports cluster launch.
Implementations§
Source§impl CudaDeviceProp
impl CudaDeviceProp
Sourcepub fn from_device(ordinal: c_int) -> CudaRtResult<Self>
pub fn from_device(ordinal: c_int) -> CudaRtResult<Self>
Construct a CudaDeviceProp by querying device attributes via the
CUDA Driver API.
§Errors
Returns an error if the driver is not loaded or any attribute query fails.
Trait Implementations§
Source§impl Clone for CudaDeviceProp
impl Clone for CudaDeviceProp
Source§fn clone(&self) -> CudaDeviceProp
fn clone(&self) -> CudaDeviceProp
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more