Repository navigation
Conversation
…gate (#3138) The maintainer decided (#3138) that `audio_mix/buffering_add_one_tick` stays above the 1.10 ratio: after #3141 removed the real inefficiencies the residual is the Rust/C boundary itself (~46 ns vs ~41 ns per call, once per audio tick), and the recorder should record that as an exemption rather than a breach. So the gate needs a named exemption, its reason in the report, and the over-bound case must use a pair that is not exempt. Fails on this commit: `record.RATIO_EXEMPTIONS` does not exist, and `over_bound` still reports the exempt pair.
The maintainer decided (#3138) that `audio_mix/buffering_add_one_tick` stays above the 1.10 ratio and is exempt instead: what is left after #3141 is the Rust/C boundary itself (~46 ns vs ~41 ns per call, once per audio tick). - `RATIO_EXEMPTIONS` names the pair with that absolute cost and reason; `summarize` keeps the reason in the row as `exemption` and its status reads `exempt from the ratio bound`, so the report shows the decision. - `over_bound` skips an exempt pair, so `--max-ratio 1.10` passes on a run that records it at 1.157 and still fails on any other breach. - `docs/rust-port/release-criteria.md` records the exemption next to the bound. End-to-end: `record.py --category audio_mix --repeats 3 --cpu 7 --max-ratio 1.10` exits 0 and records 1.157 with the exemption.
Member
Author
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.
Fixes #3138.
The maintainer decided on #3138 (option 1):
audio_mix/buffering_add_one_tickstays above the 1.10 ratio and is exempted by name in the recorder, with
its absolute cost recorded — do not add the
push_ts_frontfast path. Since#3141 removed the real inefficiencies, what is left (~46 ns vs the C's ~41 ns,
once per audio tick) is the Rust/C boundary itself.
Change
record.pygainsRATIO_EXEMPTIONS, one entry per exempt pair: theabsolute cost, the reason, and the decision that made it.
summarizekeepsthat reason on the row (
exemption) and itsstatusreadsexempt from the ratio bound, so a report shows the decision instead of asilent pass.
over_boundskips an exempt pair, so--max-ratiostill fails every otherbreach.
docs/rust-port/release-criteria.mdrecords the exemption beside the bound.RED
24dce5672adds the tests only:The over-bound case now uses
format/i420_to_uyvx/1080p, so the gate keeps awitness that is not exempt.
GREEN
17c6be328adds the exemption.Ran 16 tests ... OK.End-to-end, on this host, warm caches (
--cpu 7, three complete runs):The recorded row, in a loaded-box run:
{"benchmark": "audio_mix/buffering_add_one_tick", "rust_over_c": 1.157, "status": "exempt from the ratio bound", "exemption": "~46 ns vs the C's ~41 ns per call, once per audio tick: ..."}Every other
audio_mixpair in that run is at or below the bound (0.26-1.06).Checks:
uv run ci/local_gate.py --lane lintok (55.7 s),test_benchmark_record.py16 tests OK.
Noticed, not fixed here
summarizerenders the bound as{BOUND:.0%}, andBOUNDis a ratio, so apassing row's status reads
within 110% bound(and a breachover 110% bound).That predates this PR and is only a label; I left it out to keep this unit to
the exemption, and can file it as an
infra:follow-up if you want it fixed.