Repository navigation
Fix srv1_floor_memory_budget: use real runner cgroup cap (8 GiB) instead of whole-run-peak × margin - #5836
Merged
Conversation
…measurement.dag gunbc_ci_floor_runner_margin_num/den and gunbc_ci_floor_whole_run_peak_rss_bytes had no remaining consumers after within_run_spawn_budget() was retired in the prior commit. Delete them to close the §5 specification-without-execution gap: the budget_tree.dag prose claimed they were deleted but they were still present. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Generated from plans/budget_tree.dag which already noted the deletion. Addresses reviewer non-blocking note on #5836. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
gunbai-bot Bot
pushed a commit
that referenced
this pull request
Jun 26, 2026
…nflicts Conflicts resolved: - ci_floor_measurement.dag: keep gunbc_ci_host_container_memory_cap_disposition data item from this branch (absent on main after #5836) - plans/budget_tree.dag: use main's more accurate provenance note (explicitly names deleted margin constants and gunbc_ci_floor_whole_run_peak_rss_bytes) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This was referenced Jun 26, 2026
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.
Summary
srv1_floor_memory_budget()now returnsgunbc_per_runner_memory_cap(the real 8 GiB cgroup cap) directly, replacingwithin_run_spawn_budget()which computedwhole-run-peak × (6/5) ≈ 13.9 GiB— a budget that never matched the actual binding constraintwithin_run_spawn_budget()and the orphaned margin constants (gunbc_ci_floor_runner_margin_num/den,gunbc_ci_floor_whole_run_peak_rss_bytes) which had no remaining consumer after this changewitness_spawn_width_budget_deconflated→witness_spawn_width_budget_is_per_runner_capto reflect the corrected invariantWhy the old budget was wrong
within_run_spawn_budget()usedgunbc_ci_floor_whole_run_peak_rss_bytes() × (6/5)as the budget passed tomemory_aware_spawn_width. That whole-run peak (~11.6 GiB) × 1.2 ≈ 13.9 GiB — larger than the actual 8 GiB cgroup cap. The spawn-width formula therefore operated against a phantom budget, makingspawn_width = floor(13.9 × 4/5 / per_shard)instead of the correctfloor(8 × 4/5 / per_shard).Consequence named up front
With the corrected budget and the unmodified
per_shardvalue (2.1 GiB from main),spawn_width = floor(8 × 4/5 / 2.1) = 3. The real cgroup footprint per shard (~3.5 GiB including rustc children from emit_host_gate) means width=3 still exceeds 8 GiB — the floor will remain red on OOM until the footprint reductions land (tidy-wren-707 resolve env de-merge + emit-host batch isolation). That red is accepted. This PR only fixes the budget model; the per_shard reground is a separate PR once real footprint drops.Not in this PR
Test plan
.dagcompile clean:ci_budget_tree.dagandci_budget_tree_witness_test.dagcompile against unchangedci_floor_measurement.dag(orphaned symbols remain in measurement.dag until a future cleanup)witness_spawn_width_budget_is_per_runner_cappasses:srv1_floor_memory_budget()==gunbc_per_runner_memory_cap> 0 <srv1_host_ram()within_run_spawn_budgetreference removed from all consumers (only consumer wassrv1_floor_memory_budget)🤖 Generated with Claude Code