forge
Explore
Log in

Don't you dare go Hollow

wip(av1): sbpart r3's in-flight rect64 bisect edits, committed verbatim at the turn cap

Browse files at this commit

dac1692efcb3d5996f7fade99307c169b1c77f6cAhmet Kaan GümüşParent: 8aa2626
The builder stopped at its 75-turn limit with "compiles clean, now run the
gate" -- so this tree compiles but its gate result is unknown to me. State
unverified: r4 re-runs the gate before believing anything here.
crates/ec-av1/src/decode.rsmodified+8 -1
@@ -2624,7 +2624,14 @@ fn decode_block_rect64(
26242624 cdfs,
26252625 neighbours.above_mode[c],
26262626 neighbours.left_mode[r],
2627- true,
2627+ // `is_cfl_allowed` (spec 5.11.5) caps CFL at <=32x32; these
2628+ // superblock-level HORZ/VERT strips are 64x32/32x64, so unlike
2629+ // `decode_block_rect`'s own 32x16/16x32 strips (where `true` is
2630+ // correct), CFL must never be offered here -- passing `true`
2631+ // read `uv_mode` off the 14-symbol `uv_mode_cfl` CDF instead of
2632+ // the real 13-symbol `uv_mode_no_cfl` one and desynced the tile
2633+ // from this block's very first symbol (lane-sbpart r3 bisect).
2634+ false,
26282635 bw,
26292636 bh,
26302637 enable_filter_intra,
crates/ec-av1/src/stream.rsmodified+10 -0
@@ -6490,6 +6490,16 @@ mod tests {
64906490 };
64916491 let ffmpeg_frames = ffmpeg_decode_sequence(&stream, width, height, frame_count);
64926492 assert_eq!(frames.len(), frame_count);
6493+ let mismatched = frames
6494+ .iter()
6495+ .zip(&ffmpeg_frames)
6496+ .any(|(got, want)| got.y != want.y || got.u != want.u || got.v != want.v);
6497+ if mismatched {
6498+ if let Ok(path) = std::env::var("EC_AV1_GATE_DUMP") {
6499+ std::fs::write(&path, &stream).expect("writing pinned stream");
6500+ eprintln!("EC_AV1_GATE_DUMP: wrote mismatching stream (seed {seed}) to {path}");
6501+ }
6502+ }
64936503 for (i, (got, want)) in frames.iter().zip(&ffmpeg_frames).enumerate() {
64946504 assert_eq!(got.y, want.y, "{NAME} frame {i} luma vs ffmpeg (seed {seed})");
64956505 assert_eq!(got.u, want.u, "{NAME} frame {i} U vs ffmpeg (seed {seed})");