diff --git a/lanes/b128.report.md b/lanes/b128.report.md index 88a3a9b6..c7a4a1e4 100644 --- a/lanes/b128.report.md +++ b/lanes/b128.report.md @@ -77,3 +77,130 @@ open item names is entirely the SEARCH-time vs WRITE-time stack divergence own reconstruction through `decode_stream` AND through ffmpeg. RED before this lane by construction: `write_sb128_root` wrote `PARTITION_SPLIT` at every root, so the count was 0 and no such block existed to decode. + +### Census (`EC_AV1_B128_CENSUS=1`, plus a per-row count in the gate) + +Per row, over the four-quantizer ladder (search took / writer coded -- the +writer is higher because the filter search re-codes each tile): + +| row | 128 roots taken | writer-coded | +|---|---|---| +| bars 1080p | 3448 | 6013 | +| bars 2160p | 4144 | 5827 | +| film A | 505 | 1241 | +| film B | 1928 | 3189 | +| screen capture | 4736 | 4774 | + +Per frame on film B the census reads e.g. `100 whole 128x128 roots, 336 +coded blocks (83.3% of the frame's area at 128)` -- the lever cen3's L1 +asked for (38754 coded blocks vs libaom's 16178) is really being pulled. +All of them are on INTER frames: a key frame's 128 root still writes SPLIT. + +## 3. The gate + +`bd_rate_screen_native`, 12 frames, four quantizers, BD-rate vs libaom +`cpu-used 6` / rav1e `speed 6` (lower is better). Both arms from THIS tree, +both controls reproduced (not taken from the charter): + +| row | 64 superblocks (control) | 128 + the 128 root | +|---|---|---| +| bars 1080p | −2.6 / −18.3 | **−3.3 / −18.9** | +| bars 2160p | +8.8 / −13.2 | **+7.9 / −14.0** | +| film A (1080p) | +20.6 / −5.1 | **+20.4 / −5.2** | +| film B (2160p) | +24.8 / −2.1 | **+24.2 / −2.5** | +| screen capture | +14.6 / −33.2 | **+14.4 / −33.2** | + +Long GOP (`bd_rate_film_long_gop`, 48 frames): + +| row | 64 superblocks | 128 + the 128 root | +|---|---|---| +| film A | +24.7 / −7.5 | **+24.4 / −7.7** | +| film B | +86.8 / +7.4 | **+85.6 / +6.6** | + +The 2x2 the charter asked for (film B, 12 frames): + +| arm | vs libaom | vs rav1e | +|---|---|---| +| SB64, LR on (control) | +24.8% | −2.1% | +| SB128 + 128 root, LR on | **+24.2%** | **−2.5%** | +| SB128 + 128 root, LR off (`EC_AV1_LR=0`) | +24.6% | −2.3% | + +(The SB64 LR-off control was not re-run: the SB64 path is byte-identical to +the control tree -- the pins prove it -- and lane-sb128b measured it at ++25.4/−1.6. The forced ≥128 LR unit is no longer a loss: LR ON is the better +arm on both columns now, the reverse of lane-sb128b's reading.) + +Every row of both gates is down or flat on both columns. The keep rule +HOLDS -- and the default still does not flip. See below. + +## 4. Why the default stays OFF (the blocker, not this lane's) + +With `EC_AV1_SB128=1`, **eleven** of this crate's own round-trip tests fail, +and they fail with the 128x128 BLOCK switched off (`EC_AV1_B128=0`) too -- +i.e. they are lane-sb128's SPLIT-only plumbing, at sizes its own 256x128 +witness never covered: + + stream::tests::decode_stream_round_trips_a_gop + stream::tests::decode_stream_round_trips_an_odd_size_gop + stream::tests::decode_stream_agrees_with_ffmpeg_on_a_gop + stream::tests::decode_stream_matches_the_tile_path_on_a_key_frame + stream::tests::streaming_decode_matches_the_collecting_one + stream::tests::a_doubly_cut_superblock_root_round_trips_in_every_plane + stream::tests::a_sweep_of_doubly_straddling_sizes_round_trips_through_ffmpeg + encoder::tests::every_tile_layout_decodes_sample_exact_through_both_decoders + encoder::tests::tile_bytes_do_not_depend_on_the_thread_count + encoder::tests::a_moving_detail_clip_codes_two_delta_q_levels_both_decoders_read_exactly + encode::tests::a_repeated_pattern_key_frame_codes_intrabc_blocks_ffmpeg_decodes_exactly + +`decode_stream_round_trips_a_gop` fails with exactly the refusal lane-sb128b +root-caused ("a reference frame selected with no picture at this frame's own +ref_frame_idx slot"), so at least one writer/reader desync is still live in +the 128 path at odd sizes / multiple tiles. Two more +(`encode::tests::reach_matches_libaom_has_top_right_and_has_bottom_left`, +`every_rect_shape_reaches_what_libaom_says_over_the_whole_superblock`) are +TEST staleness: they assert libaom's 64-superblock reach tables against a +process whose superblock size is 128. + +A 0.6-point BD win does not buy shipping that, so `SB128_DEFAULT` stays +`false` and the whole feature stays behind `EC_AV1_SB128=1`. The next lane +is named by this list. + +## 5. A defect fixed on the way (class: stale header in the test harness) + +Ten decode round-trip tests encode with THIS process's encoder and then +decode the tile directly with a plain `FrameCtx`, whose superblock size is +the DECODER default (64) -- not the size the writer used. With 128 +superblocks on, the reader skipped the root's partition symbol and the tile +desynced at symbol 0 (found by `EC_AV1_SYMTRACE`: the reader's first symbol +was the writer's second). `FrameCtx::for_encoder` exists for exactly this +and is now used in all ten; the module was swept, and two of the ten were +not failing yet. Same shape as the `filter_intra_on()` argument beside them. + +## Disposition + +- `deferred`: **HORZ / VERT at the 128 root** (two 128x64 / 64x128 blocks) -- + the writer has no rect neighbour recording and the search no rect + prediction/SSE at this size; the square NONE arm needed neither. Unblocked + by a rect `record_inter`/`record` pair plus a rect trial in + `search_root_128`. The decoder already reads both (lane-sb128c r7). +- `deferred`: **the 128 block's residual and its compound arm** -- four + TX_64X64 luma units interleaved with a TX_32X32 chroma pair per mu chunk, + on the offset-10 `txb_skip` rows, plus one `txfm_partition` symbol per + chunk. Unblocked by that writer path; `write_inter_block_128` refuses a + non-skip block until then, so nothing can silently code one wrong. +- `deferred`: **the intra 128 root on key frames** -- the key-frame writer + codes SPLIT at every 128 root, as before. +- `open`: the eleven pre-existing 128-superblock desyncs above (the default's + blocker). +- `open`: search-time vs write-time mv stacks still differ (lane-sb128b's own + second open item); the writer's clamp makes it safe, not right. + +## Suite / checks (default OFF, the shipped state) + + s1 --skip stream:: 340 passed; 0 failed; 34 ignored (RC=0) + s2 stream:: --skip 10bit 200 passed; 0 failed; 15 ignored (RC=0) + s3 10bit 42 passed; 0 failed; 1 ignored (RC=0) + --ignored every_speed_preset_decodes_sample_exact_through_both_decoders ok + --ignored a_128_superblock_clip_whose_root_search... ok (406 blocks) + the_encoders_own_streams_are_byte_identical_to_their_pins ok, and ok at EC_AV1_SPEED=6 + cargo check --workspace --all-targets 0 errors, 0 ec-av1 warnings