patches/audition.cc: stale bank count in the allocation comment #63

Open
opened 2026-09-05 12:31:37 +00:00 by bcox · 1 comment
Owner

patches/audition.cc:200 reads:

// Not free: 28 allocations of a 200-voice pool instead of one. This is an

The bank is 30 patches as of modal-cymbals (it was 29 before, and 28 before
that), so the number has been stale through two additions. Bank.HasThirtyPatches
in patches/patches_test.cc is the live count.

Trivial, comment-only. Worth doing with a sweep for the same shape elsewhere:
this class of stale count has now been found three times in this repo --
CLAUDE.md's "29 patch names" (fixed on modal-cymbals), the
EveryBlobsMacroKnobsAreItsOwn header's blob counts (fixed on the same
branch), and this one. A count that has to be updated by hand on every patch
addition is a count that will go stale; if any of these can be derived from
patches::Count() instead, that is the better fix.

Found by the whole-branch review of modal-cymbals.

`patches/audition.cc:200` reads: // Not free: 28 allocations of a 200-voice pool instead of one. This is an The bank is 30 patches as of `modal-cymbals` (it was 29 before, and 28 before that), so the number has been stale through two additions. `Bank.HasThirtyPatches` in `patches/patches_test.cc` is the live count. Trivial, comment-only. Worth doing with a sweep for the same shape elsewhere: this class of stale count has now been found three times in this repo -- `CLAUDE.md`'s "29 patch names" (fixed on `modal-cymbals`), the `EveryBlobsMacroKnobsAreItsOwn` header's blob counts (fixed on the same branch), and this one. A count that has to be updated by hand on every patch addition is a count that will go stale; if any of these can be derived from `patches::Count()` instead, that is the better fix. Found by the whole-branch review of `modal-cymbals`.
Author
Owner

The bank is 31 as of branch fm-followups, which adds patches/chowning_horn.h -- so patches/audition.cc:200's "28 allocations" is now three additions stale rather than two.

That branch also introduces a second instance of the same shape: patches/patches_test.cc:264 reads "a 200-voice pool per patch to serialize 30 patches", which the branch itself made false. The live count moved correctly (Bank.HasThirtyOnePatches); only the prose counts drift.

This is the fourth and fifth instance of this shape in the repo, which strengthens the issue's own recommendation: derive these from patches::Count() rather than fixing the numbers again.

The bank is **31** as of branch `fm-followups`, which adds `patches/chowning_horn.h` -- so `patches/audition.cc:200`'s "28 allocations" is now three additions stale rather than two. That branch also introduces a second instance of the same shape: `patches/patches_test.cc:264` reads "a 200-voice pool per patch to serialize 30 patches", which the branch itself made false. The live count moved correctly (`Bank.HasThirtyOnePatches`); only the prose counts drift. This is the fourth and fifth instance of this shape in the repo, which strengthens the issue's own recommendation: derive these from `patches::Count()` rather than fixing the numbers again.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
bcox/tymbal#63
No description provided.