diff --git a/crates/ec-av1/src/decode.rs b/crates/ec-av1/src/decode.rs index da4adb6a..e80a7f36 100644 --- a/crates/ec-av1/src/decode.rs +++ b/crates/ec-av1/src/decode.rs @@ -1519,6 +1519,41 @@ pub(crate) fn palette_split_tx_hits() -> usize { PALETTE_SPLIT_TX_HITS.with(|c| c.get()) } +thread_local! { + /// lane-pal8 r1: square 8x8 LEAVES ([`decode_leaf8`]) that actually use a + /// palette (Y or UV) -- the shape every 8-bit `--tune-content=screen` + /// stream stopped on, since aomenc palettes square blocks at 8 bit and + /// `--min-partition-size=8` puts them on this leaf path. + static PALETTE_LEAF8_HITS: std::cell::Cell = const { std::cell::Cell::new(0) }; +} + +/// Current value of [`PALETTE_LEAF8_HITS`]. +pub(crate) fn palette_leaf8_hits() -> usize { + PALETTE_LEAF8_HITS.with(|c| c.get()) +} + +/// Zeroes [`PALETTE_LEAF8_HITS`] (per-attempt gate counting). +pub(crate) fn reset_palette_leaf8_hits() { + PALETTE_LEAF8_HITS.with(|c| c.set(0)); +} + +thread_local! { + /// lane-pal8 r1: NON-SKIP palette blocks on a superblock-level (64-level) + /// HORZ/VERT or 1:4 strip ([`decode_block_rect64`]) -- i.e. a palette + /// block that also carries a real, corner-cropped luma transform. + static PALETTE_SB_STRIP_HITS: std::cell::Cell = const { std::cell::Cell::new(0) }; +} + +/// Current value of [`PALETTE_SB_STRIP_HITS`]. +pub(crate) fn palette_sb_strip_hits() -> usize { + PALETTE_SB_STRIP_HITS.with(|c| c.get()) +} + +/// Zeroes [`PALETTE_SB_STRIP_HITS`] (per-attempt gate counting). +pub(crate) fn reset_palette_sb_strip_hits() { + PALETTE_SB_STRIP_HITS.with(|c| c.set(0)); +} + // lane-hgkf r2: SKIPPED intra blocks whose `tx_depth` split the luma transform // and which are therefore predicted one transform unit at a time (a skipped // block codes no coefficients, so nothing else in the stream witnesses this @@ -8593,6 +8628,14 @@ fn decode_block_rect64( // needs the plain, uncropped rect reader [`decode_block_rect`] already // has, not this one's truncation. `skip` (no residual at all) is // still supported below (lane-palette2 r4). + // + // lane-pal8 r1 MEASURED the lift and it is NOT free: dropping this + // refusal decodes `testsrc2` 128x128 10-bit cq55 `--enable-palette=1 + // --min-partition-size=8 --tile-columns=1` with a whole-frame pixel + // mismatch (the arm the gate below counts). Something in this shape's + // palette prediction or its corner-cropped residual is wrong, and the + // refusal stays until that is found -- it is counted, never skipped. + PALETTE_SB_STRIP_HITS.with(|c| c.set(c.get() + 1)); return Err(unsupported( "a palette block with a real transform on a superblock-level HORZ/VERT \ strip (corner-cropped luma coefficients not ported for palette)", @@ -10670,7 +10713,15 @@ fn decode_leaf8( // An 8x8 leaf is well within `is_cfl_allowed`'s <=32x32 bound (spec // 5.11.5), so it reads the CFL-allowed `uv_mode_cfl` CDF, like every other // `decode_block` caller at 16x16 and up. - let (skip, mode, angle_delta_y, uv_mode, angle_delta_uv, alpha, filter_intra, _palette_y, _palette_uv) = + // lane-pal8 r1: this leaf's own palette-Y mode ctx and colour cache + // (`av1_get_palette_mode_ctx` / `av1_get_palette_cache`, decodemv.c:567, + // `read_palette_mode_info`), at its REAL mi position -- passing + // `None`/`&[]` read `palette_y_mode` off CDF row 0 and refused by name the + // moment a real 8x8 palette block fired, which is where every 8-bit + // `--tune-content=screen --min-partition-size=8` stream stopped. + let (palette_ctx, palette_cache) = neighbours.palette_ctx_and_cache_mi(leaf_mi); + let palette_uv_cache = neighbours.palette_uv_cache_mi(leaf_mi); + let (skip, mode, angle_delta_y, uv_mode, angle_delta_uv, alpha, filter_intra, palette_y, palette_uv) = read_intra_mode( dec, cdfs, @@ -10682,11 +10733,31 @@ fn decode_leaf8( neighbours.skip_txfm_ctx(leaf_mi.0, leaf_mi.1), allow_screen_content_tools, allow_intrabc, - None, - &[], + Some((palette_ctx, &palette_cache)), + &palette_uv_cache, leaf_mi.0, leaf_mi.1, )?; + // `av1_visit_palette`'s reconstruction (decodeframe.c:1135): the colour + // index map, mapped through the base colours, IS the block's prediction -- + // carried to the next `reconstruct`/`read_plane` through the same + // [`PALETTE_PRED`] slot [`decode_block`] uses at 16x16 and up. + let palette_y_buf: Option> = palette_y + .as_ref() + .map(|p| p.map.iter().map(|&i| p.colors[i as usize]).collect()); + let palette_uv_bufs: Option<(Vec, Vec)> = palette_uv.as_ref().map(|p| { + ( + p.map.iter().map(|&i| p.u_colors[i as usize]).collect(), + p.map.iter().map(|&i| p.v_colors[i as usize]).collect(), + ) + }); + let (pal_y_size, pal_y_colors) = + palette_y.as_ref().map_or((0, [0u16; 8]), |p| (p.size, p.colors)); + let (pal_uv_size, pal_uv_colors) = + palette_uv.as_ref().map_or((0, [0u16; 8]), |p| (p.size, p.u_colors)); + if palette_y.is_some() || palette_uv.is_some() { + PALETTE_LEAF8_HITS.with(|c| c.set(c.get() + 1)); + } let uv_predict_mode = if uv_mode == UV_CFL_PRED { DC_PRED } else { @@ -10715,7 +10786,11 @@ fn decode_leaf8( // transform units, each off the units already written left/above of // it inside this same leaf -- an intra block's transform size is read // whether or not it is skipped, and spec 7.11.2 predicts per unit. - if resolved == 4 { + // A palette block's prediction is the whole-block index map, never + // per-transform-unit edges ([`decode_block`]'s own `split_tx_skip` + // rule) -- so a palette leaf takes the single 8x8 reconstruct below + // even when `tx_depth` resolved to TX_4X4. + if resolved == 4 && palette_y_buf.is_none() { SKIP_SPLIT_TX_HITS.with(|c| c.set(c.get() + 1)); for tu_row in 0..2 { for tu_col in 0..2 { @@ -10750,6 +10825,9 @@ fn decode_leaf8( } } } else { + if let Some(buf) = &palette_y_buf { + set_palette_pred(buf.clone()); + } y.reconstruct( px, py, @@ -10764,6 +10842,9 @@ fn decode_leaf8( ); } let ac = alpha.map(|_| cfl_ac_q3(y, px, py, 8)); + if let Some((ub, _)) = &palette_uv_bufs { + set_palette_pred(ub.clone()); + } u.reconstruct( cpx, cpy, @@ -10776,6 +10857,9 @@ fn decode_leaf8( None, smooth_neighbor_uv, ); + if let Some((_, vb)) = &palette_uv_bufs { + set_palette_pred(vb.clone()); + } v.reconstruct( cpx, cpy, @@ -10793,6 +10877,9 @@ fn decode_leaf8( v_grid = vec![0i32; 16]; } else if resolved != 4 { let around = neighbours.around_mi(leaf_mi, 8); + if let Some(buf) = &palette_y_buf { + set_palette_pred(buf.clone()); + } luma_grid = read_plane( dec, cdfs, @@ -10820,6 +10907,9 @@ fn decode_leaf8( smooth_neighbor, )?; let ac = alpha.map(|_| cfl_ac_q3(y, px, py, 8)); + if let Some((ub, _)) = &palette_uv_bufs { + set_palette_pred(ub.clone()); + } u_grid = read_plane( dec, cdfs, @@ -10842,6 +10932,9 @@ fn decode_leaf8( None, smooth_neighbor_uv, )?; + if let Some((_, vb)) = &palette_uv_bufs { + set_palette_pred(vb.clone()); + } v_grid = read_plane( dec, cdfs, @@ -10893,6 +10986,19 @@ fn decode_leaf8( y.height, ); let tu_skip_ctx = neighbours.luma_skip_ctx(tu_mi, 1); + // Each 4x4 unit predicts from its own window of the block's + // 8x8 colour-index map ([`decode_block`]'s per-TU slice at + // 16x16 and up) -- the whole-block buffer would be taken by + // the FIRST unit and indexed at the wrong stride. + if let Some(buf) = &palette_y_buf { + PALETTE_SPLIT_TX_HITS.with(|c| c.set(c.get() + 1)); + let mut window = vec![0u16; 16]; + for row in 0..4 { + let src = (tu_row * 4 + row) * 8 + tu_col * 4; + window[row * 4..][..4].copy_from_slice(&buf[src..][..4]); + } + set_palette_pred(window); + } let tu_grid = read_plane( dec, cdfs, @@ -10932,6 +11038,9 @@ fn decode_leaf8( } let ac = alpha.map(|_| cfl_ac_q3(y, px, py, 8)); let chroma_around = neighbours.around_mi(leaf_mi, 8); + if let Some((ub, _)) = &palette_uv_bufs { + set_palette_pred(ub.clone()); + } u_grid = read_plane( dec, cdfs, @@ -10954,6 +11063,9 @@ fn decode_leaf8( None, smooth_neighbor_uv, )?; + if let Some((_, vb)) = &palette_uv_bufs { + set_palette_pred(vb.clone()); + } v_grid = read_plane( dec, cdfs, @@ -11004,12 +11116,12 @@ fn decode_leaf8( neighbours.above[leaf_mi.1 + cell][2] = v_state; } } - // Non-palette 8x8 leaf (this path never reads a palette): clear the - // above/left palette state over its own cell so the next block's ctx and - // colour cache do not read a previous block's palette (lane-palette2 r8). + // This leaf's own palette state into the mi-granular above/left bands + // (sizes 0 when it used none, which is what clears a previous block's + // palette out of the next block's ctx and colour cache). { - neighbours.record_palette_y_rect(leaf_mi, 8, 8, 0, [0u16; 8]); - neighbours.record_palette_uv_rect(leaf_mi, 8, 8, 0, [0u16; 8]); + neighbours.record_palette_y_rect(leaf_mi, 8, 8, pal_y_size, pal_y_colors); + neighbours.record_palette_uv_rect(leaf_mi, 8, 8, pal_uv_size, pal_uv_colors); } neighbours.fill_skip_grid(leaf_mi, 2, skip); neighbours.fill_lf_grid(leaf_mi, 2, 4, 0); @@ -11017,12 +11129,12 @@ fn decode_leaf8( return Ok(mode); } neighbours.record_mi(leaf_mi, 8, &[luma_grid, u_grid, v_grid]); - // Non-palette 8x8 leaf (this path never reads a palette): clear the - // above/left palette state over its own cell so the next block's ctx and - // colour cache do not read a previous block's palette (lane-palette2 r8). + // This leaf's own palette state into the mi-granular above/left bands + // (sizes 0 when it used none, which is what clears a previous block's + // palette out of the next block's ctx and colour cache). { - neighbours.record_palette_y_rect(leaf_mi, 8, 8, 0, [0u16; 8]); - neighbours.record_palette_uv_rect(leaf_mi, 8, 8, 0, [0u16; 8]); + neighbours.record_palette_y_rect(leaf_mi, 8, 8, pal_y_size, pal_y_colors); + neighbours.record_palette_uv_rect(leaf_mi, 8, 8, pal_uv_size, pal_uv_colors); } INTER8_SKIP_BAND_HITS.with(|c| c.set(c.get() + 1)); neighbours.fill_skip_grid(leaf_mi, 2, skip); diff --git a/crates/ec-av1/src/stream.rs b/crates/ec-av1/src/stream.rs index 5a47c52a..3544cde8 100644 --- a/crates/ec-av1/src/stream.rs +++ b/crates/ec-av1/src/stream.rs @@ -2800,6 +2800,235 @@ mod tests { } } + /// lane-pal8 r1, the gate for a palette on a SQUARE 8x8 LEAF. + /// + /// `read_palette_mode_info` (decodemv.c:567) reads `palette_y_mode` for + /// every `DC_PRED` block whose `av1_get_palette_bsize_ctx` + /// (`num_pels_log2 - num_pels_log2[BLOCK_8X8]`, 0 at 8x8) exists, and + /// `av1_decode_palette_tokens` (decodeframe.c:1135, `av1_visit_palette`) + /// reads the colour-index map after the WHOLE mode-info read. Ours passed + /// `None`/`&[]` from [`decode::decode_leaf8`], reading the mode symbol off + /// CDF row 0 and refusing "a block that actually uses a palette (Y) -- + /// reconstruction is out of scope" the moment it fired -- and at 8 bit + /// aomenc palettes SQUARE blocks, so with `--min-partition-size=8` every + /// 8-bit screen-content stream stopped there (lane-kf900 r4's measurement). + /// + /// Sweeps both bit depths x cq 30/40/55 x `--enable-tx-size-search` 0/1 x + /// two lavfi sources (+ a `--tile-columns=1` arm, per the neighbour-map + /// rule: the palette bands are per-mi and tile-guarded). Key frame only + /// (`--limit=1`): the inter frames of these recipes stop on OTHER lanes' + /// open refusals (8x8 inter leaf chroma mode, inter 1:4 partitions). + /// HARD-asserts the 8x8-leaf palette counter moved on the compared arms + /// and that no arm mismatched, in or out of scope. + #[test] + fn a_real_aomenc_palette_stream_with_8x8_leaves_decodes_pixel_exact() { + const NAME: &str = "a_real_aomenc_palette_stream_with_8x8_leaves_decodes_pixel_exact"; + if !have_ffmpeg() { + eprintln!("SKIP {NAME}: no ffmpeg"); + return; + } + if !have_aomenc() { + eprintln!("SKIP {NAME}: no aomenc at {}", aomenc_path().display()); + return; + } + let (width, height) = (128usize, 128usize); + let (mut leaf8_total, mut fired_arms, mut compared, mut frames_compared) = + (0usize, 0u32, 0u32, 0usize); + let (mut out_of_scope, mut out_of_scope_mismatch, mut refusals) = (0u32, 0u32, 0u32); + let (mut sb_strip_total, mut sb_strip_arms) = (0usize, 0u32); + // The one palette shape this round did NOT lift (measured: lifting it + // mismatches -- see [`decode_block_rect64`]'s own comment). + let mut sb_strip_refusals = 0u32; + for src in ["testsrc2", "smptebars"] { + for depth in [8usize, 10usize] { + for cq in [30usize, 40, 55] { + for txs in [0usize, 1] { + for tiles in [0usize, 1] { + let arm = format!("{src}-{depth}bit-cq{cq}-txs{txs}-tc{tiles}"); + let pix_fmt = if depth == 10 { "yuv420p10le" } else { "yuv420p" }; + let size = format!("{src}=size={width}x{height}:rate=25"); + let render = || { + let out = Command::new("ffmpeg") + .args([ + "-v", "error", "-f", "lavfi", "-i", &size, "-t", "0.04", + "-pix_fmt", pix_fmt, "-strict", "-1", "-f", + "yuv4mpegpipe", "-", + ]) + .stdin(Stdio::null()) + .stdout(Stdio::piped()) + .stderr(Stdio::piped()) + .output() + .expect("ffmpeg failed to run"); + assert!(out.status.success(), "{NAME}: ffmpeg failed for {arm}"); + out.stdout + }; + let y4m_a = render(); + let y4m_b = render(); + assert_eq!( + y4m_a, y4m_b, + "{NAME}: {arm} must render byte-identical across two runs" + ); + let y4m = y4m_a; + let depth_arg = format!("--bit-depth={depth}"); + let input_depth_arg = format!("--input-bit-depth={depth}"); + let cq_arg = format!("--cq-level={cq}"); + let txs_arg = format!("--enable-tx-size-search={txs}"); + let tiles_arg = format!("--tile-columns={tiles}"); + let mut child = Command::new(aomenc_path()) + .args([ + "--codec=av1", + "--passes=1", + "--end-usage=q", + "--cpu-used=0", + "--threads=1", + "--row-mt=0", + "--lag-in-frames=0", + "--limit=1", + "--sb-size=64", + "--tune-content=screen", + "--enable-palette=1", + "--enable-intrabc=0", + "--min-partition-size=8", + "--enable-cdef=0", + "--enable-restoration=0", + "--loopfilter-control=0", + ]) + // aomenc keeps the LAST occurrence of a repeated flag, + // so per-arm overrides go after the base recipe. + .args([&depth_arg, &input_depth_arg, &cq_arg, &txs_arg, &tiles_arg]) + .args(["--obu", "-o", "-", "-"]) + .stdin(Stdio::piped()) + .stdout(Stdio::piped()) + .stderr(Stdio::piped()) + .spawn() + .expect("aomenc failed to start"); + child + .stdin + .take() + .expect("aomenc stdin") + .write_all(&y4m) + .or_else(|e| match e.kind() { + std::io::ErrorKind::BrokenPipe => Ok(()), + _ => Err(e), + }) + .expect("writing y4m to aomenc"); + let out = child.wait_with_output().expect("aomenc failed to run"); + assert!( + out.status.success(), + "{NAME}: aomenc refused {arm}: {}", + String::from_utf8_lossy(&out.stderr) + ); + let stream = out.stdout; + decode::reset_palette_leaf8_hits(); + decode::reset_palette_sb_strip_hits(); + let decoded = decode_stream(&stream); + let leaf8 = decode::palette_leaf8_hits(); + let sb_strip = decode::palette_sb_strip_hits(); + leaf8_total += leaf8; + sb_strip_total += sb_strip; + match decoded { + Ok(frames) => { + assert!(!frames.is_empty(), "{NAME}: {arm} decoded no frame"); + let theirs = if depth == 10 { + ffmpeg_decode_sequence_10bit( + &stream, + width, + height, + frames.len(), + ) + } else { + ffmpeg_decode_sequence(&stream, width, height, frames.len()) + }; + assert_eq!( + frames.len(), + theirs.len(), + "{NAME}: {arm} frame count" + ); + let mut same = true; + for (i, (ours, ref_f)) in + frames.iter().zip(theirs.iter()).enumerate() + { + let ok = ours.y == ref_f.y + && ours.u == ref_f.u + && ours.v == ref_f.v; + if !ok { + eprintln!("{NAME}: {arm} MISMATCH at frame {i}"); + } + same &= ok; + frames_compared += 1; + } + compared += 1; + if sb_strip > 0 { + sb_strip_arms += 1; + assert!( + same, + "{NAME}: {arm} decoded {sb_strip} non-skip palette \ + block(s) on a superblock-level strip and did not \ + match ffmpeg" + ); + } + if leaf8 > 0 || sb_strip > 0 { + fired_arms += 1; + assert!( + same, + "{NAME}: {arm} decoded {leaf8} 8x8-leaf palette \ + block(s) and did not match ffmpeg" + ); + } else { + out_of_scope += 1; + if !same { + out_of_scope_mismatch += 1; + } + } + eprintln!( + "{NAME}: {arm} {} frame(s), {leaf8} 8x8-leaf palette \ + block(s), {sb_strip} superblock-strip palette \ + block(s), exact={same}", + frames.len() + ); + } + Err(e) => { + let msg = e.to_string(); + assert!( + msg.contains("unsupported"), + "{NAME}: {arm} decode failed: {e}" + ); + // Named, counted, never turned into a skip. + if msg.contains("superblock-level HORZ/VERT strip") { + sb_strip_refusals += 1; + } + eprintln!("{NAME}: {arm} REFUSED: {e}"); + refusals += 1; + } + } + } + } + } + } + } + eprintln!( + "{NAME}: {leaf8_total} 8x8-leaf palette block(s) across {fired_arms} arm(s), \ + {compared} arms compared ({frames_compared} frames), {sb_strip_total} \ + superblock-strip palette block(s) across {sb_strip_arms} arm(s), \ + {out_of_scope} out of scope ({out_of_scope_mismatch} mismatched), \ + {refusals} refused ({sb_strip_refusals} superblock-strip palette)" + ); + assert!( + leaf8_total > 0 && fired_arms > 0, + "{NAME}: gate is vacuous -- no compared arm decoded an 8x8-leaf palette block" + ); + assert!( + sb_strip_refusals > 0, + "{NAME}: no arm reached the superblock-strip palette refusal -- the open residue \ + this gate documents is no longer exercised" + ); + assert_eq!( + out_of_scope_mismatch, 0, + "{NAME}: an out-of-scope arm mismatched ffmpeg -- a defect, never a skip" + ); + assert!(frames_compared > 0, "{NAME}: no frame was compared pixel-exact"); + } + /// lane-kf900 r5, the gate for the rect-strip `use_intrabc` read. /// /// `av1_allow_intrabc` is a FRAME-level test (`decodemv.c:892`, diff --git a/lanes/pal8-r1.report.md b/lanes/pal8-r1.report.md new file mode 100644 index 00000000..87b9e7d6 --- /dev/null +++ b/lanes/pal8-r1.report.md @@ -0,0 +1,69 @@ +# lane-pal8 r1 -- palette on a square 8x8 leaf + +Built on `lane-kf900` 5a28354 (merged first, commit `merge lane-kf900`). + +## What changed + +- `crates/ec-av1/src/decode.rs` `decode_leaf8` (~10680): the square 8x8 leaf now + passes its OWN palette-Y mode ctx + colour cache + (`neighbours.palette_ctx_and_cache_mi(leaf_mi)` / `palette_uv_cache_mi`) into + `read_intra_mode` instead of `None`/`&[]`, and keeps the returned + `PaletteY`/`PaletteUv` instead of dropping them. Mirrors + `read_palette_mode_info` (decodemv.c:567; `av1_get_palette_mode_ctx`, + `av1_get_palette_cache`, `read_palette_colors_y/uv` at decodemv.c:478) and + `av1_decode_palette_tokens` / `av1_visit_palette` (decodeframe.c:1135), whose + colour-index map is read after the whole mode-info read -- both already + implemented in `read_intra_mode`; only this call site was excluded. + `palette_bsize_ctx(8)` is `num_pels_log2 - 6 = 0`, chroma map is the 4x4 + (`ss_size_lookup`) one `read_intra_mode` already decodes at `side / 2`. +- Same fn: reconstruction wired through the existing `PALETTE_PRED` slot -- + whole-block 8x8 buffer for the single-TX8 and skip arms, a per-4x4-TU window + slice under a `tx_depth`-split leaf (the same slicing `decode_block` does at + 16x16 and up); a palette skip leaf takes the single 8x8 reconstruct, never the + per-TU one (`decode_block`'s own `split_tx_skip` rule). +- Same fn: the two `record_palette_y_rect(leaf_mi, 8, 8, 0, [0; 8])` tail sites + now stamp the leaf's REAL palette size/colours into the per-mi neighbour bands + (kf900's bands), so the next block's ctx and colour cache see it. +- New counters `PALETTE_LEAF8_HITS` (+ getter/reset) for the gate. +- `crates/ec-av1/src/stream.rs`: new gate + `a_real_aomenc_palette_stream_with_8x8_leaves_decodes_pixel_exact`. + +## Refusals + +- LIFTED (for the square 8x8 leaf): `"a block that actually uses a palette (Y) + -- reconstruction is out of scope"` and its UV twin no longer reachable from + `decode_leaf8`. The two strings STAY in `refusal_inventory.rs`: they are still + live on the inter-frame intra paths (decode.rs:19783/19788, 22479/22484), + another lane's scope. No inventory line was removable this round. +- NOT lifted, MEASURED: `"a palette block with a real transform on a + superblock-level HORZ/VERT strip"`. I removed it and re-ran the gate: the arm + `testsrc2-10bit-cq55-txs0-tc1` decodes a whole-frame MISMATCH vs ffmpeg, so + the refusal is real, not stale. Restored, with the measurement recorded in the + code comment, and the gate now HARD-asserts that some arm still reaches it + (`sb_strip_refusals > 0`) so the residue cannot silently disappear. + Disposition: deferred(root-cause of the 64-level-strip palette mismatch -- + bisect the msac range of that stream's first SB-strip palette block, and check + the class `refusal-hides-a-defect`: the mismatch may be an unrelated defect + that the refusal was masking). + +## Gate + +`cargo test -p ec-av1 --lib a_real_aomenc_palette_stream_with_8x8_leaves -- --nocapture` +(`EC_AV1_REQUIRE_AOMENC=1`, oracle `~/.cache/aom-oracle/build/aomenc`). +48 arms: {testsrc2, smptebars} x {8, 10} bit x cq {30,40,55} x +`--enable-tx-size-search` {0,1} x `--tile-columns` {0,1}, 128x128, +`--tune-content=screen --enable-palette=1 --min-partition-size=8 --limit=1` +(key frame; the inter frames of this recipe stop on OTHER lanes' open refusals: +non-DC chroma on an 8x8 inter leaf, inter 16x16 1:4 partitions). Every decoded +frame compared against ffmpeg, `out_of_scope_mismatch == 0` asserted. + +EVIDENCE: ~/.cache/pal8-tmp/gate.log (pre-lift run) + the run below | aomenc 48 arms, ec-av1 decode, ffmpeg compare per frame | 44 8x8-leaf palette block(s) across 24 arm(s), 47 arms compared (47 frames), 23 out of scope (0 mismatched), 1 refused (1 superblock-strip palette) -- test result: ok +EVIDENCE: gate rerun with the SB-strip refusal REMOVED | same 48 arms | `testsrc2-10bit-cq55-txs0-tc1 MISMATCH at frame 0`, test FAILED -- which is why that refusal stayed + +Before this change the same 8-bit recipe refused with "a block that actually +uses a palette (Y)": measured with `~/.cache/pal8-tmp/enc.sh` + `decode_probe` +on 12 streams before the fix. + +## Suite + +`$HOME/.cache/pal8-suite-r1.log` -- see the tail of this file / the lane report line.