#[non_exhaustive]pub struct RunProfile {
pub exit_code: Option<i32>,
pub duration: Duration,
pub cpu_time: Option<Duration>,
pub peak_memory_bytes: Option<u64>,
pub samples: usize,
}stats only.Expand description
Resource summary of one finished run — produced by
RunningProcess::profile.
CPU and memory are sampled from the started child process (the same
source as RunningProcess::cpu_time /
peak_memory_bytes), so they
are None where per-process metrics are unavailable (macOS/BSD) or when
the run exited before the first sample landed.
Non-exhaustive: a read-only summary the crate produces — new metrics can be added without a breaking change.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.exit_code: Option<i32>The exit code; None for a run killed by its timeout or a signal
(matching RunningProcess::wait).
duration: DurationWall-clock time from process start until the run finished (exit reaped and output drained).
cpu_time: Option<Duration>Cumulative CPU time (user + kernel) at the last successful sample.
peak_memory_bytes: Option<u64>Peak resident memory observed across the samples, in bytes.
samples: usizeHow many sampling ticks ran (including ones that found no data).
Implementations§
Trait Implementations§
Source§impl Clone for RunProfile
impl Clone for RunProfile
Source§fn clone(&self) -> RunProfile
fn clone(&self) -> RunProfile
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for RunProfile
Source§impl Debug for RunProfile
impl Debug for RunProfile
Source§impl PartialEq for RunProfile
impl PartialEq for RunProfile
Source§fn eq(&self, other: &RunProfile) -> bool
fn eq(&self, other: &RunProfile) -> bool
self and other values to be equal, and is used by ==.