pub struct CallTreeNode {
pub name: String,
pub inclusive_ns: u64,
pub exclusive_ns: u64,
pub call_count: u64,
pub children: Vec<CallTreeNode>,
}Expand description
A node in a call tree (for inclusive/exclusive timing analysis).
Fields§
§name: StringFunction name.
inclusive_ns: u64Total (inclusive) time in ns.
exclusive_ns: u64Self (exclusive) time in ns.
call_count: u64Number of calls.
children: Vec<CallTreeNode>Child nodes.
Implementations§
Source§impl CallTreeNode
impl CallTreeNode
Sourcepub fn avg_exclusive_ns(&self) -> f64
pub fn avg_exclusive_ns(&self) -> f64
Average self time per call.
Sourcepub fn avg_inclusive_ns(&self) -> f64
pub fn avg_inclusive_ns(&self) -> f64
Average inclusive time per call.
Sourcepub fn find_child(&self, name: &str) -> Option<&CallTreeNode>
pub fn find_child(&self, name: &str) -> Option<&CallTreeNode>
Find a child with the given name.
Trait Implementations§
Source§impl Clone for CallTreeNode
impl Clone for CallTreeNode
Source§fn clone(&self) -> CallTreeNode
fn clone(&self) -> CallTreeNode
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for CallTreeNode
impl RefUnwindSafe for CallTreeNode
impl Send for CallTreeNode
impl Sync for CallTreeNode
impl Unpin for CallTreeNode
impl UnsafeUnpin for CallTreeNode
impl UnwindSafe for CallTreeNode
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