docs+ec-av1: lane-av1444rect r5 -- the counters document that they prove reach, not that the fix bites; the retraction derives its length from plane extents
Browse files at this commit4b6247dc1423a96d924f10e6bb07c3fb5a4b7f41Parent: cc3c8e32 changed files +38 -6
- crates/ec-av1/src/decode.rs +19 -6
- lanes/av1444rect.report.md +19 -0
crates/ec-av1/src/decode.rsmodified+19 -6
| @@ -5508,8 +5508,10 @@ pub(crate) fn intra_rect4_strip_in_inter_hits(shape: usize) -> usize { | |||
| 5508 | // coefficient context over the STRIP'S OWN extent instead of the 4:2:0 pair's | 5508 | // coefficient context over the STRIP'S OWN extent instead of the 4:2:0 pair's |
| 5509 | // (see [`decode_inter_block`]'s `around_c`). `is_chroma_reference` | 5509 | // (see [`decode_inter_block`]'s `around_c`). `is_chroma_reference` |
| 5510 | // (av1_common_int.h:1454) is unconditionally true at ss (0,0), so no pair | 5510 | // (av1_common_int.h:1454) is unconditionally true at ss (0,0), so no pair |
| 5511 | -// exists there; the counter is what keeps a 4:4:4 1:4-strip gate from passing | 5511 | +// exists there; the counter keeps a 4:4:4 1:4-strip gate from passing |
| 5512 | -// vacuously (a 4:2:0 stream of the same content leaves it at 0). | 5512 | +// vacuously (a 4:2:0 stream of the same content leaves it at 0). It proves |
| 5513 | +// REACH only, never that the fix bites -- that is the gate's byte compare and | ||
| 5514 | +// its mutation, not this count (skill://ec-av1-pipeline-gate-counters). | ||
| 5513 | thread_local! { | 5515 | thread_local! { |
| 5514 | static RECT4_INTER_OWN_CHROMA444_HITS: std::cell::Cell<usize> = const { std::cell::Cell::new(0) }; | 5516 | static RECT4_INTER_OWN_CHROMA444_HITS: std::cell::Cell<usize> = const { std::cell::Cell::new(0) }; |
| 5515 | } | 5517 | } |
| @@ -5526,10 +5528,21 @@ pub(crate) fn reset_rect4_inter_own_chroma444_hits() { | |||
| 5526 | RECT4_INTER_OWN_CHROMA444_HITS.with(|c| c.set(0)); | 5528 | RECT4_INTER_OWN_CHROMA444_HITS.with(|c| c.set(0)); |
| 5527 | } | 5529 | } |
| 5528 | 5530 | ||
| 5529 | -// lane-av1444rect r2: how many intra-BC 1:4 strips at `ss (0,0)` coded their | 5531 | +// lane-av1444rect r2: how many intra-BC 1:4 strips at `ss (0,0)` took the |
| 5530 | -// OWN 16x4 / 4x16 chroma plane block instead of the 4:2:0 pair's 8x4 (see | 5532 | +// own-chroma arm of [`decode_rect4_16_intrabc`]'s `own444`. A 4:2:0 / 4:2:2 |
| 5531 | -// [`decode_rect4_16_intrabc`]'s `own444`). A 4:2:0 / 4:2:2 stream of the same | 5533 | +// stream of the same recipe leaves it at 0, which is what makes it the |
| 5532 | -// recipe leaves it at 0, which is what makes it the 4:4:4-only route. | 5534 | +// 4:4:4-only route. |
| 5535 | +// | ||
| 5536 | +// WHAT THIS COUNTER IS NOT: it is NOT evidence that the fix bites, and it | ||
| 5537 | +// never was. A route counter fires identically before and after a change that | ||
| 5538 | +// changes nothing downstream, so a non-zero count proves REACH and nothing | ||
| 5539 | +// more. On this lane it is also armed deliberately OUTSIDE the `own444` | ||
| 5540 | +// expression, so that the mutation (`own444 = false`) still increments it and | ||
| 5541 | +// the red comes from the pixel/entropy arm instead. The evidence that the ss | ||
| 5542 | +// gate bites is the measured fork move -- first entropy fork read 11750 -> | ||
| 5543 | +// 12465, luma first wrong sample 164416 -> 205264, 455240 -> 390380 total -- | ||
| 5544 | +// not this count. See skill://ec-av1-pipeline-gate-counters: a counter needs | ||
| 5545 | +// a DIFFERS-style assertion to carry a claim. | ||
| 5533 | thread_local! { | 5546 | thread_local! { |
| 5534 | static INTRABC_RECT4_OWN_CHROMA444_HITS: std::cell::Cell<usize> = const { std::cell::Cell::new(0) }; | 5547 | static INTRABC_RECT4_OWN_CHROMA444_HITS: std::cell::Cell<usize> = const { std::cell::Cell::new(0) }; |
| 5535 | } | 5548 | } |
lanes/av1444rect.report.mdmodified+19 -0
| @@ -190,6 +190,16 @@ clamp on a 4:4:4 chroma TX_32X64 is still the prime suspect. Re-measured | |||
| 190 | here to prove the class claim above: H2's numbers are bit-identical before | 190 | here to prove the class claim above: H2's numbers are bit-identical before |
| 191 | and after, so this fix neither caused nor cured it. | 191 | and after, so this fix neither caused nor cured it. |
| 192 | 192 | ||
| 193 | +> **Derive the length, do not copy the multiplier.** The re-measurement | ||
| 194 | +> below writes `assert len(ours) == 2 * len(ref)`. That factor is a | ||
| 195 | +> **coincidence of 4:4:4 against 4:2:0 at the same geometry** — our `dump_yuv` | ||
| 196 | +> emits `u16` per sample while the oracle's 8-bit dump is `u8`, so the factor is | ||
| 197 | +> the bits-per-sample ratio and has nothing to do with chroma. At 4:2:2, at a | ||
| 198 | +> high bit depth, or on any fixture where the two sides do not agree on bit | ||
| 199 | +> depth, `2 *` is simply wrong. Compute the expected byte length from the plane | ||
| 200 | +> extents and the two bit depths (and assert the oracle's dump length against | ||
| 201 | +> that, not against a constant) before comparing anything. | ||
| 202 | + | ||
| 193 | **H3: RETRACTED — my first claim was void, Agent142-2's measurement stands.** | 203 | **H3: RETRACTED — my first claim was void, Agent142-2's measurement stands.** |
| 194 | I reported this stream "byte-exact 6/6". It is not. My throwaway compare | 204 | I reported this stream "byte-exact 6/6". It is not. My throwaway compare |
| 195 | script hardcoded the frame geometry to 128x96 (the H1 fixture's) and | 205 | script hardcoded the frame geometry to 128x96 (the H1 fixture's) and |
| @@ -386,6 +396,15 @@ other fired 4800 msac bits away. | |||
| 386 | 396 | ||
| 387 | ## 8. Method notes for the next lane | 397 | ## 8. Method notes for the next lane |
| 388 | 398 | ||
| 399 | +- **A route counter is not proof a fix bites.** This lane learned it the hard | ||
| 400 | + way: a counter can fire identically before and after a change that changes | ||
| 401 | + nothing downstream, so a non-zero count proves REACH and nothing more. Both | ||
| 402 | + counters this lane added carry that warning in their own doc comment, and | ||
| 403 | + the intra-BC one is deliberately armed OUTSIDE the `own444` expression so the | ||
| 404 | + mutation still increments it and the red lands on the pixel/entropy arm | ||
| 405 | + instead. What carries the claim is the measured fork move and the mutation | ||
| 406 | + red. Rule now in skill://ec-av1-pipeline-gate-counters: a counter needs a | ||
| 407 | + DIFFERS-style assertion before it can carry a claim. | ||
| 389 | - `testsrc2` is time-parameterised: any sweep recipe quoting it must pin | 408 | - `testsrc2` is time-parameterised: any sweep recipe quoting it must pin |
| 390 | `rate`, or the fixture is not reproducible. `rate=1` vs `rate=25` on | 409 | `rate`, or the fixture is not reproducible. `rate=1` vs `rate=25` on |
| 391 | 128x96 yuv444p is the difference between an 8121-byte exact stream and | 410 | 128x96 yuv444p is the difference between an 8121-byte exact stream and |