Repository navigation
build: keep line-table debug info only in dev and test profiles - #756
Merged
Merged
Conversation
Set debug = "line-tables-only" for [profile.dev] and [profile.test]. Backtraces keep function, file and line; debugger locals need CARGO_PROFILE_DEV_DEBUG=2 / CARGO_PROFILE_TEST_DEBUG=2. The release profile is unchanged, so product binaries and measurements are not affected. CI already sets CARGO_PROFILE_TEST_DEBUG=0 and is unaffected. Diagnostic build check, taken on main 7d42d0b before rebasing here (one cold sample per arm, layerfs-content only, cargo 1.85.1, macOS aarch64, -j 6, host 1-min load 8.8-13.9 from other sessions; not a product measurement): - cargo build --tests: 26.6 s -> 14.3 s wall, 66.4 -> 49.9 s user; target 964 -> 800 MB (-17%), deps 471 -> 347 MB (-26%) - cargo test --no-run: 34.5 s -> 31.9 s wall, 162.8 -> 143.7 s user; target 1092 -> 865 MB (-21%); test executables unchanged on macOS (debug info stays in object files there) Production LOC: 206163 -> 206163 (delta 0); scope core+engine+control+api, tools/production_loc.py at parent 2f6718e and committed tree; manifest-only change. Reference absent (retired R9c; last counted 65,417 at tree 498dd19). Deleted tests: none. 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
Sets
debug = "line-tables-only"in[profile.dev]and[profile.test](rootCargo.toml). Manifest-only change.CARGO_PROFILE_DEV_DEBUG=2/CARGO_PROFILE_TEST_DEBUG=2(noted in the manifest comment).CARGO_PROFILE_TEST_DEBUG=0inci.yml,nightly.ymlandstore-ext4.yml, so CI is unaffected.Diagnostic build check
One cold sample per arm,
layerfs-contentonly, cargo 1.85.1, macOS aarch64,-j 6, host 1-min load 8.8–13.9 from other sessions. Taken on main7d42d0b506before rebasing onto v2. Not a product measurement.cargo build --tests(dev)cargo test --no-run(test)On macOS, debug info stays in object files, so executables barely change there; Linux builds should also shrink binaries (not measured).
After this lands, each existing worktree target rebuilds once and keeps old artifacts until it is cleaned (
tools/cleanup.py).Checks
cargo +1.85.1 test -p layerfs-content --no-run --locked --offlinecompiles on this branch (base2f6718e193).tools/production_loc.pyat parent2f6718e193and the committed tree.🤖 Generated with Claude Code