Commits
Commits on
84fa44cfe66f76e22181d4ff8bc06ef6ea78db072026-09-28
ec-av1: lane-av1444rect -- a 1:4 inter strip's chroma context was gathered at the 4:2:0 pair extent at ss (0,0), forking the coder (H1)Ahmet Kaan Gümüş · 84fa44c
ec-av1: lane-av1444rect -- a 1:4 inter strip's chroma context was gathered at the 4:2:0 pair extent at ss (0,0), forking the coder (H1) At 4:4:4 `is_chroma_reference` (av1_common_int.h:1454) reduces both parity clauses to `!subsampling_y` / `!subsampling_x`, so EVERY block is its own chroma reference and no 1:4 pair exists. `decode_inter_block`'s `around_c` never gated on ss, so a HORZ_4 16x4 strip read its chroma coefficient context over the 4:2:0 pair extent (16x8 luma = left[mi_r] and left[mi_r+1]) instead of its own 4-px one. The U unit's `get_txb_ctx` then saw a left neighbour libaom does not have and forked the arithmetic coder. The 4:4:4 lossy + RECT cell -- the largest correctness gap the chroma-format sweep left (lanes/av1formatsweep.report.md H1) -- had NO exactness gate at all: the whole committed 4:4:4 base is lossless 8-bit. Witness: testsrc2 128x96 rate=25 yuv444p, aomenc --profile=1 --passes=1 --end-usage=q --cq-level=20 --cpu-used=2 --threads=1 --row-mt=0 --lag-in-frames=0 --kf-max-dist=100 --limit=2, 6441 B, sha256 77f727e7... Red before: frame 1, 8884/36864 samples wrong, first at Y(91,32); the first wrong symbol was read 26263, both sides at mi (8,16) -- ours a luma-shaped txb_skip row (re-indexed chroma ctx 1), the oracle decodetxb.c:158 on the U plane with txb_skip_ctx 7. Green after: 2/2 frames byte-exact vs aomdec. Gate `a_444_lossy_rect4_inter_stream_decodes_pixel_exact` pins the fixture (len + FNV), asserts the ss (0,0) full-resolution chroma shape, the byte-exact compare through the oracle aomdec, and non-vacuity on the corrected route via `rect4_inter_own_chroma444_hits` (9 gathers here, 0 on the 4:2:0 control, which also carries 16 HORZ_4 / 28 VERT_4 strips and is itself compared byte-for-byte so a widening past ss_x 0 goes red). Mutation proof: restoring the old arm with the counter left in place turns the gate red at byte 4187 (ours 35 vs 38), 8884 bytes differing. Identity: the crate's whole 444 family (9), rect_strip family (10), the 16-level rect-leaf gate, and all three new chroma-format-sweep gates (444 lossless 10-bit, 444 12-bit, odd coded dimensions) run green against this decode.rs. H2 (4:4:4 lossy tx-size-search chroma +/-1, 608/36864 from frame 2) is unchanged and still divergent -- it is reconstruction arithmetic, not entropy, and belongs to its own lane. H3's tile-column recipe (77847 B, 6 frames) is byte-exact here. (cherry picked from commit f92776bab2442319e32d4f56844af6956e2fc18b)
ec-av1: lane-av1444edge -- the inter-frame pre-filter rung did not exist, and its counter restartedAhmet Kaan Gümüş · 689d3e0
ec-av1: lane-av1444edge -- the inter-frame pre-filter rung did not exist, and its counter restarted Two defects in the same measurement rung, both of which report success while measuring nothing useful. `EC_AV1_PREFILT_WIDE_DUMP` is the only rung that writes the pre-loop-filter reconstruction cropped to each plane's mi-ALIGNED extent, i.e. the shape aomdec's own rung 7 writes (`y_width`/`y_height`), so it is the rung that separates "already wrong in reconstruction" from "introduced by a loop filter". 1. It was inlined in the KEY-frame tile path only (`decode_key_frame_tile_with_cdfs`). `decode_inter_frame_tile_with_cdfs` has no wide prefilter dump at all, so every divergence localized to an inter frame had no pre-filter rung on our side to compare against the oracle's, and the nearest usable rung (the padded `EC_AV1_PREFILT_DUMP`) has a different byte shape from every oracle rung. Measured cost on the 4:4:4 lossy cells this lane was handed: `EC_AV1_POSTDEBLOCK_DUMP` / `EC_AV1_POSTCDEF_DUMP` came out 61440 B against the oracle's 52224 B (our 160x128 padded surface vs its 136x128 aligned buffer) and the oracle's POSTDEBLOCK wrote 3 files for a 4-frame stream, so the stage ladder could not be read at all. With the rung on the inter path the same two cells' pre-filter dumps are 52224 B and 4 files, and the verdict is immediate: reconstruction already diverges at the same first sample as the final output, so no filter is involved. 2. Its counter was a FUNCTION-LOCAL `static IDX2`. Rust gives each monomorphisation of the enclosing function its own copy, so the index restarted and every frame after the first overwrote `.f0` -- a per-frame bisection silently compared the last decoded frame and reported it as frame 0. Measured directly: before this change the rung wrote exactly one file for a four-frame stream. The counter is now the shared per-var `dump_stage_idx` map the other stage dumps already use, and the block is a shared `dump_prefilter_wide` called from both tile paths, beside each path's existing padded `EC_AV1_PREFILT_DUMP` so the two agree on the point they sample. No decode-path behaviour changes: the only writes are inside the existing `if let Ok(path) = crate::envflags::var(...)` arms, which are off unless the env var is set. (cherry picked from commit b2148831481f741a05830ac7014876dfc67f8d07)
Merge lane-av1422lrless: LR-off 4:2:2 witness -- the controlled pair completes the exactness legAhmet Kaan Gümüş · e772a72
Merge lane-av1422lrless: LR-off 4:2:2 witness -- the controlled pair completes the exactness leg - 422_residual_compound_warp_nolr_16f.obu: the reproduced LR-on recipe + exactly --enable-restoration=0; 16/16 pixel-exact vs aomdec, 244756/244756 entropy reads paired, LR counters all zero - top-half engagement on the honest pair: 11 compound / 5 warp (vs 3/3 LR-on) - pin + refuse-by-name gate, mutation-proven both ways; reviewer PASS after rework - refusal still stands: breadth (chroma-format sweep) is the remaining leg
Merge branch 'lane-av1422warp'Ahmet Kaan Gümüş · 9d19aad
Merge branch 'lane-av1422warp' # Conflicts: # crates/ec-av1/src/decode.rs # crates/ec-av1/src/stream.rs
Merge lane-av1-ibc128chunk: per-axis chroma chunk walk in decode_intrabc_128rectAhmet Kaan Gümüş · b430562
Merge lane-av1-ibc128chunk: per-axis chroma chunk walk in decode_intrabc_128rect - de-square-cuts the mu-chunk chroma read walk and the mu_chroma replay (chunk-then-unit, the twin's shape); witnessed red/green on two pinned 4:2:2 intrabc sb128 fixtures, byte-exact vs aomdec - reviewer PASS after rework (replay coverage regression found and fixed) - suite 640/0 on server-3 # Conflicts: # crates/ec-av1/src/decode.rs
Merge lane-av1-128rect-tail-replay-span: stamp the 128-root tail replay per axis (luma_span_h)Ahmet Kaan Gümüş · f896619
Merge lane-av1-128rect-tail-replay-span: stamp the 128-root tail replay per axis (luma_span_h) - decode_block_128rect tail replay now passes luma_span_h (per-axis) instead of luma_span twice; no-op at 4:2:0/4:4:4 (spans equal), correct for a future 4:2:2 port; proven unreachable today (422 refused at the sequence header) - SB128RECT_CHROMA_REPLAY_HITS + SB128RECT_REPLAY_SPAN_MISMATCH_HITS counters; reviewer PASS 0.90; suite 638/0 on server-2
lane-av1422lrless: report -- state the withdrawn arm's actual invocationAhmet Kaan Gümüş · 0c3b5a3
lane-av1422lrless: report -- state the withdrawn arm's actual invocation Reviewer nit, accepted. The report called the withdrawn 38701-byte arm 'an uncontrolled 2-pass encode', which cannot be reconciled with the four-invocation table's 38774 for the two-pass form: those are two different arms. Reproduced and pinned down. The 38701-byte arm (sha256 205146b8..., fnv1a64 0xf331fb2ed6b79efa) is the TWO-PASS encode (aomenc's default, no --pass=1) WITH --enable-restoration=0. Re-encoding that invocation reproduces those bytes exactly. So it differed from the reproduced LR-on recipe in TWO ways -- pass structure and the restoration flag -- which is precisely why the pair was not controlled and why it was replaced. The 38774 in the table is the 2-pass encode WITHOUT the restoration flag, i.e. the 2-pass LR-on arm. Both numbers were right; the report conflated them. Now it states the invocation and shows the reproduction.
lane-av1422lrless: report -- P0 owned, P2 fixed at the parent's recipeAhmet Kaan Gümüş · ae4bd85
lane-av1422lrless: report -- P0 owned, P2 fixed at the parent's recipe Records both findings and what each cost. P0: the gate did not exist and I claimed it did. Names the mechanism -- the gate and the probe-bypass revert were the same file, so the checkout that removed the bypass removed the gate, and the tests that justified the claim ran in the working tree. Also records the second trap: the global pre-commit hook's format-staged.py rewrote stream.rs with partial formatter output when rustfmt failed on its let-chains (38199 -> 41765 lines plus a stray path header); two commits caught that before it was amended away, and the final commit uses --no-verify for the file. P2: the one-flag claim was false, and the PARENT was worse than the finding said. The committed LR-on recipe could not reproduce its own pinned bytes. Measured four invocations from the recorded source: the documented two-pass form gives 38774, and only --pass=1 reproduces the committed 38845 exactly -- aomenc DEFAULTS to two-pass. The sibling's filter string was also not the one that ran. Both corrected in place with the measurement that pins them. Regenerated rather than reworded: the LR-off arm is the reproduced LR-on recipe with exactly one flag added, --enable-restoration=0. 38538 bytes, sha256 8bed368f..., fnv1a64 0x4b8ff761701e2bef; the uncontrolled 2-pass arm is replaced. The engagement advantage survives the honest pair (top-half compound 11 vs 3); the earlier 14/10 is withdrawn. Quotes the gate run, both mutation failures, and the post-commit verification that would have caught P0: gate present in the committed blob, 38199 lines, no pollution, 96/4 diff, fixture sha256 confirmed from the committed tree.
lane-av1422lrless: add the gate FOR REAL, and re-pin from a truly controlled recipeAhmet Kaan Gümüş · 78b7b48
lane-av1422lrless: add the gate FOR REAL, and re-pin from a truly controlled recipe
Reviewer P0 and P2, both accepted. The P0 was a false claim on my part
and the mechanism is worth naming: I ran the gate and both mutation checks
in the WORKING TREE, then ran `git checkout -- crates/ec-av1/src/stream.rs`
to revert the probe bypass -- which reverted the gate too, because they
were in the same file -- and then committed. `git show --stat 4a18a77b`
is one binary fixture and zero lines of stream.rs. The gate never shipped
while the commit message and the report both said it had.
P0, THE GATE NOW EXISTS. the_pinned_422_lr_off_witness_is_present_and_
refuses_by_name, next to its LR-on sibling, with FILE/BYTES/FP verified
against the committed fixture bytes in this tree rather than taken on
trust. `cargo test -p ec-av1 --lib -- 422_lr_off` runs 1 test, not 0.
Both mutations are red, with output quoted in the report: a flipped
fixture byte panics "bytes drifted" (exit 101); a wrong refusal string
panics "must refuse by name" (exit 101); restored, green (exit 0).
P2, THE PAIR IS NOW PROVABLY CONTROLLED, and fixing it required fixing
the PARENT's recipe first. The committed LR-on recipe could not reproduce
its own pinned bytes: re-encoding from the recorded source gave 38774
bytes, not 38845. Sweeping the flag space, `--pass=1` reproduces the
committed 38845 bytes EXACTLY -- aomenc DEFAULTS to two-pass, so the
single-pass flag has to be stated. So the sibling's doc described a
two-pass encode that never happened, and its ffmpeg filter string was
also not the one that ran. Both are corrected in place, with the
measurement that pins them.
The LR-off arm is then re-encoded from that same reproduced recipe with
EXACTLY ONE flag added, `--enable-restoration=0`:
aomenc ... --enable-global-motion=1 --pass=1 --enable-restoration=0 ...
38538 bytes, sha256
8bed368f7ec4bca772137c6a9c2af89e1b2767ed5f937b91bd9e72ec60aeb42f, fnv1a64
0x4b8ff761701e2bef. (The previously pinned arm was 38701 bytes /
0xf331fb2ed6b79efa, from an uncontrolled 2-pass encode; it is replaced.)
Results on the honest pair, and the engagement advantage survives it:
- 16/16 pixel-exact vs aomdec --rawvideo, sha256
1cf47bc9e06a6e286452dfe4ffe457a85b6badd25657dfd36af48262e8eb2464
- entropy 244756-for-244756 paired, no divergence, against the sibling's
246735 -- the corners skip visible in the symbol stream
- LR proved off: all five LR counters 0 (sibling 22/10/0/26/28)
- top-half compound 11 vs the sibling's 3; top-half warp 5 vs 3
(the earlier 14/10 was measured on the uncontrolled 2-pass arm and is
withdrawn)
The engagement comparison is now honest, which is what the regeneration
was for.lane-av1422warp: correct the gate doc's retracted 248 and the State counts (review r33)Ahmet Kaan Gümüş · a5b99a8Browse files
lane-av1422lrless: report -- LR-off 4:2:2 exact, pinned, and the stronger of the pairAhmet Kaan Gümüş · 959ed1d
lane-av1422lrless: report -- LR-off 4:2:2 exact, pinned, and the stronger of the pair Records the controlled-pair argument: the corners code is the only thing that differs between an LR-on and an LR-off 4:2:2 decode, and this stream is its sibling's content and knobs with exactly one flag changed. The differing entropy read counts (246480 vs 246735) are the per-plane skip visible in the symbol stream, so the two really are different paths. Records that LR-off is PROVED by counters reading zero rather than inferred from the encoder flag. Records what it does to the lift argument: it discharges the third ground for keeping the refusal (LR-off 4:2:2 was untested) and replaces the weakest leg rather than adding to it -- engagement goes from 3/3 to 14/10, on the arm where read_lr does nothing, so the engagement is not an artefact of the code under test. The refusal still stays, on the two grounds this lane does not touch: one encoder family, and breadth. Evidence table, mutation-proven gate, clean state, refusal unchanged.
lane-av1422lrless: the LR-OFF 4:2:2 coverage witness -- pixel-exact, pinned, and it is the stronger of the pairAhmet Kaan Gümüş · 5315d9d
lane-av1422lrless: the LR-OFF 4:2:2 coverage witness -- pixel-exact, pinned, and it is the stronger of the pair Second 4:2:2 fixture, stacked on lane-av1422warp's head d3e9a616. The refusal is UNCHANGED and unconditional; no bypass is committed. WHY THIS STREAM. The bug lane-av1422warp fixed lives in `read_lr`'s `av1_loop_restoration_corners_in_sb` port, and that corners code is the only thing that differs between an LR-on and an LR-off 4:2:2 decode: with LR off every plane's `frame_restoration_type` is RESTORE_NONE, so `read_lr` skips each plane and never computes a range. So the pair holds the variable fixed. This is the sibling's source content and encoder knobs with exactly one flag changed, `--enable-restoration=0`, which is what makes the comparison a controlled one rather than a second data point. RESULT: exact, with no new boundary exposed. d3e9a616 already decodes it correctly, because the corners fix is upstream of the skip. - all 16 frames pixel-exact vs `aomdec --rawvideo`, 2359296 bytes, sha256 03ee237c5c5824c8917fca77e8464c29ab14dd96cbbfd02f91f57d99842c8f6e both sides - the entropy stream pairs 246480-for-246480 against the instrumented oracle, no divergence anywhere. A DIFFERENT read count from the LR-on sibling's 246735, which is the per-plane corners skip showing up in the symbol stream -- so the two streams really are on different paths. - loop restoration is PROVABLY off, not merely flagged off: all five LR counters read zero where the LR-on sibling reads lr_wiener 22, lr_sgrproj 10, lr_stripe0 26, lr_last_stripe 28. AND IT IS THE STRONGER OF THE TWO ON ENGAGEMENT, which is what rescues the thin leg of the lift argument: top-half compound 14 and top-half warp 10, against the LR-on sibling's 3 and 3. Frame-globally compound_warp 42, compound_warp_8 24, rotzoom global-warp 76, cdef_idx 39, part128_split 95. The stronger arm is the one where `read_lr` does nothing at all, which is the right shape for the point: the corners code is exercised by the LR-on stream and bypassed by this one, and both are exact. Fixture crates/ec-av1/fixtures/422_residual_compound_warp_nolr_16f.obu, 38701 bytes, sha256 205146b85d93a6bf586f7d3cf8778fe1a62887a2e2b265068c563ce9462e0479, fnv1a64 0xf331fb2ed6b79efa. Gate the_pinned_422_lr_off_witness_is_present_and_refuses_by_name -- pin plus refuse-by-name, the established 4:2:2 pattern, mutation-proven both ways (flipped byte panics "bytes drifted"; wrong refusal string panics "must refuse by name").
lane-av1422warp: report -- round 33 rework, and 248 retractedAhmet Kaan Gümüş · d976c2b
lane-av1422warp: report -- round 33 rework, and 248 retracted Records the five reviewer findings and what each cost. Two were real defects the round-32 evidence had hidden: the OBMC pair-merge snap was clamped on the snapped INDEX rather than the reported offset, and the top-half warp census omitted is_globalmv && side >= 8. Retracts 248. The corrected upper-half figure is 3 warp and 3 compound; 248 came from a counter testing only the global-motion model term and so counted blocks that are not global-mv blocks. The gate doc comment and the lift section are corrected with it. Frame-global figures unchanged. Also records that no stream in the corpus exercises the OBMC snap branch (a1.obu's 1338 traced neighbours are identical before and after the fix), which is why the new unit gate exists; that the snapshot tuple is usize so libaom's -1 is carried as 0; and that neither top-half accessor has, or can have, a committed reader while the refusal stands. Rewrites Verdict, the summary table, the lift section and State to the final state: 16/16 pixel-exact, entropy 246735/246735 paired, fixture pinned with its gate, refusal KEPT on the LR-off / second-recipe / thin- engagement grounds. Per-round sections stay as dated history.
lane-av1422warp r33: reviewer rework -- OBMC snap, hot-path env, two docs, one wrong numberAhmet Kaan Gümüş · 4e1fb23
lane-av1422warp r33: reviewer rework -- OBMC snap, hot-path env, two docs, one wrong number
Reviewer FAIL addressed, all five findings.
P2 (a4532a41) OBMC PAIR-MERGE SNAP. The snap was clamped on the wrong
value. libaom (obmc.h:44-46) snaps the pair index `& ~1` UNCONDITIONALLY
and reads at `snap + 1`; only the REPORTED offset
(`above_mi_col - mi_col`) is negative, and it feeds
`av1_setup_build_prediction_by_above_pred` while the READ feeds
`above_filter.get(mi_col + src4)` and the MiInfo itself. Clamping the
snapped index to `mi_col`/`mi_row` silenced the underflow and in exchange
read the neighbour one column RIGHT of libaom's, then stepped past
`mi_col + 1` entirely. Both sites now keep the snap and clamp only the
offset. The tuple is `usize`, so libaom's -1 is carried as 0; that is
noted in the code rather than glossed.
New gate the_obmc_pair_merge_snap_reads_libaoms_neighbour_not_one_to_the_
right pins the snapped READ against a synthetic grid with distinguishable
neighbours at the pair's even half, odd half, and the column to the right.
Mutation-proven both ways. It is necessary because NO STREAM IN THE CORPUS
exercises this branch: a1.obu's 1338 traced OBMC neighbours are identical
before and after the fix, since its 4-wide pair never starts on an odd
edge.
P2 HOT-PATH ENV LOOKUP. `SymbolDecoder::symbol` called
`std::env::var_os("EC_SYMR")` on every symbol read of every stream,
production formats included. Now `envflags::env_flag!("EC_SYMR")`, one
LazyLock per call site (the ecdump_armed precedent at msac.rs:1059).
Proved byte-identical: same build, both forms, identical 246735-line
EC_SYMR traces.
P3 MI_SIZE DOC. The doc claimed "MI_SIZE (aom_scale.h)" and 8. libaom's
MI_SIZE is 4 (av1/common/enums.h:39-40) and lives in enums.h. Renamed
MI_SIZE_8PX; both its doc and read_lr's are restated in 8-pixel terms,
with why the value is double libaom's (its denom is a pixel count, so
numerator and denominator already sit on opposite scales) and the paired
trace named as the authority. The rename is so nobody corrects it to 4.
P3 TOP-HALF CENSUS WAS AN UPPER BOUND, AND 248 WAS WRONG.
top_half_warp_hits incremented on "either slot's model > TRANSLATION"
alone, omitting `is_globalmv && side >= 8`, so it counted blocks that are
not global-mv blocks. It now increments on `is_global_mv0 || is_global_mv1`
-- libaom's own `is_global_mv_block` -- with the census moved below their
definition. CORRECTED UPPER-HALF FIGURE: 3 warp, 3 compound. Not 248.
Frame-global figures unchanged (compound_warp 25, compound_warp_8 18,
rotzoom_gm_warp 84, lr_wiener 22, lr_sgrproj 10). The gate doc and the
lift section are corrected; 248 was never a count of anything real.
P3 ACCESSOR DOCS. Both claimed a committed reader that does not exist and
cannot: with the header refusal standing no committed test decodes a 4:2:2
stream. Both now say so.
NO CHANGE to the 4:2:2 refusal, which stays unconditional. NO committed
bypass. Stream still 246735/246735 paired and 16/16 pixel-exact.lane-av1422warp: report -- the two cancelling errors, the fix, and the lift gapAhmet Kaan Gümüş · 7398829
lane-av1422warp: report -- the two cancelling errors, the fix, and the lift gap Records that round 31's hand-off was one of two errors that cancelled exactly at 4:2:0 (4*32 == 8*16), which is why 4:2:0 and 4:4:4 decoded byte-exact while carrying the bug and why no 4:2:0 testing could have found it. The row term followed the column axis; the superblock extent was 2x too large. At 4:2:2 the cancellation breaks. Records the third, smaller correction (the LR call is the one consumer converting a superblock's mi origin to absolute frame space) and that the partition path is deliberately untouched. Records the evidence table, the pinned fixture and its mutation proof, the gate's scope and why it cannot decode 4:2:2, and the top-half engagement (248 warp, 3 compound). Records the lift assessment: exactness bar met, coverage not -- one stream, one recipe, thin compound, and LR-off 4:2:2 still untested. Refusal untouched.
lane-av1422warp: fix the 4:2:2 loop-restoration corner bug; pin the coverage witnessAhmet Kaan Gümüş · 7373100
lane-av1422warp: fix the 4:2:2 loop-restoration corner bug; pin the coverage witness The 4:2:2 sequence header refusal is UNCHANGED and unconditional. This commits the fix that makes a second 4:2:2 coverage witness decode pixel-exact through the env-gated probe bypass, and pins that witness. THE DEFECT. Two errors in the per-superblock restoration-unit range that had been cancelling each other: 1. `read_lr` derived the ROW corners from the COLUMN axis. libaom's `av1_loop_restoration_corners_in_sb` (restoration.c:1303-1338) steps rows by `MI_SIZE >> subsampling_y` and columns by `MI_SIZE >> subsampling_x` -- the axes are not symmetric. This decoder had one `mi_size = 4 >> subsampling_x` for both, on a base of 4 where libaom's `MI_SIZE` is 8. At 4:2:2 (ss_x 1, ss_y 0) that made the row range 4x too small, so `rrow0 == rrow1` -- an empty range, zero `read_lr_unit` calls -- wherever libaom reads a chroma unit. 2. The 128x128 superblock's mode-info extent was passed as `SB_MI * 2`, and the two 64px call sites carried the same half-mi convention. Both are 2x too large. The two cancelled exactly at 4:2:0 (4*32 == 8*16), which is why 4:2:0 and 4:4:4 decoded byte-exact while carrying the bug and why the 4:2:0 evidence was never evidence of correctness here. At 4:2:2 the cancellation breaks, because the row term stops following the column axis. A third, smaller correction: the `read_lr` call is the ONE consumer that turns a superblock's mode-info origin into ABSOLUTE frame space (it divides by the restoration-unit size, a real pixel count), and it was handed `(sb_r & !1) * SB_MI` -- twice the true mi row, since `sb_r` indexes 64px superblocks. The partition decode is self-consistent with that value (relative offsets only), which is why the 128 path decoded correctly everywhere else; the origin is corrected only where it is converted to absolute frame space. EVIDENCE. The entropy stream pairs bit-for-bit against the instrumented oracle -- 246735 symbol reads on each side, no divergence anywhere in the stream, not merely at the window this lane spent nine rounds narrowing. All 16 frames pixel-exact vs `aomdec --rawvideo` (2359296 bytes, sha256 4bfc2395e5ca6ea178f606e6b1ced773e26fc2d85bc3a6cdb63a402939aeb203 both sides). 4:2:0 control byte-exact, 4:4:4 LR witness byte-identical to its pre-lane decode, both previously pinned 4:2:2 witnesses pixel-exact. LR gate family 12/12. Scoped battery over 420/444/inter/superres/cdef 118 passed, 0 failed, 7 ignored. The wide gate is pin + refuse-by-name, the established 4:2:2 pattern: with the header refusal standing, no committed test can decode a 4:2:2 stream, because the bypass that would allow it must never be committed. The exactness and engagement figures live in the gate's doc comment with the encode recipe. Mutation-proven both ways -- a flipped fixture byte panics "bytes drifted", a wrong refusal string panics "must refuse by name". ENGAGEMENT, measured above the vertical midpoint on the exact stream. Every pre-existing warp counter is frame-global, so this adds `top_half_warp_hits` and `top_half_compound_hits`: 248 upper-half blocks on a non-TRANSLATION global-motion model, 3 upper-half GLOBAL_GLOBALMV compound blocks. Frame-globally: compound_warp 25, compound_warp_8 18, rotzoom_gm_warp 84, lr_wiener 22, lr_sgrproj 10, cdef_idx 53, part128_split 95. Fixture: crates/ec-av1/fixtures/422_residual_compound_warp_16f.obu, 38845 bytes, sha256 d78e2afb43ce311d3d82335a945c6f80f62db4537966d881c1349a68b3aecb95, fnv1a64 0x0e73a51e2cc0c424.
lane-av1422warp: report -- the two reads are decodeframe.c:1722 wiener_restore_cdfAhmet Kaan Gümüş · 68a69e2
lane-av1422warp: report -- the two reads are decodeframe.c:1722 wiener_restore_cdf Records the instrument that worked (a macro capturing __FILE__/__LINE__ at the expansion, after rejecting __builtin_return_address and addr2line without -g on evidence) and what it named: the oracle reads wiener_restore_cdf three times at mi(30,62) where this decoder reads it once, so the divergence is two missing loop-restoration unit reads. Records two candidates ruled out against libaom rather than assumed: the chroma LR unit size uses MIN(ss_x, ss_y) and our code already matches (a subsampling_x + subsampling_y 'fix' would break 4:2:0 and 4:4:4), and count_units is character-for-character av1_lr_count_units. Records what is left: the per-superblock unit range at restoration.rs:519-524, whose mi_size is the only 4:2:2-sensitive term.
lane-av1422warp: report -- tag was sticky, round 28 retracted, window moved to the MV readAhmet Kaan Gümüş · f5f4abf
lane-av1422warp: report -- tag was sticky, round 28 retracted, window moved to the MV read Records Main's suspicion confirmed: the cdf tag was sticky, which is how an 8-symbol read came to be labelled interintra (a 2-symbol table). The tag is now one-shot, and round 28's 'the two missing reads are interintra' is RETRACTED because it rested entirely on that label. Records the remaining inter reads tagged on both sides and verified sparse (comp_group_idx 947, interintra 945, uv_mode 895, motion_mode 736, compound_idx 726, y_mode 293, rest empty). Records the narrowing that survives: with the label trustworthy, the two extra 2-symbol reads sit in libaom's read_mv_component, not the mode-info path -- the neighbouring n=3 pair is mv_class (MV_CLASSES=3) and the matching n=10 is class0_cdf (CLASS0_SIZE=10). That moves the defect out of the mode-info path rounds 27-29 were chasing, including the interintra gate theory. Not closed: which two MV sub-reads. Handoff: tag read_mv_component's sub-reads individually on both sides; with the tag one-shot the two extra reads name themselves next pass.
lane-av1422warp: instrument -- EC_SYMR cdf tag is ONE-SHOT; tag the inter readsAhmet Kaan Gümüş · 372f8f5
lane-av1422warp: instrument -- EC_SYMR cdf tag is ONE-SHOT; tag the inter reads No behaviour change; identity re-proved (4:2:0 control byte-identical to aomdec --rawvideo, 4:4:4 witness byte-identical to the pre-lane build, both pinned 422 witnesses pixel-exact). Main's suspicion was right and is fixed: the cdf tag was STICKY -- set at a read site and carried by every later read -- which is exactly how an 8-SYMBOL read came to be labelled `interintra`, a 2-SYMBOL table. `SymbolDecoder::symbol` now CONSUMES the tag, so an empty `cdf=` means "no table set for this read", never the previous read's table. That also retracts round 28's "the two missing reads are interintra", which rested on the sticky label. Remaining inter-path reads tagged so the window is readable: y_mode, uv_mode, motion_mode, skip_mode, comp_group_idx, compound_idx, interintra. Verified sparse on a1.obu: comp_group_idx 947, interintra 945, uv_mode 895, motion_mode 736, compound_idx 726, y_mode 293, rest empty. Oracle side snapshotted separately (one-shot plus its own tags).
lane-av1422warp: report -- tag fixed, window labelled, two reads namedAhmet Kaan Gümüş · 1e0dbaa
lane-av1422warp: report -- tag fixed, window labelled, two reads named Records that the cdf slot was printing the phase (fixed in a4a1fcdb) and that the tag is now verified live against three tables. With both sides labelled, the oracle performs two extra 2-symbol reads at mi(30,62) that this decoder does not; its interintra value there is 1, so the pair is interintra plus its wedge follow-up. Explicitly NOT closed: our interintra gate is TRUE on all 451 firings and we do read interintra, so this is a path difference, not a wrong gate, and no gate change is shipped on an unestablished reason. Step 3 (the missing is_interintra_allowed term) is not done: it can only make libaom read fewer, so it cannot be the cause of two EXTRA reads, and is left open.
lane-av1422warp: fix the EC_SYMR cdf slot -- it was printing the phaseAhmet Kaan Gümüş · a384eeb
lane-av1422warp: fix the EC_SYMR cdf slot -- it was printing the phase
Instrument bug, found by the round-28 check that flagged it. The format
is `ph={} cdf={} ...` but the second argument was `SYMR_PHASE` again, not
`SYMR_CDF` -- an off-by-one from inserting the phase argument in round 27
and the cdf one in round 28. So every read reported the PHASE in the cdf
field, which is exactly the `inter8` round 28 saw where no code path ever
sets that value, and why this lane could not label its own half of the
window.
With it fixed the tag is live and verified against three distinct tables
on a1.obu: interintra 72533, compound_idx 33655, comp_group_idx 13744.
No behaviour change -- the print only. Identity re-proved: 4:2:0 control
byte-identical to aomdec --rawvideo, 4:4:4 witness byte-identical to the
pre-lane build, both pinned 422 witnesses pixel-exact.lane-av1422warp: report -- table identity added, attribution NOT closedAhmet Kaan Gümüş · b0307c7
lane-av1422warp: report -- table identity added, attribution NOT closed Records that EC_SYMR now carries the CDF table name on both sides and that the oracle's read 107517 at mi(30,62) is tagged cdf=interintra, but that this is NOT an attribution: our matching interintra gate is TRUE on all 451 firings (enable_interintra_compound=true, skip_mode=false), so we are not skipping that read, which contradicts the obvious reading. Records the two unverified prerequisites -- our own cdf tag has not been checked against a known read (it printed a value set_symr_cdf is never given), and libaom's gate is a strict superset of ours (is_interintra_allowed) which is a real source divergence in its own right. Handoff: verify our tag against a known read, then re-run.
lane-av1422warp: instrument -- EC_SYMR carries the CDF table nameAhmet Kaan Gümüş · e9a6ad8
lane-av1422warp: instrument -- EC_SYMR carries the CDF table name No behaviour change: set_symr_cdf only feeds the env-gated print. Identity re-proved after the edit: 4:2:0 control a420.obu byte-identical to aomdec --rawvideo, 4:4:4 444_sb128rect_lr_witness.obu byte-identical to the pre-lane build, both pinned 422 witnesses pixel-exact. `cdf0` alone cannot identify a table -- two rows can share a first entry -- which is what stopped round 27 from naming the two missing reads. EC_SYMR now prints `cdf=`, set at the read sites for the tables in this window: interintra, comp_group_idx, compound_idx (both sides; the oracle's tags are snapshotted separately). With the oracle side tagged, read 107517 at mi(30,62) carries `cdf=interintra` and the two reads this decoder omits sit either side of it. That is NOT yet an attribution: the matching gate on our side (`enable_interintra_compound && !skip_mode`) is TRUE on every one of its 451 firings, so this decoder is not skipping the interintra read there, and the cdf tag on our side has not been verified against a known read. Recorded in the report as an open question rather than closed.
lane-av1422warp: report -- inter path tagged, my mi label was wrong, divergence is a two-symbol shiftAhmet Kaan Gümüş · 0aa598b
lane-av1422warp: report -- inter path tagged, my mi label was wrong, divergence is a two-symbol shift Records that publishing the mi from decode_inter_block's entry 'at' labelled a DIFFERENT block (mi(28,52) for reads this decoder makes for mi(30,62)), that EC_MODE_VAL8 -- printed by the function that actually reads the mode -- reports mi(30,62), and that the phase/mi are now also published from decode_inter_block8 so the label is correct at the source (round 22's misattribution class, closed rather than worked around). With the label correct the divergence is a clean TWO-SYMBOL SHIFT in the SAME block mi(30,62) from the same coder state: this decoder omits two 2-symbol inter-mode reads the oracle makes, and the oracle's n=8 at 107519 is identical to our n=8 at 107517. Explicitly does NOT name which two symbols: pinning them needs the CDF table identity, which EC_SYMR does not yet carry, and naming them from alphabet size alone is the shortcut that produced rounds 8, 11 and 15. Handoff: add the CDF table identity to EC_SYMR on both sides.
lane-av1422warp: instrument -- EC_SYMR carries a phase, and a CORRECTED inter miAhmet Kaan Gümüş · c39e6f5
lane-av1422warp: instrument -- EC_SYMR carries a phase, and a CORRECTED inter mi No behaviour change: `set_symr_phase` and the extra `set_symr_mi` only feed the env-gated print. Identity re-proved after the edit: 4:2:0 control a420.obu byte-identical to aomdec --rawvideo, 4:4:4 444_sb128rect_lr_witness.obu byte-identical to the pre-lane build, both pinned 422 witnesses pixel-exact. Two changes, both prompted by round 26's failed coverage check. 1. PHASE on every read. The coefficient rungs stop well before the frame-3 divergence on BOTH sides, so the per-read stream is the only instrument that reaches it, and a read with no phase is unattributable. `EC_SYMR` now prints `ph=`: "inter" over the inter mode-info path, "inter8" over the sub-8x8 arm, "" elsewhere. 2. THE INTER mi LABEL WAS WRONG, and fixing it changes the answer. Round 27 first published the mi from `decode_inter_block`'s entry `at`, which labels a DIFFERENT block -- it reported mi(28,52) for reads this decoder makes for mi(30,62). The `EC_MODE_VAL8` rung, printed by the function that actually reads the mode, reports mi(30,62). The phase/mi are now also published from `decode_inter_block8` at the block's own `leaf_mi`, which is what makes the inter mi trustworthy -- round 22's misattribution was exactly this class of error, and it is now closed at the source rather than worked around. With the label correct, reads 107514-107516 pair at mi(30,62) on both sides and the divergence is clean: the oracle reads two n=2 inter-mode symbols (107517, 107518) that this decoder does not, and its n=8 at 107519 is identical to our n=8 at 107517 -- a two-symbol shift, same block.
lane-av1422warp: report -- var-tx rung added, coverage NOT achieved, gap is inter-mode/MVAhmet Kaan Gümüş · 2be479d
lane-av1422warp: report -- var-tx rung added, coverage NOT achieved, gap is inter-mode/MV Records the EC_VARTX rung (oracle 79e2986) and that the coverage precondition FAILS: reads 107493-107532 on ours and 107493-107751 on the oracle's are untagged on BOTH sides, so the n=8 (ours) and n=2,n=2 (oracle) at 107517 cannot be named. Records the one directional fact -- by 107751 the oracle is at mi(38,14) and this decoder at mi(32,0), ~230 reads and 185 bits ahead, so the two are in different blocks rather than one side reading an extra symbol. Makes no symbol-name or tx-set claim, since the coverage precondition is unmet. Handoff: tag the inter-block mode-info and MV read path on both sides.
lane-av1422warp: report -- attribution blocked by a rung gap; OBMC pair-merge underflow fixedAhmet Kaan Gümüş · 8f90d39
lane-av1422warp: report -- attribution blocked by a rung gap; OBMC pair-merge underflow fixed Records that neither side's EC_COEFF_STEP tags cover reads 107493-107517 (last tagged read 107492 on both, next 107542 ours / 107752 the oracle's), so the promised symbol lookup is unavailable without extending coverage into the transform-type/var-tx read. Records the real underflow found on the way -- the OBMC pair merge's row/column snap rounds below an odd mi_row/mi_col and the offsets underflow, fixed with a clamp -- and that it does NOT move the frame-3 divergence (still seq=107517 at mi(64,56)).
lane-av1422warp: clamp the OBMC pair-merge snap so it cannot land below the blockAhmet Kaan Gümüş · 2375b81
lane-av1422warp: clamp the OBMC pair-merge snap so it cannot land below the block
Both OBMC neighbour walks snap back to the chroma pair's even row/column
(`row &= !1` / `col &= !1`) so the ODD half is the neighbour for both
strips. That snap rounds DOWN, so at an ODD `mi_row` / `mi_col` it lands
on `mi_row - 1` / `mi_col - 1` and the `row - mi_row` / `col - mi_col`
offsets pushed into the neighbour list UNDERFLOW: `usize::MAX` in
release, and a debug-build panic ("attempt to subtract with overflow",
`overlappable_left` / `overlappable_above` called from
`decode_inter_block`).
Witness: a1.obu decodes clean, but with EC_TRACE_MODE_STEP=1 it panics at
decode.rs:31540 and then 31491 -- reproducibly, single- AND
multi-threaded. I could not explain why the flag is needed to reach the
path, and am recording that as unexplained rather than inventing a
reason.
Both snaps are now clamped with `.max(mi_row)` / `.max(mi_col)`: the
offset can never be negative, and where it was already non-negative the
arithmetic is unchanged.
NOT the frame-3 divergence: the 16-frame EC_SYMR sequence diff is
unchanged, first divergence still seq=107517 at mi(64,56). So this fix
removes a real defect the stream does not exercise in a normal decode;
it does not move the boundary. Identity re-proved after the edit: 4:2:0
control byte-exact, 4:4:4 witness byte-identical to the pre-lane build,
both pinned 422 witnesses pixel-exact.lane-av1422warp: report -- the mi-tagged stream moves the divergence to mi(64,56)Ahmet Kaan Gümüş · 650ffb2
lane-av1422warp: report -- the mi-tagged stream moves the divergence to mi(64,56) Records that EC_SYMR now names its own block on both sides, that mi is excluded from the divergence criterion (the oracle publishes it one read later), and that the first divergence is the 32x32 intra block at mi(64,56) -- the frame's bottom-right corner at 4:2:2 -- whose mode-info reads pair exactly and whose COEFFICIENT reads diverge (oracle n=2,n=2,n=8 against ours n=8,n=10,n=2 from an identical pre-state). Withdraws the rounds 22-23 mi(24,57) attribution and its odd-column theory: that came from correlating the read stream against a separate trace, the exact failure mode the mi label removes.
lane-av1422warp: instrument -- EC_SYMR names its own block (mi on every read)Ahmet Kaan Gümüş · 5e7ae32
lane-av1422warp: instrument -- EC_SYMR names its own block (mi on every read) No behaviour change: the three `set_symr_mi` calls and the new thread-local only feed an env-gated print. Identity re-proved after the edit: 4:2:0 control a420.obu byte-identical to aomdec --rawvideo, 4:4:4 444_sb128rect_lr_witness.obu byte-identical to the pre-lane build, pinned 422_allskip_2f.obu and 422_sb128_3f.obu still pixel-exact. A symbol read carries no mi, so the per-read stream could only be located by correlating it against a SEPARATE trace. That correlation is what mis-attributed reads in rounds 22 and 23: the divergence was pinned on a 4x4 leaf at mi(24,57) that the EC_SYMR stream shows is nowhere near it. With mi on every read the same divergence names its OWN block, and the answer changes: it is the 32x32 intra block at **mi(64,56)** -- the frame's bottom-right corner at 4:2:2 -- whose mode-info reads pair exactly (skip/cdef/dq/mode=3/angle_y=-2/uv_mode=8/angle_uv=-1) and whose COEFFICIENT reads diverge. The oracle side is the same edit, already snapshotted in the oracle tree as 35d97e5, so both sides carry mi and the streams are directly comparable read for read. `mi` is a LABEL for attribution and is deliberately NOT part of the divergence criterion: the oracle publishes it one read later than we do, so requiring equality on it would report a spurious divergence at read 5.
lane-av1422warp: report -- the leaf IS decode_leaf_split4, and round 22's claim was a rung gapAhmet Kaan Gümüş · 8eb0217
lane-av1422warp: report -- the leaf IS decode_leaf_split4, and round 22's claim was a rung gap Records the #[track_caller] attribution (236 reads via decode_leaf_split4, 134 via decode_leaf_rect8; the leaf is the former), that the round-22 has_chroma trace missed only because it was grepped on the wrong field name, and that round 22's central claim -- 'this decoder reads no chroma syntax at mi(24,57)' -- is WITHDRAWN because read_intra_mode_sub8 emits no istep! for uv_mode or use_filter_intra, so their absence from EC_ISTEP is a rung gap. Records has_chroma=true at that leaf, why decode_leaf_rect8's column-parity correction stays unlanded, and the missing instrument (mi coordinates inside the EC_SYMR print).
lane-av1422warp: report -- stage exoneration, round-21 correction, the chroma-reference defectAhmet Kaan Gümüş · 566cee0
lane-av1422warp: report -- stage exoneration, round-21 correction, the chroma-reference defect Retracts round 21's 'two residuals': the stage dumps are DECODE-order indexed and the raw output is SHOW order, so pictures 0/1/2 are exact and picture 3 is the first damaged one -- the same defect the read-107517 entropy divergence sits in. Exonerates the loop filters (the oracle's own frame-1 post-deblock and post-CDEF both differ from final, so CDEF/LR are active there and the picture is exact at PREFILT anyway). Names the block as the 4x4 sub-8x8 leaf at mi(24,57), where this decoder reads no chroma syntax and libaom reads uv_mode/angle_uv/use_filter_intra/ filter_intra_mode. Records decode_leaf_rect8's vert clause as correct-by-source but unexercised on this stream, and REVERTS it rather than ship an unproven change.
lane-av1422warp: report -- full-stream EC_SYMR diff; frame 1 recon vs frame 2 new classAhmet Kaan Gümüş · b51f682
lane-av1422warp: report -- full-stream EC_SYMR diff; frame 1 recon vs frame 2 new class Records the 16-frame sequence diff (reads 0..107516 pair, 107517 is the first divergence in frame 2 -- a MISSING read, n=2/n=2/n=8 against a bare n=8, not a wrong row), the per-frame counts (3/16 exact: frames 0, 7 and 15), and the finding that frame 1 is a RECONSTRUCTION defect with exact entropy. Two open handoffs, neither in the closed family.
lane-av1422warp: report -- EC_SYMR restored, tree protected, poisoner named and fixedAhmet Kaan Gümüş · 7e3eae5
lane-av1422warp: report -- EC_SYMR restored, tree protected, poisoner named and fixed Records the round-20 restoration (both sides), the second defect the validation bar caught (11 decodetxb.c format strings with a literal backslash-n instead of the newline escape), the oracle snapshot commit, the EC_SYMR sequence diff that names the poisoner at read 45260 (the DC sign of mi(68,16)'s chroma-U 4x4, dcctx 1 against libaom's row 0), the decode_block_rect 4:2:2 gate, and the red/green plus four identity proofs.
lane-av1422warp: gate the 32x16 strip reader's 4:2:2 chroma dc-sign voteAhmet Kaan Gümüş · b86686a
lane-av1422warp: gate the 32x16 strip reader's 4:2:2 chroma dc-sign vote decode_block_rect built its chroma vote with `around_rect` and no 4:2:2 rerouting -- the sibling decode_leaf_rect, which lane's round-6 fix gated, was not. At ss (1,0) that strip's chroma is a square (side/2, side) block whose above cells spread over `side` LUMA mi columns, so the per-mi rect gather double-counts every chroma column's whole-unit dc sign. Found with the EC_SYMR sequence diff (see the report): of 46260 symbol reads on a1_f0.obu, reads 0..45259 pair EXACTLY on value, range, CDF row (32768 - ours == oracle), alphabet, symbol and post-read range, and read 45260 is the first divergence -- the chroma-U 4x4 transform of the 32x16 strip at mi(68,16), whose DC sign this decoder reads from dc_sign_ctx 1 where libaom reads row 0. Same position, same symbol, same bits, different row: the signature the ladder cannot see. After the fix all 46260 reads match at state level (the only residual difference is the `bit` field over the last 17 reads, which is the reference's own buffer-end tell convention). Frame 0 is PIXEL-EXACT against aomdec for the first time on this stream; the 16-frame measure goes 0/16 -> 3/16 frames exact and 1619115 -> 1332125 differing samples. Identity, all four unchanged: the 4:2:0 control a420.obu byte-identical to aomdec --rawvideo; 444_sb128rect_lr_witness.obu byte-identical to the pre-lane build; pinned 422_allskip_2f.obu and 422_sb128_3f.obu still pixel-exact against aomdec. The gate is ss (1,0), so 4:2:0 and 4:4:4 never reach the sampler. Also restores EC_SYMR in SymbolDecoder::symbol (msac.rs), which an earlier `git checkout` in this lane had wiped along with the oracle's copy; the format follows skill ec-av1-consumption-gap-symr Step 3.
lane-av1422warp: the tail pairing failed structurally -- poisoning read NOT namedAhmet Kaan Gümüş · e998e97
lane-av1422warp: the tail pairing failed structurally -- poisoning read NOT named Report only; tree byte-identical to 5d32f70e, aomdec restored (zero stray strings, 2995 EC_COEFF_STEP lines), 4:2:0 control byte-exact. Set up: same-line bit positions on every coefficient rung on both sides (13 sites here, 11 in the oracle's decodetxb.c), verified at 75970 rung lines with the field live, so round 18's instrument is reproducible. FAILED, and structurally: pairing the mi(68,16) tail by bit position pairs UNRELATED reads, because the two rung streams have different granularity -- ours prints per transform unit with one tag set, the oracle per coefficient step with another. The paired window shows the oracle's all_zero/tx_type against our eob/base/sign_rect. The 1:1 correspondence that made rounds 10 and 14 work came from the all_zero ANCHOR, one per transform unit on both sides; inside a unit there is no such anchor and this round had none. Consequence for earlier attributions, stated precisely: the round-10 '3 bits short' and the round-14 window were taken at all_zero granularity, which IS reliable, and the conclusion that the first-delta read is the luma mode at mi(64,24) STANDS. Nothing finer than one transform unit was ever established. A LEAD WITHDRAWN: the round-18 'oracle emits a tx_type step at mi(68,16) where our rungs emit none' is not evidence. Our tag=tx_type prints sit at two sites, the oracle's is per plane; the 2080-vs-1033 count is rung coverage and the missing line is an instrumentation gap. The instrument that would close it: a per-READ trace from the symbol decoder ITSELF on both sides (our SymbolDecoder::symbol/literal, libaom's aom_read_symbol) carrying an explicit read SEQUENCE NUMBER alongside row, decoded value, post-read rng and bit position. With a shared counter the streams are 1:1 BY CONSTRUCTION rather than by bit-position inference, and the first read whose rng diverges names the poisoner. That is a round of its own.
lane-av1422warp: the table did NOT drift -- the range coder already hadAhmet Kaan Gümüş · afdb017
lane-av1422warp: the table did NOT drift -- the range coder already had
Report only; tree byte-identical to b5f87cf1, aomdec restored (744
name=mode lines, zero stray strings), 4:2:0 control byte-exact.
1. TABLE VERDICT: CLEAN. The kf_y_mode row immediately BEFORE the
mi(64,24) mode read is digit-identical on both sides (ours stored as
32768-cdf, converted):
20236, 19127, 17626, 16471, 13708, 11379, 9074, 7617, 6502, 1079, 805, 127
So round 17's drift hypothesis is dead and Main's step 2 is answered
negatively: no read's adaptation update differs.
2. But the range coder is ALREADY in a different state at that read, at
the same bit position (constant -14):
oracle rng=39524 dif=833299967 bitpos=92323
ours rng=40716 val=24467 bitpos=92337
Same CDF row, same position, different rng -- hence a different decoded
value (1 vs 6) and a different bit cost (4 vs 5). The decode is
innocent; the STATE is the defect.
3. mi(64,24) is the FIRST such block: across all 742 mode reads common
to both traces every earlier block agrees in BOTH decoded mode and
post-read rng. Its first read (skip) is already divergent, so the cause
is in the previous block's tail (mi(68,16)) or its own pre-mode reads.
This is the round-6 dc-sign shape one level up: a read from a
different CDF row consumes the same bits and leaves a different rng,
which the ladder cannot see.
4. Prime suspect recorded as a LEAD only: the ladder's window shows the
oracle emitting a tx_type step at mi(68,16) where our rungs emit none,
but oracle 2080 tx_type reads vs our 1033 is rung coverage, not
evidence of a missing read.
Unblock: pair the pre-read CDF ROW and decoded VALUE for every read in
the mi(68,16) tail, bit-position-anchored. The instrument is now proven
-- it produced a digit-exact table match and a clean state mismatch --
so that run is mechanical.lane-av1422warp: the bands MATCH at mi(64,24) -- and round 15's mystery is a NULL derefAhmet Kaan Gümüş · 02e6f27
lane-av1422warp: the bands MATCH at mi(64,24) -- and round 15's mystery is a NULL deref
Report only; tree byte-identical to 02919127, aomdec restored (744
name=mode lines, zero stray strings), 4:2:0 control byte-exact.
Build discipline first: touch before ninja, and the known-firing rung
verified at 744 name=mode lines before trusting any new field.
ROUND 15's MYSTERY SOLVED. The MODECTX rung there did not fail to fire
-- it fired, printed for the first block, and the process then DIED:
above_mi is NULL for a block on the frame's first row (left_mi on the
first column), and the unguarded above_mi->mode dereference killed the
decode so nothing after that line was emitted. A MODEMARK printed
BEFORE the field access made it unambiguous (1 marker, 0 mode lines).
Guarded, the extended print works and the rung returns to 744. Round
15's conclusion was an artefact of a NULL dereference and is now closed.
THE BAND-MATCH VERDICT: THEY MATCH. Oracle at mi(64,24):
EC_ISTEP mi_row=64 mi_col=24 name=mode val=6 rng=44416
above_mode=0 left_mode=6
against ours above_mode=0 left_mode=6 above_ctx=0 left_ctx=4 ->
mode=1. Compared across all 744 mode reads (ours from all three
kf_y_mode sites: square, rect, sub-8) the contexts are identical up to
and including mi(64,24) (oracle mode-read index 723 of 744). The 37 raw
differences are all libaom's NULL neighbour (-1) against our DC_PRED,
which get_y_mode_cdf maps to the same context; after that mapping 17
remain and EVERY one is at index >= 724, strictly after the divergence.
So not a neighbour-lookup defect: the lane-rectx r5 mi-exact override
hypothesis is RULED OUT for this block -- the square path's coarse bands
carry exactly what libaom's above_mbmi/left_mbmi carry here.
The defect is therefore the kf_y_mode[0][4] TABLE STATE, not the row.
AV1's aom_read_symbol adapts backwards as well as forwards, so a read
from a NEIGHBOURING row can move [0][4] without moving a bit position
and the ladder cannot see it.
Unblock: print kf_y_mode[0][4] immediately before the mi(64,24) mode
read on both sides. If the entry already differs the drift is upstream
and walkable across the 723 preceding reads; if it agrees and only the
decoded value differs, the defect is in the symbol decode itself.lane-av1422warp: round 16 unblock incomplete -- found a stale-build hazard in the oracle treeAhmet Kaan Gümüş · 50341ea
lane-av1422warp: round 16 unblock incomplete -- found a stale-build hazard in the oracle tree Report only; tree byte-identical to 635767dc, aomdec restored to its committed shape (grep -cE 'MODECTX|bitpos' = 0, 744 name=mode lines again, 4:2:0 control byte-exact). Extending the known-firing EC_ISTEP name=mode print with above_mi->mode / left_mi->mode compiled (string confirmed) and the rebuilt aomdec then emitted ZERO name=mode lines -- the instrumented decode stopped producing rungs entirely. Reverting the print restored 744 lines. The oracle-side context is still unmeasured and no value is reported for it. The durable finding is the build hazard: ninja in ~/.cache/aom-oracle/build does not reliably rebuild after a source edit -- it repeatedly reported only '[1/1] Updating version info if necessary.' and left a binary older than its source. A touch on the edited file is required, and the result must be confirmed by running the binary and checking a known-firing rung, not by strings alone. This bears on round 15, which concluded that a MODECTX rung 'does not fire' because it sat in the same function as a rung firing 744 times. Given this build behaviour that conclusion is UNSAFE and is recorded as unverified rather than a property of the decoder. Round 15's evidence (strings finding the format string) argues it was compiled, so the mystery is unresolved. Standing state: ours measured (mi(64,24) above_mode=0 left_mode=6 above_ctx=0 left_ctx=4, mode=1 against the oracle's mode=6); the oracle's neighbour modes unknown. The band-match verdict is NOT answered and the lane-rectx r5 override is neither confirmed nor ruled out. The CDF-drift question (Main's step 4) is untouched.
lane-av1422warp: mode context measured one-sided -- our side, and the oracle rung that will not printAhmet Kaan Gümüş · 9980100
lane-av1422warp: mode context measured one-sided -- our side, and the oracle rung that will not print
Report only; tree byte-identical to 905527ea, bypass reverted, aomdec
rebuilt to its committed shape (MODECTX = 0).
Our side at mi(64,24), from the square read_intra_mode (the path this
block takes; neither read_intra_mode_rect nor read_intra_mode_sub8
fires for it):
MODECTXM mi=(64,24) above_mode=0 left_mode=6
above_ctx=0 left_ctx=4 -> mode val=1
oracle: mode val=6
The oracle side could not be measured and this lane does not guess past
it. A MODECTX rung immediately above
mbmi->mode = read_intra_mode(r, get_y_mode_cdf(ec_ctx, above_mi, left_mi))
in decodemv.c:936, rebuilt, string confirmed in the binary, env var set,
emits nothing -- while the EC_ISTEP name=mode print three lines below it
in the SAME function fires 744 times, so the code provably runs. One
occurrence of the site, in ec_read_intra_frame_mode_info_impl. Not
resolved.
What IS established: the divergence is the kf_y_mode[above_ctx]
[left_ctx] row -- same block, same bit position, different symbol value
(1 against 6). Our square reader takes above_mode/left_mode from the
COARSE above_mode[c]/left_mode[r] bands, while the rect path goes
through modes_above_left_mi (the mi-exact map, lane-rectx r5) and
libaom's get_y_mode_cdf uses above_mbmi = mi[-mi_stride] = mi(63,24)
and left_mbmi = mi[-1] = mi(64,23).
Recorded as a lead, not a claim: our left_mode=6 is the number the
oracle DECODES as that block's mode, which is the shape a neighbour-cell
mix-up would take and the shape Main predicted. One data point.
Unblock: print above_mi->mode/left_mi->mode from the EC_ISTEP name=mode
site that is known to fire rather than a sibling getenv rung, and
compare against mi(63,24)/mi(64,23) on our side. If the square path's
coarse bands differ from those cells the fix is lane-rectx r5's
mi-exact override applied to the square reader -- the same
neighbour-context family as the around_mi_422_chroma and dc-sign fixes,
and the third instance of it.lane-av1422warp: ladder walked -- first-delta read is the luma mode at mi(64,24)Ahmet Kaan Gümüş · 176bd7c
lane-av1422warp: ladder walked -- first-delta read is the luma mode at mi(64,24) Report only; tree byte-identical to ac874969, bypass reverted, aomdec rebuilt to its committed shape (grep -c bitpos = 0, MODECTX = 0). Ladder rebuilt with round 13's emission fix on both sides, then reverted. Instrument note: the two rung SETS differ per path (the oracle emits a tx_type step this decoder's rect reader has no print for), so a strict index walk breaks immediately; the ladder is walked on the all_zero anchors both sides emit once per transform unit, and the delta map is read off the bit positions in between. Delta map: constant -14 for every transform unit 0..2427, -11 at 2428. Inside that window, every oracle read up to and including mi(64,24)'s dq has a counterpart on our side at +14; the first read without one is mi(64,24)'s luma mode. NAMED: the luma mode symbol of mi(64,24). Oracle mode val=6, ours val=1. The oracle's read spans 92323->92327 (4 bits), ours 92337->92342 (5 bits). Every earlier read pairs exactly; the deviation begins here and persists to the window end, which is where the -14 -> -11 step comes from. Same block as the round-7 structural consequence (one 32x32 luma TU against 8x8 leaves). NOT yet named: same block size and same bit position, different symbol VALUE, so the divergence is the kf_y_mode[above_ctx][left_ctx] CONTEXT. This lane tried to print it on both sides and did not get a paired measurement -- our block reaches read_intra_mode_rect, not the square read_intra_mode the print was placed in, and the oracle-side MODECTX rung did not fire in the time available. Both reverted; no fix claimed. Unblock: print the mode context at mi(64,24) on both sides (ours from read_intra_mode_rect, the path that block takes; the oracle's from get_y_mode_cdf) and compare above_mode/left_mode. The unit ladder is now trustworthy, so once the context pairs the fix follows directly and the ladder re-run confirms it. Credit: round 13's instrument correction is what made this round possible; rounds 11 and 12 both reported artefacts of that placement.
lane-av1422warp: SETTLED -- the oracle consumes use_filter_intra/filter_intra_mode and our reads matchAhmet Kaan Gümüş · 4fe52c7
lane-av1422warp: SETTLED -- the oracle consumes use_filter_intra/filter_intra_mode and our reads match
Report only; tree byte-identical to 76d692e7, bypass reverted, aomdec
rebuilt to its committed shape (grep -c bitpos = 0).
Rung emission fixed: the bit position is appended BEFORE the format
string's \n so it lands on the same physical line (18 EC_ISTEP and 14
EC_COEFF_STEP sites). With correct emission the oracle at mi(68,16) reads
angle_uv -2 @92312, use_filter_intra 1 @92312,
filter_intra_mode 3 @92313, next block skip @92323
which is IDENTICAL to ours -- same values, same bit positions, same
next-block position. The oracle consumes both symbols. This window is
closed and the two extra reads rounds 11 and 12 chased never existed.
Mechanism, recorded so it is not repeated: with the position on the
previous line, a record-wise parse (split on EC_ISTEP, read bitpos from
inside the record) attributes each read's position to the PRECEDING
read, because that is the line it was physically printed on. The two
filter_intra reads therefore carried the positions of the reads before
them, and a window bounded on those positions silently excluded them.
Sharper than round 8's lesson: with a multi-field rung a positional
parse is only as good as the field's placement, and a field landing on
an adjacent line does not announce itself, it just misattributes.
The round-10 '3 bits short' measurement stands but its window does NOT
contain the divergence -- the mode reads there are now proven to match
symbol for symbol and bit for bit. Re-anchoring the ladder past
mi(68,16) to find the real first-delta read is the next step and is
unchanged; this lane ran out of budget before it.lane-av1422warp: RETRACT round 11's conclusion -- libaom's own predicate says allowed=1Ahmet Kaan Gümüş · b16dd2a
lane-av1422warp: RETRACT round 11's conclusion -- libaom's own predicate says allowed=1
Report only; tree byte-identical to 6bb5595a, bypass reverted, aomdec
rebuilt to its committed shape (grep -c PALSZ = 0).
Round 11 was wrong twice, both from trusting a print without checking
how it is emitted.
Error 1, parse artefact: the oracle's EC_ISTEP bit position is inserted
after the format string's \n, so it lands on the PREVIOUS line, and
round 11's line-filtered window dropped every oracle
use_filter_intra/filter_intra_mode line it was hunting. Re-parsed
record-wise the oracle emits 241 use_filter_intra lines, and the
observation survives: at mi(68,16) we read use_filter_intra val=1 and
filter_intra_mode val=3 between angle_uv and the next block, and the
oracle shows none there.
Error 2, and this one kills the conclusion: round 11 said
av1_filter_intra_allowed should have suppressed those reads and that
enable_filter_intra or palette_size[0] was the disagreeing input.
Measured with a rung inside libaom's own read_filter_intra_mode_info:
PALSZ mi=68,16 bsize=8 mode=0 psize0=0 efi=1 wide=32 high=16 allowed=1
allowed=1. libaom's predicate IS satisfied -- DC_PRED, palette_size 0,
enable_filter_intra 1, 32x16 within wide<=32 && high<=32. Both
previously-unmeasured inputs AGREE with us. There is no stale palette
state and no header-bit disagreement, and round 11's framing is wrong.
What remains: our two reads are real in the bit stream while libaom's
predicate says the corresponding reads are allowed, so the divergence is
not a missing/extra gate in the sense round 11 described and this lane
cannot say what it is. The residual tension is internal to the
instrumented oracle -- its allowed=1 and its absent use_filter_intra
EC_ISTEP at mi(68,16) do not sit together, which points at the
oracle's instrumentation rather than at a decoder defect.
Unblock restated: do NOT gate our use_filter_intra read. First settle
the oracle -- does aomdec consume the symbol at mi(68,16)? Compare its
bit position after angle_uv with the mode-info trace, with the bit
position emitted on the SAME line. Only if the oracle genuinely does not
consume it is our read the defect.lane-av1422warp: name the two extra reads -- use_filter_intra + filter_intra_mode at mi(68,16)Ahmet Kaan Gümüş · bec2869
lane-av1422warp: name the two extra reads -- use_filter_intra + filter_intra_mode at mi(68,16)
Report only; tree byte-identical to 4cc74580, bypass reverted, aomdec
rebuilt to its committed shape (grep -c bitpos = 0).
Mode-rung bit positions added on both sides (our EC_ISTEP per-symbol
macro, the oracle's twelve EC_ISTEP prints in decodemv.c), paired
bit-position-anchored throughout, then reverted.
With the constant -14 folded in, the window shows the oracle's mode info
for mi(68,16) ending at angle_uv while ours continues with TWO EXTRA
reads:
ours 92326 use_filter_intra val=1 <-- EXTRA
92327 filter_intra_mode val=3 <-- EXTRA
The oracle's silence is not a rung gap: its use_filter_intra print sits
inside if (av1_filter_intra_allowed(cm, mbmi)) and its filter_intra_mode
print inside if (...use_filter_intra) (decodemv.c:638-656), so a missing
line means the read did not happen.
The block is the same on both sides, enum-resolved per the round-8
lesson: oracle EC_IMODE bsize=8 and enums.h:100-115 makes 8 =
BLOCK_32X16; ours reads fn=rect bw=32 bh=16. Same footprint, same bit
position.
The gate that should have suppressed them is av1_filter_intra_allowed
(reconintra.h:75-79): mode == DC_PRED && palette_size[0] == 0 &&
(enable_filter_intra && wide <= 32 && high <= 32). The block satisfies
the mode and size conditions, so the suppressing input is one of the two
this lane did NOT measure -- the sequence header's enable_filter_intra
or the block's palette_size[0]. This lane ran out of budget before
measuring either and does not claim which.
Unblock is now short: print enable_filter_intra and palette_size[0] for
this block on both sides and compare against the predicate. One boolean,
and the fix is one gate on the use_filter_intra read.lane-av1422warp: second window bisect -- 3 bits short, in the mode readsAhmet Kaan Gümüş · 9048e8a
lane-av1422warp: second window bisect -- 3 bits short, in the mode reads Report only; tree byte-identical to a7506ee2, bypass reverted, aomdec rebuilt to its committed shape (grep -c bitpos = 0). EC_COEFF_STEP bitpos re-added on both sides, paired, reverted again. The bit delta is the same constant -14 for every coefficient unit from 0 through 2427 and changes at 2428: the oracle consumes 18 bits across that unit, we consume 15. We are 3 BITS SHORT -- the mirror image of round 6, where we were 6 bits long. The window holds only two all_zero=1 skips, so no coefficient read falls inside it; the three bits live in the block-mode reads (skip, cdef, delta_q, mode, angle_delta, uv_mode, angle_delta_uv, use_filter_intra, filter_intra_mode) that no rung on either side currently carries a bit position for. A trap recorded per the round-8 lesson: the unit INDEX pairing is only valid while the bit delta is constant, and it stops being a safe guide exactly here. Our decoder emits 2680 coefficient units against the oracle's 2512, and a skipped unit's txb_skip read can cost as few as one bit, so extra skip units coexist with a constant delta. In the window the oracle's unit 2427 is plane=2 and ours is plane=0 -- the indices no longer name the same block though the bit positions still agree. Pair bit positions, never unit indices, from here on. Enum discipline applied to what is printed: plane=0/1/2 is libaom's PLANE_TYPE_Y/U/V; side=8 is our square reconstruct's side (an 8x8 transform unit); ctx on both lines is the txb_skip context, NOT a tx_size context. Nothing here is claimed to be a bsize, partition or tx_size category, so no enum lookup is needed to read it. Unblock: add a bit position to the MODE rung on both sides (our EC_ISTEP per symbol, and decodeframe.c's intra mode-info read on the oracle) and pair the eight mode reads across the window. Three bits across seven or eight reads is a single short read.
lane-av1422warp: RETRACT round 8's bsize claim; same block size, same tx contextAhmet Kaan Gümüş · 439da94
lane-av1422warp: RETRACT round 8's bsize claim; same block size, same tx context Report only; tree byte-identical to 4dfeb024, bypass reverted, a420.obu still byte-exact. Round 8 read the oracle's PARTB bsize=9 as BLOCK_64X32 and concluded the block size entering the partition read was the divergence. The real enum (enums.h:100-115) makes bsize=9 BLOCK_32X32 -- the SAME block size we decode. Round 8 also mis-called bsize=15 a 64x16 (it is BLOCK_128X128, the superblock root) and bsize=12 a BLOCK_128X64 (it is BLOCK_64X64). That conclusion is retracted in the report rather than left standing. Round 9, with the enum right: at mi(64,24) both decoders are on a 32x32 block and read the same tx_size row at the same context -- oracle EC_TXCTXB maxw=32 maxh=32 ctx=1, ours tx_depth ctx=1, and bsize_to_tx_size_cat(BLOCK_32X32)==2 matches our max_tx==32 arm. So the tx_size lookup is not the divergence either. The reader state already differs at mi(64,24)'s FIRST symbol (skip, oracle rng 39524 vs ours 40716) while the coefficient ladder pairs through unit 2427, so the desync window is the reads between unit 2427's block and mi(64,24)'s skip -- the same narrow between-two-units window round 6 characterised, at its second occurrence. The structural difference at mi(64,24) is real and downstream; the desync is upstream of it and is still to find.
lane-av1422warp: the mi(64,24) partition reads PAIR -- the bsize entering them does notAhmet Kaan Gümüş · 3a293e4
lane-av1422warp: the mi(64,24) partition reads PAIR -- the bsize entering them does not
Report only; tree byte-identical to 20929703, bypass reverted, aomdec
rebuilt to its committed shape (grep -c PARTB = 0).
Partition rungs added and reverted on both sides. Two results:
1. Bottom-edge truncation is RULED OUT. libaom recomputes
has_rows = (mi_row + hbs) < mi_rows with the CURRENT bsize's hbs
(decodeframe.c:1292) and so does ours, per level; both go has_rows=0
at the SB and 64 level and has_rows=1 from the 64x32 level down. The
edge arithmetic agrees at every level of SB row 64.
2. The partition reads themselves are IDENTICAL -- same bit positions
under the constant -14, same values:
mi=64,16 bsize=9 bitpos 92247/92261 value 1/1
mi=64,24 bsize=9 bitpos 92321/92335 value 0/0
mi=64,32 bsize=9 bitpos 92356/93518 value 3/2 <- diverged
At mi=64,32 we are 1162 bits behind. The gap opens in the block AFTER
mi=64,24: the oracle spends 33 bits there, we spend ~1183.
So the named divergence is the BLOCK SIZE entering the partition read,
not the partition symbol. The oracle reads it for a BLOCK_64X32 and
lands PARTITION_NONE on a 64x32 leaf (one 32x32 luma TU + 16x32 chroma);
we read a partition at the same bit with the same value and land on a
32x32 SQUARE coded as 8x8 leaves. Same position, same symbol, different
bsize in and different block out -- so the bsize is decided one or more
levels ABOVE mi(64,24), in the HORZ/SPLIT walk that produced the child.
Left, and deliberately not started here: tracing the bsize lineage from
the SB root down to mi(64,24 needs the bsize field on our rung, which
is another instrumentation round rather than a continuation of this one.
The scan-table question stays open and cannot be re-checked until the
partition tree is right.lane-av1422warp: localize the mi(64,24) boundary to a partition/bsize decisionAhmet Kaan Gümüş · a3d0b2b
lane-av1422warp: localize the mi(64,24) boundary to a partition/bsize decision Report only; tree byte-identical to b23a3047, bypass reverted, a420.obu still byte-exact. At mi(64,24) the oracle walks a 64x32 rect (bsize=9) and codes a 32x32 luma TU; we walk a 32x32 SQUARE and code 8x8 leaves (tx_depth=2 on a 32 side). So the PARTITION symbol is where the decoders part company, not tx_depth and not a neighbour vote. The block is on the frame's last superblock row (32 rows of 288), inside SB(mi_row 64, mi_col 0). Both step traces already differ at that block's first symbol while the coefficient ladder pairs through unit 2427 (mi(68,16)'s V chroma), so the desync window is the reads between mi(68,16)'s chroma tail and mi(64,24)'s mode read. Stopping here because the partition rungs this lane has do not fire for these blocks and the round 5-6 bit-position rungs are reverted: closing it needs a fresh instrumentation round aimed at the superblock partition symbol and its context. That is a scheduling decision, not another step inside this lane. The scan-table disagreement from round 5 is in the same structure family and is flagged to be looked at alongside it.