Repository navigation
Cargo: host test builds carry line tables; harness-job comments after #1386 - #1389
Merged
Merged
Conversation
[profile.test] debug = "line-tables-only". cargo test builds every unit of the host unit suite (workspace libraries and third-party crates included) with the test profile, which inherited full DWARF from dev in the main checkout; lanes and CI already trim dev through a cargo config, which test inherits, so for them the unit graph is unchanged. dev is untouched. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Makefile (check-python-harness) and ci.yml (host-python-harness) described DepGates as running the whole of ci/check-deps.sh per test, with 175 s / 661 s figures; since #1386 each self-test runs only the rules it plants for. Both now say so, with the CI step times read from main's runs on 2026-11-14 (144-196 s after, 380-500 s before). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…t has line tables The test-profile setting falsified three statements: the build-gc.sh lane policy named CARGO_PROFILE_DEV_DEBUG=2 as the way to get DWARF in a host test (it is CARGO_PROFILE_TEST_DEBUG=2 now), and agent-reference.md, cargo-seed.py and the host-rust action said the main checkout keeps full DWARF without saying it is the dev profile's. The policy marker stays v2: cargo-seed.py hashes every applying cargo config byte for byte, and a version bump would also flip between lanes on older and newer build-gc.sh. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… check covered dev builds Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…profile Both said the host tests run the dev profile; they run the test profile, which inherits dev. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… change
The [profile.test] table added to rust-modules/Cargo.toml changes the root
manifest's pinned hash (workspace.manifests["Cargo.toml"]), so the serde_json
read-only certificate is regenerated with the documented producer
(ci/readonly_dependencies.py --produce) and CERTIFICATE_SHA256 is re-pinned to
the new canonical hash. Regenerated with the owner's explicit approval
("Approve re-pin", 2026-11-14).
Exactly two hashes change: the root Cargo.toml manifest hash, and the lib_sha256
of ui/src/lib.rs, which had been stale since 6a74d2a.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… manifest change ci/proofs/platform-generated-enums.json pins the root Cargo.toml by hash too, so the [profile.test] table makes the generated-unit-enum proof return None and the machine-shape gates that rest on it fail. The one changed value is manifests["Cargo.toml"] (fbeb9007... -> c57b1c2d...), the same root-manifest hash the serde_json certificate takes in the previous commit; the file is verified equal to readonly_generated.produce_certificate output and CERTIFICATE_SHA256 is re-pinned to its canonical hash (c737368b...). Re-certified with the owner's explicit approval (2026-11-14). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
rust-modules/Cargo.toml:[profile.test] debug = "line-tables-only". Host unit-test builds in the main checkout stop writing full DWARF.Makefilecomment abovecheck-python-harness, the.github/workflows/ci.ymlcomment abovehost-python-harness).tools/build-gc.sh(lane policy text),docs/agent-reference.md,tools/cargo-seed.py,.github/actions/host-rust/action.yml.Which units the setting reaches
cargo testbuilds EVERY unit of the host unit suite with thetestprofile, not just the test harness: the 18 test binaries, the workspace library units under them and the third-party library units (cargo test --lib --no-run --unit-graphon the Makefile's-plist namesprofile.name = "test"for all of them; a-vbuild shows-C debuginfo=followingCARGO_PROFILE_TEST_DEBUGforplx_base/plx_machine/plx_gfx/plx_platformrlibs). Thetestprofile inheritsdev, so until now it carried whateverdevhad.Reached:
make check'scheck-cargo-unit-*,make test-fast,make test-crate,make test-hostsim,make build-bench, and the CI host unit jobs.Not reached:
[profile.dev].make sim-macosis acargo build(dev) andsim-linux/macapp/ the ARM library use--releaseor--profile tvdev; no recipe passes--profile test.make lint/make check-nodefarecargo clippy/cargo check(dev, no codegen).Lanes and CI: no change.
.claude/worktrees/.cargo/config.toml(tools/build-gc.sh) and CI's~/.cargo/config.toml(host-rust action) already set[profile.dev] debug = "line-tables-only"and[profile.dev.package."*"] debug = false, whichtestinherits; the--unit-graphJSON of the whole suite is byte-identical before and after this change in a lane. Only the owner's main checkout (full-DWARFdev) changes. There, third-party crates move from full DWARF to line tables too (a manifestdebugapplies to them; a package override would be the next step, not taken here).Bench: how it was made representative of the main checkout
A bench run in a lane would show nothing (the lane config zeroes the difference). So base and head were measured in two scratch
git worktrees OUTSIDE.claude/worktrees/(no lane config, no~/.cargo/config.toml), i.e.dev= full DWARF as in the main checkout. Checked first with--unit-graph: base has debuginfo 2 on all 18 test units, the 17 workspace library units and 100 third-party library units (the rest are host build scripts / proc-macros at 0); head hasline-tables-onlyon exactly those units.Command, each tree (
make build-bench ARGS="--only leaf,ui,hub,leaf-inc,hub-inc,tests --cold --runs 3"; the second pair of runs left outtestsand--cold), run alternately base, head, base, head on the same warm trees. Apple M4, 10 cores, rustc 1.100.0. Basede6a21c0c, head9b2ad8371(the later commits only change comments and prose). Medians of 3 per run, seconds:target-fast)Each head run against its adjacent base run, non-incremental rows: leaf -14.9% / -22.1% / -17.3%, ui -14.5% / -20.8% / -14.0%, hub -14.8% / -20.6% / -13.4% (the machine was shared with other lanes and ran slower in the second half, on both sides; the loaded first rounds are in the medians' tails, not the medians). Disk,
duofrust-modules/target+target-fastafter the runs: 3.13 GB + 6.43 GB (base) -> 2.47 GB + 5.29 GB (head), -19%.What this does NOT show: the incremental loop (
make test-fast,make test-crate) is not clearly faster.hub-incis flat;leaf-increads -4% against the first base run and -26% / -29% against the second, because the baseline itself drifted from 16.1 s to 21.8 s between the two base runs. The measured gain is in non-incremental test builds (make check's cargo leg,build-bench, a cold or re-keyed tree).What is lost, and the escape hatch
Variable-level debug info in host test binaries of the main checkout:
lldb/rust-lldbon a test no longer shows locals or types. Panic backtraces keep file:line (that is what a line table is for). To get full DWARF back for one run:CARGO_PROFILE_TEST_DEBUG=2 make test-crate ...(orcargo test --config profile.test.debug=2).CARGO_PROFILE_DEV_DEBUG=2, the old hatch intools/build-gc.sh's lane policy, no longer reaches acargo testbuild because the manifest's explicittestvalue outranks whattestinherits fromdev; that text is corrected.Costs to know
target/debug/deps(tools/build-gc.sh --stalesweeps them once they are old enough).tools/cargo-seed.pykeys the seed on the manifest bytes, so lanes re-seed once.rust-cachekey hashesrust-modules/Cargo.toml, so the host jobs have one cold build; the units themselves are unchanged for CI (identical unit graph).tools/build-gc.shstaysv2on purpose: the installer replaces any marked file that lacks the exact current marker, so a bump would flip the file between lanes on older and newerbuild-gc.sh, andcargo-seed.pyhashes every applying cargo config byte for byte. The corrected text reaches fresh installs only; the installed comment stays as it was (a comment in an untracked file).The comment fixes
Makefileabovecheck-python-harness: saidDepGatesruns the whole ofci/check-deps.sh(11 s a run) per test and quoted 175 s / 661 s. Now: about 70 self-tests, each runningci/check-deps.sh --only <its rules>(Harness: each DepGates self-test runs only the rule it plants for #1386), on the thread pool; CI's harness step measured 144-196 s on main's commits after Harness: each DepGates self-test runs only the rule it plants for #1386 and 380-500 s before it (gh run view, 2026-11-14)..github/workflows/ci.ymlabovehost-python-harness: same correction;timeout-minutes: 15untouched.Gates
Committed tree,
git status --shortempty before and after, head603d477f5:cd ci && python3 -m unittest test_ci_workflows test_ci_split test_dependencies:Ran 124 tests in 3.245s/OKcd ci && python3 test_arm_profile.py:Ran 24 tests in 32.613s/OKcd ci && python3 -m unittest test_build_gc test_cargo_seed(after the last edit):Ran 112 tests in 87.139s/OK (skipped=1); withtest_test_fast test_no_host_staticlibon the previous commit:Ran 132 tests/OK (skipped=1)make test-crate C=plx_base:test result: ok. 272 passed; 0 failed; 0 ignored; 0 measured; 0 filtered outmake check-nodef: exit 0 (Finished dev profile [unoptimized + debuginfo] target(s) in 17.81s)After the two read-only re-certifications below, head
e47fbee18(commitsacd3c123e,e47fbee18),git status --shortempty before and after:python3 ci/test_readonly_dependencies.py:Ran 64 tests in 1.113s/OK(11 failures before the serde_json re-pin)python3 ci/test_machine_readonly.py:Ran 34 tests in 0.227s/OKpython3 ci/test_readonly_generated.py:Ran 20 tests in 0.655s/OK(8 failures and 1 error before the generated-enums re-pin)make check-python-rest:==== check: 136 steps — all ok (191s wall, 454s cpu, 4 at once; slowest: test_build_gc.py 89s, test_disk_budget.py 55s, test_disk_preflight.py 42s) ====(4 of 136 steps failed before the generated-enums re-pin:test_check_machine_shape.py,test_transition_arguments.py,check-machine-shape.py,test_readonly_generated.py)Read-only certificates re-certified with the owner's explicit approval (2026-11-14), because
[profile.test]changes the rootrust-modules/Cargo.tomlhash both pin:ci/proofs/serde-json-immutable.json(regenerated withci/readonly_dependencies.py --produce):workspace.manifests["Cargo.toml"]fbeb9007... -> c57b1c2d..., andui/src/lib.rslib_sha256c77775a6... -> 616bd784... (stale on main since6a74d2a8b, included with the owner's approval);CERTIFICATE_SHA256inci/readonly_dependencies.py7a299a63... -> 29e62dc1... .ci/proofs/platform-generated-enums.json:manifests["Cargo.toml"]fbeb9007... -> c57b1c2d... only (the file is equal toreadonly_generated.produce_certificateoutput);CERTIFICATE_SHA256inci/readonly_generated.pyb61be9b4... -> c737368b... .Not run: the full
make check(the unit suite itself passed in the bench on a main-like config: 13429 passed / 0 failed / 116 ignored, base and head).pr-reviewerran once on the combined diff (one MINOR, fixed in the last commit);doc-claim-auditoris left to the manager.🤖 Generated with Claude Code