pub struct ShellEfficiencyProfileSnapshot {
pub terminal_state_us: Distribution,
pub terminal_state_captures_total: u64,
pub terminal_state_skips_total: u64,
pub terminal_frame_bytes: Distribution,
pub terminal_frames_published_total: u64,
pub terminal_frame_bytes_total: u64,
pub foreground_probe_queued_us: Distribution,
pub foreground_probe_lock_wait_us: Distribution,
pub foreground_probe_walk_us: Distribution,
pub foreground_probes_total: u64,
}Expand description
One snapshot of every shell-efficiency series – what
crate::NativeRuntime::shell_efficiency_snapshot returns, and what
GET /metrics renders alongside TickProfileSnapshot.
Fields§
§terminal_state_us: DistributionDuration of real (sequence-gate-passed) terminal_state() calls –
backlog item 3’s “what a changed-screen capture actually costs”.
terminal_state_captures_total: u64Lifetime count of those real captures.
terminal_state_skips_total: u64Lifetime count of sessions the cheap sequence gate skipped instead of paying for a real capture.
terminal_frame_bytes: DistributionByte size of every published TerminalFrame – backlog item 4’s
“what a frame costs on the wire”.
terminal_frames_published_total: u64Lifetime count of frames published.
terminal_frame_bytes_total: u64Lifetime total bytes across every frame published.
foreground_probe_queued_us: DistributionThe three components of reclassify_foreground’s OS process-tree
probes – see gate4agent::pty::ForegroundProbeTiming for what each
one means. Kept as three independent series rather than one combined
duration: a total mixing pure spawn_blocking-queue waiting with
the mutex-contention wait and the actual process-table walk’s CPU
leads to opposite conclusions depending on which of the three
dominates, so collapsing them back into one number would throw away
exactly what this split exists to preserve.
foreground_probe_lock_wait_us: Distribution§foreground_probe_walk_us: Distribution§foreground_probes_total: u64Lifetime count of probes, not components – one probe increments this by one regardless of how many of the three series above it also fed.