From 410f9c861197cf6296ab317535057c45a01cfc39 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ahmet=20Kaan=20G=C3=BCm=C3=BC=C5=9F?= Date: Fri, 25 Sep 2026 14:22:47 +0300 Subject: [PATCH] ec-av1: lane-av1-422r -- remeasure after the q Some(3): first remaining diff is still frame 0 plane U (0,23) ours=50 vs oracle=49, first of the 4491-sample decode_rect_split own-chroma keyframe gap (luma byte-exact, counts byte-identical to pre-fix), frames 1..8 diverge from (0,0) so the offset did NOT fix the inter walk, and the walk now panics at frame 9 in read_coeffs_rect (rect coeff scratch 36x36 < the 422 TX_32X64 chroma unit 36x68); stopped per charter (not one index), header refusal stays, report lanes/av1422r.report.md --- lanes/av1422r.report.md | 76 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 76 insertions(+) create mode 100644 lanes/av1422r.report.md diff --git a/lanes/av1422r.report.md b/lanes/av1422r.report.md new file mode 100644 index 00000000..60566a39 --- /dev/null +++ b/lanes/av1422r.report.md @@ -0,0 +1,76 @@ +# lane-av1-422r — REMEASURE after the q `Some(3)`: the first remaining diff is +# STILL frame 0 plane U (0, 23) ours=50 vs oracle=49 — first of the 4491-sample +# `decode_rect_split` own-chroma keyframe gap, NOT one wrong index — the +# inter-frame divergence PERSISTS (frames 1..8 differ from (0,0)), and the walk +# now PANICS at frame 9 in [`read_coeffs_rect`] (rect coeff scratch 36×36 < +# the 4:2:2 TX_32X64 chroma unit's 36×68). Stopped and named per charter. + +## Outcome + +1. Remeasured the pinned fixture (sha256 `d3fa4beeb1309033e4a03f5ae5c431c8fa + 8386ba1ada088684710423c7938129`) at 03be6bad against + `$HOME/.cache/aom-oracle/build/aomdec --rawvideo` (16 frames, i422), probe + dump `EC_PROBE_OUT16`, local `EC_AV1_ALLOW_422_PROBE` bypass, reverted + byte-identical after (`git status` clean before the report commit). Do not + trust the p-report diff numbers blindly: re-derived per-frame per-plane + first diffs from the raw dumps this session. +2. **The first remaining diff: frame 0, plane U, row 0, col 23, ours=50, + oracle=49.** Frame 0 luma is byte-exact; frame 0 carries 4491 U + 4888 V + diffs — the counts are byte-IDENTICAL to the pre-fix p-report measurement, + as expected: frame 0 is the keyframe and the pair16/4x32 arms never run + there. The class is [`decode_rect_split`]'s own-chroma gap (the live + `EC_RECTCHROMA_GAP luma=16x8 tx=8x8 chroma=8x8` diagnostics). 4491 samples + is not one wrong index → charter step 3: STOP and name the function: + **`decode_rect_split`** (own-chroma reconstruction at ss(1,0)). +3. **The offset suspect is refuted for the inter-frame divergence**: frames + 1..8 diverge from sample (0,0) in all three planes (frame 1: Y (0,0) + ours=78 oracle=80, U (0,0) 230 vs 87, V (0,0) 165 vs 245; plane totals + over 9 frames Y=258976, U=125891, V=124050). The q lane's `Some(3)` did + not sync the inter walk. Note the U/V frame-1 offsets are consistent with + MC inheritance of the already-wrong frame-0 chroma; the Y divergence + (frame 0 Y exact) is a separate inter-path question that cannot be + localized while chroma inherits the frame-0 gap. +4. **New hard stop, frame 9**: `read_coeffs_rect` panics + `rect coeff scratch w=32 h=64 n=2448` (decode.rs:7129, panic at :7195). + The scratch bound `n <= 36*36` covers ≤32×32 units; a 64×64 luma block at + ss(1,0) has plane_bsize `ss_size_lookup[BLOCK_64X64][1][0]` = BLOCK_32X64 + (NOT invalid — unlike the p/q chunks), `max_txsize_rect_lookup` reads + TX_32X64, and (32+4)×(64+4) = 2448 exceeds the bound. Frames 9..15 are + unmeasurable until this is lifted. This shape never fired pre-fix because + the unsynced walk never reached it. +5. 4 u16 samples out of 8-bit range across frames 0..8 (the p report's + unclipped-output class, still unattributed; was 2+6 over 16 frames). + +## Decision + +- First diff is a 4491-sample class → no one-index fix exists; stopped per + charter. Functions named: [`decode_rect_split`] (owns the first diff) and + [`read_coeffs_rect`] (scratch capacity, blocks frames 9+). +- Header refusal STAYS: delete condition unmet (not pixel-exact — frame 0 + alone carries 9379 chroma diffs; no full-stream proof possible with the + frame-9 panic). `stream.rs` untouched; the bypass was local-only and is + not in the commit. + +## Verification + +- Ours: 9 complete frames dumped before the panic (147456 B/frame u16); + oracle: 16 frames i422. Stride-checked comparison (u16 elements vs bytes — + the first compare script had a byte/element stride bug; frame 0's numbers + were unaffected and frames 1..8 were re-derived at the correct stride). +- `cargo check -p ec-av1` (target `~/.cache/cargo-target-av1422r`): 0 + warnings, 0 errors. +- 420 gate green under `EC_AV1_REQUIRE_AOMENC=1`: + `stream::tests::a_real_aomenc_stream_with_a_skipped_8x8_intra_leaf_ + whose_tx_split_decodes_pixel_exact`: 1 passed, 0 failed. +- `git status` clean after bypass revert; this commit carries ONLY this + report. + +## State + +- Commit on lane-av1-422r (no push): this report, nothing else. +- Next stop named for the owning lane: lift [`read_coeffs_rect`]'s scratch + bound for TX_32X64 (36×68 levels — likely a heap fallback like + [`read_coeffs`]'s, or a 68-row stack tier), re-run the 16-frame remeasure, + THEN take the frame 1 luma (0,0) inter divergence with frame-0 chroma + inheritance accounted for; [`decode_rect_split`]'s own-chroma gap remains + the owner of the literal first diff.