pub struct GlobalProfiler { /* private fields */ }
Expand description
Global profiler for collecting performance data
Implementations§
Source§impl GlobalProfiler
impl GlobalProfiler
pub fn new() -> Self
pub fn enable(&self)
pub fn disable(&self)
pub fn is_enabled(&self) -> bool
pub fn record_event(&self, name: &str, duration: Duration)
pub fn record_memory_event(&self, name: &str, allocated: usize, freed: usize)
pub fn record_custom_metric(&self, name: &str, metric_name: &str, value: f64)
pub fn get_profile(&self, name: &str) -> Option<ProfileMetrics>
pub fn get_all_profiles(&self) -> Vec<ProfileMetrics>
pub fn print_all_summaries(&self)
pub fn clear(&self)
pub fn export_csv(&self, path: &str) -> Result<(), CudaRustError>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for GlobalProfiler
impl RefUnwindSafe for GlobalProfiler
impl Send for GlobalProfiler
impl Sync for GlobalProfiler
impl Unpin for GlobalProfiler
impl UnwindSafe for GlobalProfiler
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