pub struct AllocationStats {
pub total_allocations: u64,
pub total_deallocations: u64,
pub active_allocations: usize,
pub current_usage: usize,
pub peak_usage: usize,
pub total_allocated: usize,
pub total_deallocated: usize,
pub average_allocation_size: f64,
pub average_lifetime_us: f64,
pub allocation_rate: f64,
pub deallocation_rate: f64,
pub fragmentation_score: f64,
}Expand description
Allocation statistics summary
Fields§
§total_allocations: u64Total number of allocations
total_deallocations: u64Total number of deallocations
active_allocations: usizeCurrently active allocations
current_usage: usizeCurrent memory usage in bytes
peak_usage: usizePeak memory usage in bytes
total_allocated: usizeTotal bytes ever allocated
total_deallocated: usizeTotal bytes deallocated
average_allocation_size: f64Average allocation size
average_lifetime_us: f64Average lifetime in microseconds
allocation_rate: f64Allocation rate (allocs/second)
deallocation_rate: f64Deallocation rate (deallocs/second)
fragmentation_score: f64Fragmentation score (0.0 = no fragmentation, 1.0 = severe)
Trait Implementations§
Source§impl Clone for AllocationStats
impl Clone for AllocationStats
Source§impl Debug for AllocationStats
impl Debug for AllocationStats
Auto Trait Implementations§
impl Freeze for AllocationStats
impl RefUnwindSafe for AllocationStats
impl Send for AllocationStats
impl Sync for AllocationStats
impl Unpin for AllocationStats
impl UnsafeUnpin for AllocationStats
impl UnwindSafe for AllocationStats
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more