pub struct Gpu {
pub name: Option<String>,
pub vendor: Option<String>,
pub model: Option<String>,
pub architecture: Option<String>,
pub uuid: Option<Vec<u8>>,
pub pci_bdf: Option<String>,
pub extra_info: Vec<KeyValue>,
}Expand description
Information about a single GPU.
Fields§
§name: Option<String>GPU name (e.g., “NVIDIA A100”, “Adreno 740”). Used by the Perfetto UI as the display label for GPU tracks (e.g., “NVIDIA A100 Frequency” instead of “GPU 0 Frequency”). If multiple GPUs share the same name, consider appending an index to distinguish them (e.g., “NVIDIA A100 #0”, “NVIDIA A100 #1”).
vendor: Option<String>GPU vendor string (e.g., “NVIDIA”, “AMD”, “Qualcomm”).
model: Option<String>GPU model/product identifier.
architecture: Option<String>GPU architecture (e.g., “Ampere”, “RDNA 3”, “Adreno”).
uuid: Option<Vec<u8>>16-byte device UUID when available.
pci_bdf: Option<String>PCI bus location (domain:bus:device.function, e.g., “0000:01:00.0”).
extra_info: Vec<KeyValue>Implementations§
Source§impl Gpu
impl Gpu
Sourcepub fn vendor(&self) -> &str
pub fn vendor(&self) -> &str
Returns the value of vendor, or the default value if vendor is unset.
Sourcepub fn model(&self) -> &str
pub fn model(&self) -> &str
Returns the value of model, or the default value if model is unset.
Sourcepub fn architecture(&self) -> &str
pub fn architecture(&self) -> &str
Returns the value of architecture, or the default value if architecture is unset.
Trait Implementations§
Source§impl Message for Gpu
impl Message for Gpu
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
self. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
self.