pub struct Profiler { /* private fields */ }Expand description
Rolling profiler that keeps the last N frames of timing data.
Implementations§
Source§impl Profiler
impl Profiler
pub fn new(max_frames: usize) -> Self
pub fn push_frame(&mut self, record: FrameRecord)
pub fn frames(&self) -> &[FrameRecord]
pub fn total_frames(&self) -> u64
Sourcepub fn summary(&self) -> ProfileSummary
pub fn summary(&self) -> ProfileSummary
Summary stats across recorded frames.
Auto Trait Implementations§
impl Freeze for Profiler
impl RefUnwindSafe for Profiler
impl Send for Profiler
impl Sync for Profiler
impl Unpin for Profiler
impl UnsafeUnpin for Profiler
impl UnwindSafe for Profiler
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