Struct TelemetryBuffer
#[repr(C, align(64))]pub struct TelemetryBuffer {
pub messages_processed: u64,
pub messages_dropped: u64,
pub total_latency_us: u64,
pub min_latency_us: u64,
pub max_latency_us: u64,
pub input_queue_depth: u32,
pub output_queue_depth: u32,
pub last_error: u32,
pub _reserved: [u32; 3],
}Expand description
Telemetry buffer (64 bytes, cache-line aligned).
This structure is updated by the GPU kernel and read by the host for monitoring and debugging purposes.
Fields§
§messages_processed: u64Total messages processed successfully.
messages_dropped: u64Total messages dropped (queue full, timeout, etc.).
total_latency_us: u64Sum of processing latencies in microseconds.
min_latency_us: u64Minimum processing latency in microseconds.
max_latency_us: u64Maximum processing latency in microseconds.
input_queue_depth: u32Current input queue depth.
output_queue_depth: u32Current output queue depth.
last_error: u32Last error code (0 = no error).
_reserved: [u32; 3]Reserved for alignment (pad to 64 bytes).
Implementations§
§impl TelemetryBuffer
impl TelemetryBuffer
pub const fn new() -> TelemetryBuffer
pub const fn new() -> TelemetryBuffer
Create a new telemetry buffer.
pub fn avg_latency_us(&self) -> f64
pub fn avg_latency_us(&self) -> f64
Calculate average latency in microseconds.
pub fn throughput(&self, elapsed_secs: f64) -> f64
pub fn throughput(&self, elapsed_secs: f64) -> f64
Get throughput (messages per second) given elapsed time.
pub fn reset(&mut self)
pub fn reset(&mut self)
Reset all counters to initial state.
pub fn merge(&mut self, other: &TelemetryBuffer)
pub fn merge(&mut self, other: &TelemetryBuffer)
Merge another telemetry buffer into this one.
Trait Implementations§
§impl Clone for TelemetryBuffer
impl Clone for TelemetryBuffer
§fn clone(&self) -> TelemetryBuffer
fn clone(&self) -> TelemetryBuffer
Returns a duplicate of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more§impl Debug for TelemetryBuffer
impl Debug for TelemetryBuffer
§impl Default for TelemetryBuffer
impl Default for TelemetryBuffer
§fn default() -> TelemetryBuffer
fn default() -> TelemetryBuffer
Returns the “default value” for a type. Read more
impl Copy for TelemetryBuffer
Auto Trait Implementations§
impl Freeze for TelemetryBuffer
impl RefUnwindSafe for TelemetryBuffer
impl Send for TelemetryBuffer
impl Sync for TelemetryBuffer
impl Unpin for TelemetryBuffer
impl UnwindSafe for TelemetryBuffer
Blanket Implementations§
§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)§impl<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
§fn deserialize(
&self,
deserializer: &mut D,
) -> Result<With<T, W>, <D as Fallible>::Error>
fn deserialize( &self, deserializer: &mut D, ) -> Result<With<T, W>, <D as Fallible>::Error>
Deserializes using the given deserializer
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Gets the layout of the type.