mod format;
mod parse;
pub(crate) use format::{
render_executor_residual_suffix, render_perf_suffix, render_pure_covering_suffix,
render_shell_render_suffix,
};
#[cfg(test)]
pub(crate) use parse::normalize_grouped_next_cursor_json;
pub(crate) use parse::{find_result_payload, parse_perf_result};
pub(crate) struct ShellPerfAttribution {
pub(crate) total: u64,
pub(crate) planner: u64,
pub(crate) store: u64,
pub(crate) executor: u64,
pub(crate) pure_covering_decode: u64,
pub(crate) pure_covering_row_assembly: u64,
pub(crate) decode: u64,
pub(crate) compiler: u64,
}
impl ShellPerfAttribution {
pub(crate) const fn attributed_total(&self) -> u64 {
self.compiler
.saturating_add(self.planner)
.saturating_add(self.store)
.saturating_add(self.executor)
.saturating_add(self.decode)
}
pub(crate) const fn residual_total(&self) -> u64 {
self.total.saturating_sub(self.attributed_total())
}
pub(crate) const fn pure_covering_executor_residual(&self) -> u64 {
self.executor
.saturating_sub(self.pure_covering_decode)
.saturating_sub(self.pure_covering_row_assembly)
}
}
pub(crate) struct ShellLocalRenderAttribution {
pub(crate) render_micros: u128,
}