pub struct PerfStats {
pub count: u64,
pub total_time: Duration,
pub avg_time: Duration,
pub min_time: Duration,
pub max_time: Duration,
}Expand description
Performance statistics snapshot.
Fields§
§count: u64Number of operations recorded
total_time: DurationTotal time across all operations
avg_time: DurationAverage time per operation
min_time: DurationMinimum operation time
max_time: DurationMaximum operation time
Implementations§
Source§impl PerfStats
impl PerfStats
Sourcepub fn ops_per_sec(&self) -> f64
pub fn ops_per_sec(&self) -> f64
Calculate operations per second.
Sourcepub fn throughput_bps(&self, bytes_per_op: u64) -> f64
pub fn throughput_bps(&self, bytes_per_op: u64) -> f64
Calculate throughput in bytes per second.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PerfStats
impl RefUnwindSafe for PerfStats
impl Send for PerfStats
impl Sync for PerfStats
impl Unpin for PerfStats
impl UnsafeUnpin for PerfStats
impl UnwindSafe for PerfStats
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more