Skip to content

fix(test): 🐛 pause the collector while an allocation gate measures - #369

Merged
justapithecus merged 1 commit into
mainfrom
andrew/fix/test/volume-byte-gate
Nov 6, 2026
Merged

justapithecus merged 1 commit into
mainfrom
andrew/fix/test/volume-byte-gate

Conversation

@justapithecus

@justapithecus justapithecus commented Nov 6, 2026 •

Copy link
Copy Markdown
Member

Summary

The Volume commit gate failed on macOS at 252,064 bytes per run against a ceiling of 252,032. One commit allocates about 252 KB, so the 100 commits of a measurement trigger several garbage collections, and each collection empties the sync.Pool caches that the commits reuse. The gates now pause the collector while they measure, so the timing of a collection no longer moves a figure.

Highlights

  • RunAllocGates pauses the collector for each measurement, and a collection still runs before each measurement.
  • With the collector paused, the commit gate measures 135 allocations in all 150 local runs, so the commit gate's allocation ceiling falls from 136 to 135. Its byte ceiling remains 252,032.
  • In a few runs, the read gates measure two more allocations than usual, and pausing the collector does not remove that difference. Their ceilings already cover both counts and remain unchanged.
  • docs/BENCHMARKS.md explains the pause and lists the new ceiling.
  • The change touches tests and documentation only, so it needs no release.

Test plan

  • The lint, test, race, and gates tasks pass.
  • The gates pass in 150 consecutive local runs of the Volume package.
  • The local Luna review reports no findings.
  • The Bosun check passes.
  • The macOS test job passes in CI.

No-Issue: macOS gate failure on #368

🤖 Generated with Claude Code

The Volume commit gate failed on macOS at 252,064 bytes per run against a ceiling of 252,032. One commit allocates about 252 KB, so the 100 commits of a measurement trigger several garbage collections. Each collection empties the sync.Pool caches. The commits then allocate again the objects that those caches held, and the amount depends on the timing of each collection.

- The gates now pause the collector during each measurement. A collection still runs before each measurement.
- With the collector paused, the commit gate measures 135 allocations in all 150 runs, so this change lowers its allocation ceiling from 136 to 135. Its byte ceiling stays at 252,032.
- In a few runs, the read gates measure two more allocations than usual, and pausing the collector does not remove that difference. Their ceilings already cover both counts and remain unchanged.
- docs/BENCHMARKS.md explains the pause and lists the new ceiling.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@justapithecus justapithecus changed the title andrew/fix/test/volume byte gate fix(test): 🐛 pause the collector while an allocation gate measures Nov 6, 2026
@justapithecus
justapithecus marked this pull request as ready for review November 6, 2026 22:29
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-06T22:30:35.246410Z 3565dd0 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@justapithecus
justapithecus merged commit 19c762c into main Nov 6, 2026
12 checks passed
@justapithecus
justapithecus deleted the andrew/fix/test/volume-byte-gate branch November 6, 2026 22:35
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