rad experiment show 622161da69f28ffba36274b00500cd0424d40504
by lftherioslftherios@did:key:z6MkupQHdQky5atyAu9zF8dUu1EavUjckDgCdZLH8y2W8teE · Apr 26 08:20 2026
Replaced the `dirs` crate with direct `XDG_RUNTIME_DIR` environment lookup in `src/cmd/mq.rs`, but the benchmark was still slower than the current best.
Measurements
Metric
BaselineThe benchmark measurement of the unmodified code
CandidateThe code with the proposed optimization applied
Candidate/Parent ΔThe performance change from baseline to candidate
total_ms (ms)primary
Reduce the wall-clock time of the repo's `just check` workload for this repository, focusing on code and configuration changes that improve Rust compile/check performance without breaking correctness. In this environment `just` is unavailable, so the harness runs the equivalent underlying cargo command directly.
6052.000 ms (n=1)
6366.000 ms (n=1)
+5.18%REGRESSED
log_bytessecondary
2766.000 (n=1)
2681.000 (n=1)
-3.07%REGRESSED
Annotations
hypothesis
A tiny manual replacement for `dirs::runtime_dir()` could remove one more transitive dependency with almost no code cost.
learning
Very small dependency cleanups are now within or below the noise floor unless they remove a truly large subtree.
next_action_hint
Stop chasing tiny runtime-helper dependencies and focus on bigger compile contributors or architectural gating of MQ-heavy code.
rollback_reason
Primary metric regressed from 6052ms to 6366ms, so removing `dirs` is not a win here.
Base CommitThe starting commit before the optimization was applied