Merge pull request 'docs(clawhdf5): document DType variants, fix unresolved doc links' (#17) from sdlc-docs/clawhdf5-types-20260514-165210 into main
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
/// Information about a GPU device.
|
||||
#[derive(Debug, Clone)]
|
||||
pub struct DeviceInfo {
|
||||
pub name: String,
|
||||
pub backend: String,
|
||||
pub device_type: String,
|
||||
pub max_buffer_size: u64,
|
||||
pub max_storage_buffer_binding_size: u32,
|
||||
}
|
||||
|
||||
impl std::fmt::Display for DeviceInfo {
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
write!(
|
||||
f,
|
||||
"{} ({}, {}, max buffer {} MB, max binding {} MB)",
|
||||
self.name,
|
||||
self.backend,
|
||||
self.device_type,
|
||||
self.max_buffer_size / (1024 * 1024),
|
||||
self.max_storage_buffer_binding_size / (1024 * 1024),
|
||||
)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user