From fbed1b614e7b3bfe63435e9dfe9c81fd442d8c0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ahmet=20Kaan=20G=C3=BCm=C3=BC=C5=9F?= Date: Wed, 30 Sep 2026 01:22:26 +0300 Subject: [PATCH] gate_coverage: lower the count-vacuity unpinned ceiling 43 -> 2 The number the nine stream.rs commits above bring it to, with the two that survive the round named in the comment. Neither is a count to fix: * an_svt_screen_palette_block_with_a_split_transform_decodes_exactly reads its stream from the path EC_AV1_SVT1_STREAM names, and that crop is not committed to fixtures/ -- so no encode recipe, no --limit, no -frames:v and no frame count exists anywhere in the tree for it. The doc comment's "12-frame stream" is prose about one capture, and the env var accepts any file, so asserting 12 would pin a number nothing can check. Deriving one from the stream's own OBU frame headers is left on the table deliberately: the gate SKIPs on any box without that env var, so such an assert would ship unexercised. * the second is a '///' doc comment quoting the pre-r4 body of pinned_lr_sgr_stream_call_unique_dump -- the sweep's line-based scan cannot tell a doc comment from code. The gate it describes already spends FRAMES and asserts pics.len() == FRAMES. The floor (>= 40 sites) is untouched and the site population is unchanged at 60: the fixes assert the encode's count ABOVE the call rather than spending a named constant in place of .len(), so each site moves from "not spec-pinned" to "spec-pinned by a prior assert" instead of vanishing from the class. 41 sites become pinned and 43 - 41 = 2 remain. Red-before for all 41 at once: with this ceiling and stream.rs reverted to 3b691e13, the guard reds with "43 unpinned count site(s), ceiling is 2". Since each fix removes exactly one site from the unpinned population, removing any one of the 41 asserts puts unpinned at 3 and reds this same assert. --- crates/ec-av1/src/gate_coverage.rs | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/crates/ec-av1/src/gate_coverage.rs b/crates/ec-av1/src/gate_coverage.rs index 1aaf14a9..85d04d44 100644 --- a/crates/ec-av1/src/gate_coverage.rs +++ b/crates/ec-av1/src/gate_coverage.rs @@ -2414,8 +2414,30 @@ mod count_vacuity_tests { // A CEILING on the unpinned population, so a NEW site cannot be added // silently. Lower it as sites are fixed; a fix that does not lower it is // still a fix, but a NEW site is an immediate red. + // + // lane-av1pinspec: 43 -> 2. Each of the 41 fixes adds the ENCODE's own + // frame count as an `assert_eq!` ABOVE the `ffmpeg_decode_sequence*` + // call (`-frames:v 1` / `-vframes 1` / `--limit=N` / a helper's `frames` + // parameter / the arm tuple's `frame_count` / the wire's own OBU frame + // headers), so the count handed to the oracle is a value already proven + // against the encode instead of read off our decode. The two that remain + // are the two that are not a count to fix: + // * `an_svt_screen_palette_block_with_a_split_transform_decodes_exactly` + // reads the path `EC_AV1_SVT1_STREAM` names, and that crop is not + // committed to `fixtures/`, so no `--limit`, no `-frames:v` and no + // frame count exists anywhere in the tree for it. The doc comment's + // "12-frame stream" is prose about one capture and the env var + // accepts any file, so asserting 12 would pin a number nothing can + // check. Counting the stream's own OBU frame headers with + // `Av1Parser` would derive one, and is left on the table + // deliberately: the gate SKIPs on any box without that env var, so + // such an assert would ship unexercised. + // * a `///` DOC COMMENT quoting the pre-r4 body of + // `pinned_lr_sgr_stream_call_unique_dump`, which this line-based + // scan cannot tell from code. The gate it describes already spends + // `FRAMES` and asserts `pics.len() == FRAMES`. + const UNPINNED_CEILING: usize = 2; let unpinned = s.iter().filter(|x| x.pinned_by.is_none()).count(); - const UNPINNED_CEILING: usize = 43; assert!( unpinned <= UNPINNED_CEILING, "{unpinned} unpinned count site(s), ceiling is {UNPINNED_CEILING} -- a new one \