pub struct MemStats {
pub live_bytes: u64,
pub peak_bytes: u64,
pub alloc_count: u64,
pub free_count: u64,
}Expand description
A snapshot of the tracked heap. Counters are relaxed, so the fields are individually accurate but need not agree with each other to the byte under concurrent allocation.
Fields§
§live_bytes: u64Bytes currently allocated and not yet freed.
peak_bytes: u64High-water mark of live_bytes, sampled as the shards are re-summed.
alloc_count: u64Allocations made since process start. With free_count, this is the
churn rate; a reallocation resizes an existing block and counts as
neither.
free_count: u64Frees made since process start.
Trait Implementations§
impl Copy for MemStats
impl Eq for MemStats
impl StructuralPartialEq for MemStats
Auto Trait Implementations§
impl Freeze for MemStats
impl RefUnwindSafe for MemStats
impl Send for MemStats
impl Sync for MemStats
impl Unpin for MemStats
impl UnsafeUnpin for MemStats
impl UnwindSafe for MemStats
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.