Struct jemalloc_ctl::epoch
source · pub struct epoch;
Expand description
jemalloc
epoch.
Many of the statistics tracked by jemalloc
are cached. The epoch
controls when they are refreshed.
Example
Advancing the epoch:
use jemalloc_ctl::epoch;
let e = epoch::mib().unwrap();
let a = e.advance().unwrap();
let b = e.advance().unwrap();
assert_eq!(a + 1, b);
let o = e.update(0).unwrap();
assert_eq!(o, e.read().unwrap());
Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for epoch
impl Send for epoch
impl Sync for epoch
impl Unpin for epoch
impl UnwindSafe for epoch
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