Skip to content

CI measurement: rust_tests-job leaf cgroup peak + --measure-cgroup-peak (per-job placement divisor) - #5574

Merged
briansrls merged 20 commits into
mainfrom
session/quick-ant-298-ruststep
Jun 22, 2026
Merged

briansrls merged 20 commits into
mainfrom
session/quick-ant-298-ruststep

Conversation

@gunbai-bot

@gunbai-bot gunbai-bot Bot commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

Second half of the whole-tree CI memory measurement (companion to #5564's ci-job emit). Stacked on #5564 (reuses its binding_cap_cgroup_dir + sccache scan); the diff will shrink to just this change once #5564 merges.

What

  • claim_executor --measure-cgroup-peak standalone mode (emits the whole-tree cgroup measurement, no plan run).
  • A rust_tests-job ci.yml step (if: always()) that calls it, so the rust_tests job — the binding ~16-23 GiB per-job constraint (measured live on srv1) — emits its OWN cgroup peak (a different ephemeral runner cgroup from the ci job's).

Why the leaf-read correction

Live srv1 inspection (operator-granted fleet access) shows the runner units run MemoryMax=infinity — UNCAPPED. So #5564's binding_cap_cgroup_dir returns None and the cap-ancestor read emits "unavailable" on the real fleet (an honest §5 no-op, but no number). This reads memory.peak at the LEAF runner cgroup (the ephemeral per-job cgroup, always present) and reports capped-vs-uncapped + host MemTotal separately.

One walk, all reads (single authority)

The emit line carries memory.peak (usage) + memory.max (budget, =uncapped) + host_ram + pids.current/max + the sccache server cgroup classified descendant-vs-sibling (the "accounted exactly once" decision). Consumers: compile-jobs divisor (#5546, budgets) and placement (#5559, per-job peak).

Verification (by execution)

  • cargo build --release --bins, cargo clippy -p v1-compiler --bin claim_executor -- -D warnings, cargo fmt --all --check: clean.
  • ./target/release/claim_executor --measure-cgroup-peak: emits the line (verified locally).
  • ci.yml regenerated via main_wet; run_ci_yaml_gate (drift + parse + red-receipt): ExitSuccess.

🤖 Generated with Claude Code

briansrls and others added 20 commits June 21, 2026 04:20
…he 3× fleet-red)

Pins the 3× fleet-red to stale-green (PR validated against a pre-gate base,
merged without re-validating current main) via the #5429 timeline receipts;
ranks the merge-policy fixes (merge-queue >> require-up-to-date under the
approval outage); scopes neat-ibex's reverse-staleness lens as complementary,
not the 3×-red killer. Decision record for the operator's merge-policy call.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…e (the §1 coverage keystone)

Scoping artifact for the operator greenlight call. One declared fact (rust-test→
consumed-.dag closure on the existing NodeArtifactProvenance carrier) read in two
directions: FIRE-when-consumed (coverage wall, fail-closed) and SKIP-when-unaffected
(affordability selector) — DESIGN §4 one grammar both directions. Shared
testgen-reflection blocker; first vertical slice; honest multi-day estimate. Build
HELD for operator nod; decoupled from #5427.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…try (closure ⊇ reads)

bright-stag's load-bearing sharpening: coverage (fire-on-change) is fail-OPEN to
under-declaration (declaration drift re-opens the .dag→rust hole), while affordability
(skip) is fail-safe to over-declaration. So (1) the completeness lens must check
closure ⊇ actual-.dag-reads (CORRECTNESS), not mere presence — presence is the §5
faked-cache-key trap; (2) structural closure discovery IS the soundness, not optional
polish — a hand-authored closure is the §3/§5 fork that silently re-opens the hole;
(3) slice-1 must state whether its closure is structurally derived (proves the wall) or
hand-listed (proves only the wiring).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…ge item (doc reachability)

The new docs/plans/edge-b-rust-dag-provenance-brief.md was an orphan doc → the
floor witness doc_graph_has_no_orphan_docs (dsl/test/claim/doc_reachability_witness_test.dag)
RED on #5526. Fix per the rule (every docs/**/*.md reachable from a ROADMAP/DESIGN
root): add a terse pointer on the existing §1 rust-gate-coverage line, its correct
semantic home — edge-(b) is the .dag→rust coverage wall that #5427 (the .rs-hole-closer)
does not close.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
… refinement)

Per the operator short-lines rule (bright-stag enforces): move the mechanism density
(rust-test↔consumed-.dag closure, fail-closed both directions) into the brief; keep the
ROADMAP line a short scannable summary + pointer + explicit no-overclaim status
('SCOPED / pending operator greenlight'). Build is NOT greenlit; the line now says so.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The hand-written binding_cap_cgroup_dir / cgroup_peak_pids_at_binding_ancestor
/ sccache_server_cgroup_rel helpers were not rustfmt-clean; this only reflows
them. No logic change. Fixes the rust_tests fmt failure on the held draft #5564.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…ak (per-job placement divisor)

Second half of the whole-tree CI memory measurement (companion to #5564's ci-job
emit): a claim_executor --measure-cgroup-peak standalone mode + a rust_tests-job
ci.yml step that calls it, so the rust_tests job (the binding ~16-23 GiB per-job
constraint, measured live on srv1) emits its own cgroup peak.

Corrects #5564's cap-ancestor read for the real fleet. Live srv1 inspection
(operator-granted) shows the runner units run MemoryMax=infinity (UNCAPPED), so
binding_cap_cgroup_dir returns None and the cap-ancestor read emits "unavailable".
The measurement now reads memory.peak at the LEAF runner cgroup (the ephemeral
per-job cgroup, always present) and reports capped-vs-uncapped + host MemTotal.

One walk, all reads (single authority): the emit line carries memory.peak (usage)
+ memory.max (budget, =uncapped on the fleet) + host_ram + pids.current/max + the
sccache server cgroup classified descendant-vs-sibling (the "accounted exactly
once" decision) — consumed by the compile-jobs divisor (#5546) and the placement
model (#5559).

Stacked on #5564 (reuses its binding_cap_cgroup_dir / sccache scan). ci.yml
regenerated via main_wet; drift gate green; fmt + clippy -D warnings + release
build clean; --measure-cgroup-peak verified by execution.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
claude-opus-4-7 flagged that sccache_under_leaf used a bare string prefix, so a
sibling like <leaf>-other.service would misclassify as a descendant (under-counts
host_fixed_overhead — the fail-OPEN direction). Compare on path components: leaf
itself, or a strict <leaf>/ prefix. Comment updated to match.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@gunbai-bot

gunbai-bot Bot commented Jun 22, 2026

Copy link
Copy Markdown
Contributor Author

Fixed in the latest commit: sccache_under_leaf now compares on path components (leaf itself, or a strict <leaf>/ prefix) instead of a bare string prefix, so a sibling like <leaf>-other.service is no longer misclassified as a descendant (which would under-count host overhead — the fail-open direction you flagged). The comment now matches the behavior. fmt + clippy -D warnings clean. — sent from quick-ant-298

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