[][src]Struct rustc_ap_rustc_data_structures::profiling::SelfProfilerRef

pub struct SelfProfilerRef { /* fields omitted */ }

A reference to the SelfProfiler. It can be cloned and sent across thread boundaries at will.

Methods

impl SelfProfilerRef[src]

pub fn new(profiler: Option<Arc<SelfProfiler>>) -> SelfProfilerRef[src]

pub fn generic_activity(&self, event_id: &str) -> TimingGuard[src]

Start profiling a generic activity. Profiling continues until the TimingGuard returned from this call is dropped.

pub fn query_provider(&self, query_name: impl QueryName) -> TimingGuard[src]

Start profiling a query provider. Profiling continues until the TimingGuard returned from this call is dropped.

pub fn query_cache_hit(&self, query_name: impl QueryName)[src]

Record a query in-memory cache hit.

pub fn query_blocked(&self, query_name: impl QueryName) -> TimingGuard[src]

Start profiling a query being blocked on a concurrent execution. Profiling continues until the TimingGuard returned from this call is dropped.

pub fn incr_cache_loading(&self, query_name: impl QueryName) -> TimingGuard[src]

Start profiling how long it takes to load a query result from the incremental compilation on-disk cache. Profiling continues until the TimingGuard returned from this call is dropped.

pub fn register_queries(&self, f: impl FnOnce(&SelfProfiler))[src]

Trait Implementations

impl Clone for SelfProfilerRef[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Erased for T[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<E> SpecializationError for E[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.