Skip to content

Add a cargo-faster.toml with hot crates, budgets and layering rules - #9

Merged
macalinao merged 1 commit into
mainfrom
cargo-faster-config
Nov 18, 2026
Merged

macalinao merged 1 commit into
mainfrom
cargo-faster-config

Conversation

@macalinao

Copy link
Copy Markdown
Contributor

Adds cargo-faster.toml from real measurements. Needs talaagent/cargo-faster#88 (config-file support, not on crates.io yet), so CI only gets a commented-out cargo faster check step for now.

Measured

2026-11-18, cargo faster check --timings run twice (shared 32-core dev box at ~2x load, cold, nix develop). I took the larger value from each pair:

  • cold cargo check --workspace: 21.7s (second run: 3.6s, warmed by kache)
  • edit rebuild: codexwire 1.6s, codexwire-protocol 5.2s
  • critical path (workspace crates): codexwire-protocol → codexwire
  • duplicate versions (x86_64-unknown-linux-gnu): 0

Hot crates

codexwire and codexwire-protocol, which are both workspace crates. Over the last 6 months they had 28 and 13 file edits.

Accepts

None. None of the current findings are there by design.

Budgets

Each budget is the measured value × 1.25, rounded up.

  • cold_check_secs = 28
  • edit_rebuild_secs = { codexwire = 2, codexwire-protocol = 7 }
  • critical_path_max_crates = 2
  • no_new_critical_crates = ["codexwire-protocol", "codexwire"]
  • max_duplicate_versions = 0

Layer rules

  • all crates must not depend on tala-*: a standalone public library.
  • codexwire-protocol must not depend on codexwire, tokio*, async-*, futures* or mio. This follows CONTRIBUTING.md: keep the protocol crate free of process and async runtime dependencies.

Also sets env.nextest_profile = "ci", the same profile CI passes to nextest.

Follow-ups (real findings, not accepted)

  • syn is built in two versions (2.0.119 and 3.0.9) for the host/proc-macro side. See cargo tree -d -e normal,build.
  • Dev builds emit full debug info. Consider debug = "line-tables-only" for dev.
  • The jobserver and 16-job findings come from this dev machine, not the repo.

cargo faster check exits 0 with this file. cargo fmt --all --check passes.

@macalinao
macalinao merged commit 5188518 into main Nov 18, 2026
10 checks passed
@macalinao
macalinao deleted the cargo-faster-config branch November 18, 2026 09:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant