forge
Explore
Log in

Don't you dare go Hollow

Commits

Commits on 64a504331da0060a8891309bda471da400f69bbe

2026-09-29

Merge lane-av1pixprobe: EC_AV1_PIXPROBE write probe + the byte-identical diffwtd_mask cast moveAhmet Kaan Gümüş · 64a5043
Merge lane-av1pixprobe: EC_AV1_PIXPROBE write probe + the byte-identical diffwtd_mask cast move

A: the env-gated EC_AV1_PIXPROBE=x,y one-sample write probe, re-anchored by hand because both mc
stores now live in PlaneBuf::reconstruct_mc_rect (row-at-a-time slices) - it reports w, not the old
branch's side, so rectangular inter blocks are not misreported. Fires on the pinned fixture
(sha256 bc699af4...) and prints nothing when unset.
B: the diffwtd_mask cast move with its byte-identity argued from the clamp (clamp(0,64) keeps m in
0..=64, so both the forward use and the 64 - m inverse are value-preserving), plus the compound
transcription gate over all 256 phase pairs at 8 and 10 bits; two mutations red it, one proving the
10-bit arm is exercised rather than skipped.
C is recorded, not investigated: the parked branch's 8x8-leaf miss DOES NOT REPRODUCE on merged main
(byte-exact vs ffmpeg at that coordinate on the same fixture; the measuring tree was 439 commits
stale), so the row now tells the next charter to re-measure first.
lane-av1pixprobe: land the EC_AV1_PIXPROBE rung re-anchored + diffwtd_mask's cast move and its 8/10-bit gateAhmet Kaan Gümüş · 4b28b49
lane-av1pixprobe: land the EC_AV1_PIXPROBE rung re-anchored + diffwtd_mask's cast move and its 8/10-bit gate

The two items lanes/av1cheapwins.report.md §C triaged "land after rebase".

A: the env-gated one-sample write probe from lane-av1-ibcwrite @ 25f5c729,
re-anchored by hand -- the branch's two mc store hunks no longer attach
because those stores now live in reconstruct_mc_rect (lane-perf4 /
lane-recoparse reshaped it: row-at-a-time slices, an early
residual.is_empty() return, and a w/h block extent with side demoted to the
prediction stride). pix_write("mc_copy"/"mc_add", x, y, w, ...) reports w,
not the branch's side, because that is what the block=(bx,by)+SIDE field
means for a rectangular inter block. Fires on the pinned R5 fixture
(sha256 bc699af4..., re-encoded here byte-identically) at px (296,128), three
stores one per plane; prints nothing with the variable unset.

B: 295dc3fe's u8 cast move in diffwtd_mask plus its 8/10-bit libaom
transcription gate. The cast is value-preserving: clamp(0,64) leaves m in
{0..=64}, so `as u8` is a no-op on the binding and both uses
(forward `m`, inverse `64 - m`, which is 1..=64) emit the same mask byte as
the old `m as u8` / `(64 - m) as u8` pair. The gate is the 10-bit coverage
diffwtd_mask's (bd - 8) term landed without; adapted to main's
blend_masked_compound, whose `subsampled: bool` is now subw/subh. Proven
non-vacuous at both depths, including a 10-bit-only round mutation that is
inert at 8-bit and still fails the gate.

C: the 189-vs-170 intrabc partition defect is recorded, not chased -- and
does not reproduce on merged main (the fixture decodes byte-exact vs ffmpeg
at 1d47ff54; the measuring tree 37a64d99 is 439 commits stale). The hand-off
row carries the original coordinates and numbers plus that caveat, so the
next charter re-bisects instead of trusting the coordinates.

Report: lanes/av1pixprobe.report.md
Merge lane-av1pinspec2: the count-vacuity scan is comment-aware and the SVT site is wire-derivedAhmet Kaan Gümüş · 20621b0
Merge lane-av1pinspec2: the count-vacuity scan is comment-aware and the SVT site is wire-derived

Sweep: 58 site(s); 58 spec-pinned by a prior assert, 0 not (ceiling 2 -> 1 -> 0, each step tied to
its commit's measured population, each with its own red-before). The SVT split-transform gate now
runs on a COMMITTED pin (svt1-split-tx-pin.obu, 1838 B, sha256 c9d9c0ae... - a replay of two
independent SVT-AV1 v3.1.2 encodes) instead of an env-named stream, and derives its frame count off
the wire with Av1Parser, asserting the show_existing_frame case impossible on this pin rather than
arguing it. Non-vacuity: runs unset on a stock box with no SKIP, and mutating the arm counter reds.
lanes: av1pinspec2 report -- the SVT crop is committable, and the ledger is emptyAhmet Kaan Gümüş · 9341fe5
lanes: av1pinspec2 report -- the SVT crop is committable, and the ledger is empty

Outcome (a) on the branch point: the crop IS committable, so the gate runs on a
stock box and its count comes off the wire. Records the recipe and the sha256,
why lane-svt1's own 6x5x6 search missed it (it ran four frames per stream and
the misses were on the inter frames; one key frame has none), how the
show_existing_frame over-count objection is settled by assertion rather than by
argument, and the measured non-vacuity (the premise reds at hits > 1, so the arm
fires exactly once).

Also records the failure the pin invariant caught: a comment of mine quoted the
callee spelling the pin scanner matches on, and the scanner read the prose as a
pin. The call is a literal on purpose, and the comment must not quote it.
Merge lane-av1cflac: the cfl_ac_q3_at 4:4:4 premise is REFUTED, and it is now guardedAhmet Kaan Gümüş · f82a113
Merge lane-av1cflac: the cfl_ac_q3_at 4:4:4 premise is REFUTED, and it is now guarded

The inherited '188 rung hits at 4:4:4' does not reproduce: 0 hits on all 26 *444* pins, while
cfl_ac_ss's own 4:4:4 arm fires 1834 times and is byte-exact vs aomdec. cfl_ac_ss dispatches 4:4:4
and 4:2:2 to their own libaom bodies BEFORE the 4:2:0 fallthrough that owns cfl_ac_q3_at, so the
halving and the 2x2 average are correct at every reachable call site (the 4:2:0 total on the same
counter is 33752 - where the 188 almost certainly came from). No decode behaviour change: two gates
(the 4:4:4 arm>0 AND cfl_ac_q3_at==0 on one counter with per-plane 0/0/0 vs aomdec; a static closure
proving cfl_ac_q3_at is reached only through the 4:2:0 fallthrough), an oracle_plane_diffs helper and
per-arm counters. Mutation reds the gate, and in its naive half-extent form it PANICS (len 16, index
16) rather than mis-colouring - correcting the inherited 'silent wrongness' framing.
gate_coverage: make the count-vacuity scan comment-aware, ceiling 1 -> 0Ahmet Kaan Gümüş · cefac45
gate_coverage: make the count-vacuity scan comment-aware, ceiling 1 -> 0

The last unpinned row in the ledger was not a count. It was a `///` doc
comment quoting the pre-r4 body of `pinned_lr_sgr_stream_call_unique_dump` --
prose about code, sitting inside the gate the prose describes, which already
spends FRAMES and asserts `pics.len() == FRAMES`. A line-based scan cannot
tell the two apart, so that row sat in the ledger for a whole round as an
unpinned count no reader could act on, and the ceiling could never reach 0.

`sites()` now skips lines whose trimmed start is `//`. Only the SITE scan
skips them: the pin-window walk still sees every line, because a `//`-led line
there is a comment BETWEEN an assert and its call, not a site.

A coverage change gets a coverage test, in the shape `pin_inventory` already
uses -- a SYNTHETIC source, not the live tree, because a fix to the very gate
that motivated this would otherwise delete the row that proves the scanner
works. Both halves are asserted, and the second is the one that matters:

  * half one: a count call inside a `///` doc comment is NOT a site. That is
    the real row this change removes.
  * half two, the control: the SAME call as real code IS still a site, still
    attributed to the right gate, and still PINNED by an assert above it. A
    scanner that skips comments by skipping the wrong thing is identical on
    half one, and a ceiling of 0 is exactly the state where an over-broad skip
    would go unnoticed.

count-vacuity sweep: 59 site(s); 58 spec-pinned, 1 not -> 58 site(s); 58
spec-pinned, 0 not. UNPINNED_CEILING 1 -> 0.

RED-BEFORE, both halves, with the skip removed and the ceiling at 0:

  test ...::a_doc_commented_count_call_is_not_a_site_but_real_code_still_is
    ... FAILED
  test ...::the_count_vacuity_sweep_finds_the_known_sites ... FAILED
  1 unpinned count site(s), ceiling is 0 -- a new one was added
  test result: FAILED. 1 passed; 2 failed

so neither half of this change can be reverted silently.
stream: run the SVT split-transform gate on a committed pin, count off the wireAhmet Kaan Gümüş · 1e73b1b
stream: run the SVT split-transform gate on a committed pin, count off the wire

`an_svt_screen_palette_block_with_a_split_transform_decodes_exactly` read its
stream from whatever `EC_AV1_SVT1_STREAM` named and SKIPped when that was
unset, so on a stock box it never ran -- and an oracle count that cannot be
pinned is the same defect as one that is not: the gate was handing ffmpeg the
length of our own decode as the expected frame count, with nothing on the box
able to prove the number wrong.

The crop is now committed: `crates/ec-av1/fixtures/svt1-split-tx-pin.obu`,
1838 bytes, sha256
c9d9c0ae934fba72fc9a9374bc36853f290796a8a4d6442140e239669e0b341f. It is a
REPLAY, not a fresh capture -- two independent encodes of

    ffmpeg -v error -f lavfi \
      -i "smptehdbars=s=192x152:r=12,drawgrid=w=8:h=8:t=1:c=black" \
      -frames:v 1 -c:v libsvtav1 -preset 8 -crf 50 \
      -svtav1-params "lp=1:screen-content-mode=1" -g 12 -f obu out.obu

produce those exact bytes (SVT-AV1 v3.1.2). `-frames:v 1` is the part lane-
svt1's own 6x5x6 search lacked: it ran FOUR frames per stream and the
~200k-sample misses that killed every candidate were on the INTER frames
(lanes/svt1.report.md). One key frame has no inter frames, and this one
reaches the fixed arm and is pixel-exact.

The count is derived from the WIRE, not from a literal: the gate parses the
pin's own OBUs with `Av1Parser` and asserts `decoded.len() == frame_headers`
BEFORE handing that number to the oracle. A header count would OVER-count a
stream carrying `show_existing_frame` (spec 5.9.5 codes no pixels, so the
header count exceeds the shown-frame count), so that case is asserted
impossible on this pin rather than assumed -- which is what makes "one header
== one shown frame" a checked fact here instead of an argument.

`EC_AV1_SVT1_STREAM` still overrides the pin for a re-capture, and
`crate_pin` is called with a string LITERAL on purpose: the pin inventory
scans for that spelling, and a const argument would leave this pin outside the
"every pin a gate reads is a committed crate-local copy" invariant.

Non-vacuity, measured: the gate runs on a stock box with the env var unset
(0.18s, no SKIP), and `skip_split_tx_override_hits() > 0` mutated to `> 1`
reds -- so the premise arm fires exactly once on this pin and the gate cannot
pass blind. The count assert mutated to `frame_headers + 1` reds with
"the stream codes 1 frame(s), the decode showed 1", which is also the proof
the wire count and the decode agree.

count-vacuity sweep: 59 site(s); 58 spec-pinned, 1 not -- the SVT gate no
longer spends a decode-derived `.len()` at all, so it leaves the population.
lane-av1cflac: cfl_ac_q3_at's 4:4:4 defect is UNREACHABLE; closed with two gates, no behaviour changeAhmet Kaan Gümüş · d6bb506
lane-av1cflac: cfl_ac_q3_at's 4:4:4 defect is UNREACHABLE; closed with two gates, no behaviour change

The inherited premise ("188 rung hits on the 4:4:4 set") does not reproduce.
The env-gated EC_HALVSWEEP rung, swept over all 26 *444* pins, prints 0 hits
on every one, while the 4:4:4 arm of cfl_ac_ss fires 1834 times across the
same fixtures and stays byte-exact against the oracle. cfl_ac_ss gives 4:4:4
(and 4:2:2) its own libaom-anchored body before the 4:2:0 fallthrough, so
bw/2, bh/2 and the 2x2 luma average are correct at every reachable call site.
The defect is real and latent, not live.

Landed instead of a fix:
- four per-arm CfL counters + a cfl_ac_q3_at entry counter, one per cfl_ac_ss
  arm, so the routing is measurable from outside the crate;
- gate cfl_ac_444_routes_to_its_own_1x1_luma_body_and_420_to_the_2x2_average:
  two pinned fixtures, two-sided (4:4:4 arm > 0 AND cfl_ac_q3_at == 0; 4:2:0
  cfl_ac_q3_at > 0), plus per-plane Y/U/V counts vs the instrumented aomdec via
  the new oracle_plane_diffs helper -- 0/0/0 on both;
- gate cfl_ac_q3_at_is_reached_only_through_the_420_fallthrough_of_cfl_ac_ss:
  the static closure, enumerating the call-site set (3 sites), the single
  caller of each decode-side wrapper, cfl_ac_ss's arm ORDER, and the absence
  of any 4:4:4 ColorConfig in the encoder.

No decode behaviour changes: 4:2:0 is bit-identical (>> ss == / 2 there), no
stream newly refuses, nothing stopped decoding. Mutation proof: routing the
4:4:4 arm into cfl_ac_q3_at reds the gate (and in its naive half-extent form
panics in the reconstruct path, not a silent colour shift); a fourth call site
reds the enumeration. Green restored byte-identical.

Sweep: 0/26 on the 4:4:4 set; 33752 cfl_ac_q3_at entries across 17 4:2:0
fixtures; 4:2:2 arm 0 on all 85. Report: lanes/av1cflac.report.md
Merge lane-av1cheapwins: GIT_DIR leak fix in the runner locator + oracle depth-assumption docsAhmet Kaan Gümüş · 66148c5
Merge lane-av1cheapwins: GIT_DIR leak fix in the runner locator + oracle depth-assumption docs

.cargo/config.toml: the runner locator's rev-parse now strips GIT_DIR/GIT_WORK_TREE/GIT_INDEX_FILE,
which a leaked GIT_DIR (e.g. git bisect run) otherwise lets resolve the test package dir - the
class behind exit 127 and GIT_DISCOVERY_ACROSS_FILESYSTEM in worktrees. Proven both directions:
five leak shapes go 127 -> 0 while the normal path is unchanged. scripts/instrument-aom-oracle.sh:
63 comment lines documenting the 1-byte-per-sample assumption on rungs 1/6/7/15 (rung 12 is the
only depth-aware one), with the AST check that no added line lands inside an emitted C string.
scripts: re-point the oracle DEPTH ASSUMPTION blocks at today's decode.rs linesAhmet Kaan Gümüş · 2562e2c
scripts: re-point the oracle DEPTH ASSUMPTION blocks at today's decode.rs lines

The four DEPTH ASSUMPTION blocks landed from 98d878d6 citing decoder-side
line numbers that have since drifted (decode.rs is 56341 lines; the cited
:35263 / :35336 / :35356 / :19734 and the "same at :53126 / :53048 /
:53148" duplicates no longer point at the narrowing code). A comment whose
whole job is "read this before you blame your decoder" must not point at
the wrong lines.

Re-verified every substantive claim against the current tree before
re-pointing, all still true:
  - rungs 1/6/7/15: fwrite(..., 1, w, f), no YV12_FLAG_HIGHBITDEPTH check
  - rung 12: the only depth-aware one (2 B for HBD, 1 B for 8-bit)
  - the decoder-side pairs really do narrow to u8 on purpose
    (dump_stage :20048-20054, dump_prefilter_wide :20078-20090; the
    duplicate narrow closures are at :35651 and :53489)

stream.rs:2129-2155 (rung 12's u16 LE writer) was already correct and is
left alone. Comments only -- still zero non-comment added lines, so the
emitted oracle C is byte-identical.
Merge lane-av1chromarect: 4:4:4 intra-BC rect-strip chroma is sized and walked per unitAhmet Kaan Gümüş · 972e329
Merge lane-av1chromarect: 4:4:4 intra-BC rect-strip chroma is sized and walked per unit

The premise that this needed a new chroma TxbSet was WRONG: libaom never forms a 64-point chroma
transform (av1_get_adjusted_tx_size maps TX_32X64/TX_64X32 -> TX_32X32 for plane != 0), so a 4:4:4
32x64 chroma plane block is TWO TX_32X32 units and TX_32X32 is already TxbSet::Chroma32. The missing
piece was the multi-unit WALK. Lands: ss-derived chroma extent and the eight MV origin pairs, a
per-unit chroma walk with neighbour stamping and covering-leaf tx_type inheritance, an ss(0,0)-only
hit counter, and the refusal gate replaced by a pixel-exactness gate with committed oracle floors.
Measured on r512.obu: 640727 wrong samples -> 79969 (-87.5%), luma byte-exact on all three frames,
frame 2 fully exact. Residual 79969 is named in the report, not hidden.
Merge lane-av1stagegaps: a staged suite can no longer run with its preflight unverifiedAhmet Kaan Gümüş · 5938e75
Merge lane-av1stagegaps: a staged suite can no longer run with its preflight unverified

scripts/check-aom-oracle-rungs.sh exits 3 (NOTRUN) when the prerequisite is absent instead of 1;
new scripts/av1-suite-preflight.sh gates both pieces (VERDICT=GREEN|WAIVED|BLOCKED, rung_check=not-run
waivable only via a named SUITE_RUNG_WAIVER) and scripts/av1-stage-suite.sh aborts before systemd-run
on a blocked verdict. Red-before: the old driver printed rungs_exit=1 ok_count=0 and ran === SUITE
anyway; green-after: BLOCKED, no unit created. Prerequisite named for host host-d: it carries
oracle binaries only, no libaom source at $AOM_ORACLE_SRC.
Merge lane-av1ignorereasons: every bare #[ignore] names its unblock (15 -> 0)Ahmet Kaan Gümüş · 892672a
Merge lane-av1ignorereasons: every bare #[ignore] names its unblock (15 -> 0)

All 15 were in ec-opus/tests/conformance.rs; attribute lines only, no test body touched. Three
gate-shaped bodies stay ignored with reasons recording that their blocker is the local media corpus
(or a body with no asserts), not a defect. Also records that the reelm@64k dropout the library gate
first failed on is fixed per lanes/opus-drop-r2.report.md.
stage(av1): a suite cannot start with its preflight unverifiedAhmet Kaan Gümüş · bede77e
stage(av1): a suite cannot start with its preflight unverified

Three hosts, three preflight realities, one identical green suite: host C
logged 'rungs_exit=1 ok_count=0' with no detail and ran anyway, host A ran
no preflight at all. 'Green suite' meant checker-passed, checker-failed and
no-checker-ran with equal confidence.

- check-aom-oracle-rungs.sh: exit 3 (NOTRUN) for an absent PREREQUISITE --
  no libaom source tree, base ref not in it, or a TMPDIR that does not
  exist. The measured cause on host-d is the absent source tree; the
  host carries build/ (binaries) and no src/. exit 1 keeps meaning FAIL.
- av1-suite-preflight.sh (new): runs both preflight pieces, prints every
  detail line of each, and emits one verdict. rung_check=not-run is
  waivable only via a non-empty SUITE_RUNG_WAIVER; an ABSENT checker is
  never waivable, which is the host-A defect. 8-case self-test.
- av1-stage-suite.sh (new): the gate under 'set -e' before systemd-run, so
  a blocked verdict creates no unit. Also refuses a non-git tree, an empty
  index (bare 'git init' makes every pin read uncommitted), and a missing
  lanes/*.expected.txt.

Lanes/av1stagegaps.report.md carries the reproduction, red-before /
green-after, the per-host audit of both running suites (test counts
unchanged), and the sentence the merge report can quote.
lane-av1ignorereasons: reason on all 15 bare #[ignore] in ec-opus conformanceAhmet Kaan Gümüş · c5351dd
lane-av1ignorereasons: reason on all 15 bare #[ignore] in ec-opus conformance

Every bare #[ignore] in crates/ lives in crates/ec-opus/tests/conformance.rs.
Each now names its unblock instead of being indistinguishable from a lost gate.

Nothing un-ignored: the three gate-shaped bodies are blocked on the local media
corpus, not on a defect.
- encoder_library_gate_vs_libopus: the reelm@64k dropout that first failed it is
  fixed (lanes/opus-drop-r2.report.md, 0 ours-only dropouts on 14 rows), but the
  sweep is a ~12 min ffmpeg libopus run over a local music corpus and SKIPs
  missing sources, so un-ignoring would leave a 6-of-7-row gate.
- silk_library_gate_vs_libopus: hard-asserts a local source wav that is no
  longer present on this host.
- celt_click_peak_offset: ran it, +120 samples at 32/64/128k, but zero asserts.

Suite: 63 passed, 16 ignored (reasons now printed). cargo check --all-targets clean.
4:4:4 chroma plane block at the 128-root intra-BC strip: walk it in get_vartx_max_txsize units, and do not overwrite the per-unit contextsAhmet Kaan Gümüş · b88c866
4:4:4 chroma plane block at the 128-root intra-BC strip: walk it in
get_vartx_max_txsize units, and do not overwrite the per-unit contexts

Commit 1 landed the ss-derived extent and then REFUSED the witness with "a
rectangular inter chroma transform unit whose shape has no coefficient table set
here". That refusal named the shape this crate HANDED
`rect_inter_chroma_set`, not the shape libaom codes, and acting on it literally
-- a new `ChromaRect32x64` / `ChromaRect64x32` -- would have shipped a
coefficient table no bitstream can ever exercise.

libaom never forms a 64-point CHROMA transform:
  * `get_vartx_max_txsize` (blockd.h:1447) returns
    `av1_get_adjusted_tx_size(max_txsize_rect_lookup[bsize])` for `plane != 0`;
  * `av1_get_adjusted_tx_size` maps `TX_32X64 -> TX_32X32` and
    `TX_64X32 -> TX_32X32`;
  * `max_txsize_rect_lookup[BLOCK_SIZES_ALL]` (common_data.h:126) has
    `BLOCK_32X64 -> TX_32X64`;
  * `decode_token_recon_block` (decodeframe.c:994-1004) steps the plane block
    by that size's mi units, and `decode_reconstruct_tx`'s
    `tx_size == plane_tx_size || plane` arm never recurses for chroma.

So a 4:4:4 32x64 chroma plane block is TWO stacked `TX_32X32` units, each with
its own eob, scan and coefficient context -- `rect_inter_chroma_set(32, 32)` is
already `TxbSet::Chroma32` (decode.rs:28919, arm lane-av1-444 added). What was
missing was the WALK, not a set, and no `rect_scan` / rect
`base_ctx_rect` / `br_ctx_rect` change is needed either: a `TX_32X32` unit is
square, so `read_inter_plane_rect` takes its `(cw, ch) == (32, 32)` branch and
reads `default_scan(TX32)`.

New `read_intrabc_rect_chroma_split`: the same
`(cw.min(32), ch.min(32))` / `nx * ny` tiling `read_inter_rect_chroma` already
does for the other rect paths, entered ONLY when the plane block needs more
than one unit, so 4:2:0 and every 4:4:4 shape below 64 keep the caller's own
one-unit read byte-for-byte. Per unit: its own `around_mi_rect` gather, origin,
prediction slice, `covering_leaf_tx_type` inheritance (`av1_get_tx_type`,
blockd.h:1287), the `get_txb_ctx` plus-10 offset, and `record_mi_chroma`
immediately.

New `record_split_luma_rect_mi_modes` / `record_rect_mi_luma_only`, extracted
from the existing pair: when the chroma plane block was walked as several
units, the whole-block coefficient stamp would overwrite the per-unit spans
with one state (the `override-slot-on-one-arm` class -- the same reason the
lossless arm sets `mu_chroma = true`). Gated on `!skip`: a skipped strip reads
no chroma unit at all, so the whole-block stamp is still its only one.

MEASURED, same oracle (aomdec `EC_AV1_FINAL_DUMP` vs `set_final_dump_prefix`,
512x512 8-bit 4:4:4, decode order), wrong samples per frame:

              before            after
  f0  Y  166229 -> 0     |  U 155383 -> 7488   |  V 153498 -> 8128
  f1  Y       0 -> 0     |  U  74708 -> 22571  |  V  73501 -> 41782
  f2  Y       0 -> 0     |  U   9216 -> 0      |  V   8192 -> 0

640727 wrong samples -> 79969. Luma is byte-exact on all three frames and frame
2 is byte-exact on all three planes. The refusal string is gone from this
witness because nothing reaches it, not because it was deleted: the string is
still at decode.rs:28938 and in refusal_inventory.rs:55, and
`every_rect_transform_shape_the_census_lists_has_a_coefficient_table_and_scan`
still passes.

Gate `a_444_intrabc_owned_rect_strip_refuses_the_missing_rect_chroma_
coefficient_set` (commit 1) is replaced by
`a_444_intrabc_owned_rect_strip_sizes_its_chroma_plane_block_and_decodes`: a
per-(frame, plane) exact prefix against the oracle, plus
`IBC_OWNED_RECT_CHROMA_FOOTPRINT_444_HITS == 5` as the non-vacuity proof. The
prefixes are floors, not an exactness claim -- the frames 0/1 chroma tail is an
OPEN fork at a site this lane did not identify, measured and named in
lanes/av1chromarect.report.md.

Mutation proofs, each reverted:
  M1 extent back to `/ 2`                       -> RED, counter 6 != 5
  M3 `(nx, ny)` transposed                      -> RED, f0 Y diverges at 65728
  M5 per-unit chroma row origin dropped         -> RED, f0 U diverges at 65696
  M4 prediction slice column term dropped       -> GREEN (nx == 1 here, term dead)

Gates: 33/33 on the 4:4:4-lossless + intrabc_rect + 4:2:0-twin set. The wider
`rect intrabc ibc chroma 444 420 subsampl` family is 138 passed / 0 failed / 5
ignored on this tip against 137 / 0 / 5 on the base `edffad9e`, the set
difference being exactly this lane's new gate.
Merge lane-av1pinspec: 41 of 43 unpinned count sites spec-pinned, ceiling 43 -> 2Ahmet Kaan Gümüş · b6966d6
Merge lane-av1pinspec: 41 of 43 unpinned count sites spec-pinned, ceiling 43 -> 2

Sweep unchanged in population (60 sites, floor 40 intact) and now reads 58 spec-pinned, 2 not.
Per-group red-before (un-apply one group -> the real guard reds) and six value mutations, one per
derivation shape, each printing the decoded count. Handed forward: the SVT gate site (stream named
by env, not a committed pin, so a wire-header assert would ship unexercised) and one doc-comment
false positive the line-based scanner cannot tell from code.
scripts: document the 1-byte-per-sample depth assumption on oracle dump rungs 1/6/7/15Ahmet Kaan Gümüş · e6e5fdc
scripts: document the 1-byte-per-sample depth assumption on oracle dump rungs 1/6/7/15

Comments only -- no emitted byte changes. Each of the four rungs that
fwrite(..., 1, w, f) with no YV12_FLAG_HIGHBITDEPTH check now carries a
DEPTH ASSUMPTION block naming the decoder-side dump it is byte-paired
with (which narrows to u8 on purpose) and rung 12 EC_AV1_FINAL_DUMP as
the depth-correct HBD alternative. The file header and the rung-12
summary point at those blocks so the trap is visible without opening a
rung.

Measured on the shared HBD oracle build with the committed
av112bit-key.obu (160x128 4:2:0 12-bit, 30720 samples): rung 12 writes
61440 B (w*h*bps) while the four 1-byte rungs SIGSEGV inside fwrite
(exit 139) and, where the write survives, would emit 30720 B -- exactly
half, which reads like a truncated decode.

2026-09-25

ec-av1: ignore leaked GIT_DIR when the test runner locates the repoAhmet Kaan Gümüş · df78a6b
ec-av1: ignore leaked GIT_DIR when the test runner locates the repo

git bisect run exports GIT_DIR. The runner's rev-parse then resolved the test package dir and exited 127.

2026-09-29

lanes: av1pinspec report -- 41 of 43 unpinned count sites pinned, ceiling 43 -> 2Ahmet Kaan Gümüş · 5184128
lanes: av1pinspec report -- 41 of 43 unpinned count sites pinned, ceiling 43 -> 2

The 43-row table with the per-site classification, the six derivations each
asserted value comes from, the per-group red-before (the guard's own message
for each of the eight stream.rs commits) and the six-gate value mutation that
shows the new asserts bite -- and, in its 'decode showed' column, that the
values came out of the encode recipe rather than the decode.

Also records the two failures this lane hit and what caught them: a
 split that put the narrow-kernel assert inside a
refusal arm where it would only run on arms the gate had already declined to
compare, and the global pre-commit rustfmt hook re-wrapping two asserts.
gate_coverage: lower the count-vacuity unpinned ceiling 43 -> 2Ahmet Kaan Gümüş · fbed1b6
gate_coverage: lower the count-vacuity unpinned ceiling 43 -> 2

The number the nine stream.rs commits above bring it to, with the two that
survive the round named in the comment. Neither is a count to fix:

  * an_svt_screen_palette_block_with_a_split_transform_decodes_exactly reads
    its stream from the path EC_AV1_SVT1_STREAM names, and that crop is not
    committed to fixtures/ -- so no encode recipe, no --limit, no -frames:v and
    no frame count exists anywhere in the tree for it. The doc comment's
    "12-frame stream" is prose about one capture, and the env var accepts any
    file, so asserting 12 would pin a number nothing can check. Deriving one
    from the stream's own OBU frame headers is left on the table deliberately:
    the gate SKIPs on any box without that env var, so such an assert would
    ship unexercised.
  * the second is a '///' doc comment quoting the pre-r4 body of
    pinned_lr_sgr_stream_call_unique_dump -- the sweep's line-based scan cannot
    tell a doc comment from code. The gate it describes already spends FRAMES
    and asserts pics.len() == FRAMES.

The floor (>= 40 sites) is untouched and the site population is unchanged at
60: the fixes assert the encode's count ABOVE the call rather than spending a
named constant in place of .len(), so each site moves from "not spec-pinned"
to "spec-pinned by a prior assert" instead of vanishing from the class. 41
sites become pinned and 43 - 41 = 2 remain.

Red-before for all 41 at once: with this ceiling and stream.rs reverted to
3b691e13, the guard reds with "43 unpinned count site(s), ceiling is 2". Since
each fix removes exactly one site from the unpinned population, removing any
one of the 41 asserts puts unpinned at 3 and reds this same assert.
Merge lane-av1w3erefute: wave-3e refutation (3 PASS by mutation) + the unexercised-matcher class closedAhmet Kaan Gümüş · 44a0cfb
Merge lane-av1w3erefute: wave-3e refutation (3 PASS by mutation) + the unexercised-matcher class closed

Nine dead matcher spellings deleted, the matcher tables single-sourced as pub consts, and a
positive control (every_scanner_matcher_fires_on_a_known_site) that iterates those same consts
so a matcher cannot be added without a control that must pass. Sweep unchanged at 60/17/43 --
the proof the deletions cost no coverage. C1's '30 fires / 2555904 samples' is recorded as
author-reported and NOT reproduced; the verified claim is the weaker 38/38-green one.
test(av1): give every count-vacuity scanner matcher a positive controlAhmet Kaan Gümüş · 91a96ff
test(av1): give every count-vacuity scanner matcher a positive control

The wave-3e refutation of the pins5 guard turned up a class the sweep's own
floor could not see: an UNEXERCISED MATCHER IN A SOURCE SCANNER. The floor
(s.len() >= 40) and the unpinned ceiling (43) both catch a LOST shape.
Nothing caught a matcher that has never fired, so the scanner advertised
coverage it did not have.

Measured every matcher in count_vacuity against the real scan target:

  ffmpeg_decode_sequence_444( -- NOT dead, my first read was wrong. It fires
  on five stream.rs gates (7030, 7545, 7735, 8439, 11643) and produces no
  count-vacuity SITE only because all five pass the spec const FRAMES rather
  than a decode-derived .len(). KEPT, with that reason recorded at the const.

  Nine spellings that fire on nothing anywhere in the crate -- DELETED, each
  with grep evidence that the string occurs nowhere outside the matcher table,
  so there is no hypothetical caller to name and no coverage is lost:
    diagnostic                          (probe substring, 0 fns)
    the_chroma_rect_gates, restore_gate,
    cdef_gate, superres_gate,
    grain_gate, sgate                   (encode helpers, 0 fn bodies)
    NFRAMES, frames_expected            (spec bindings, 0 fn bodies)

All tables are now single-sourced pub consts (CALLEES, PROBE_SUBSTRINGS,
ENC_HELPERS, FIXABLE_CANDS, AOMENC_LEAF, DISK_READ_LEAVES, PIN_WINDOW) and
every_scanner_matcher_fires_on_a_known_site iterates those same consts, so a
matcher cannot be added later without a control that has to pass. The brace
walk is extracted from sites() into fn_body_end so the control measures the
EXACT slice the scanner classifies with (control-and-measurement-drift).

Mutation: re-adding "sgate" to ENC_HELPERS reds the control --
  the encode-helper matcher `sgate(` matches NO fn body in stream.rs -- it is
  dead coverage (grep the crate: ...)
Restored, control ok.

The sweep is UNCHANGED, which is the proof the deletions cost nothing:
  count-vacuity sweep: 60 site(s); 17 spec-pinned by a prior assert, 43 not
  test result: ok. 3 passed; 0 failed
stream: pin eight single-key-frame oracle counts, three of them by hoistingAhmet Kaan Gümüş · 222f4c5
stream: pin eight single-key-frame oracle counts, three of them by hoisting

Five of these gates already carried 'assert_eq!(frames.len(), 1)' but BELOW
the ffmpeg call, which is exactly why the sweep still read them as unpinned:
by the time the assert ran, the oracle had already been handed frames.len().
Hoisted above the call they are what they were meant to be -- a check on the
encode, taken before the budget is spent. The chroma-edge-filter gate's assert
is hoisted past both the 8-bit and the 10-bit arm, so one assert covers both
of its sites.

count-vacuity sweep: 25 unpinned -> 17.
stream: pin four more oracle counts, one of them off the wire itselfAhmet Kaan Gümüş · 31ca760
stream: pin four more oracle counts, one of them off the wire itself

a_real_aomenc_stream_with_cdf_update_disabled is the one site whose spec is
NOT a literal: the arm overrides screen_intrabc_stream_at_depth's '--limit=1'
with '--limit=3', and aomenc keeps the LAST occurrence of a repeated flag, so
'3' would be a claim about flag precedence rather than a fact about a stream.
The gate already parses this stream's own OBU frame headers with Av1Parser in
the loop sitting above the call, so the assert compares frames.len() against
that header count -- derived from the bitstream, not from a rule and not from
our decode. The mutation run in the lane report prints both sides (3 vs 4),
so the pin is shown to bite.

Also pins the rect-strip-palette gate, whose 'no frame-count assert here'
comment is deleted: frames.len() == 1 is a fact about the encode, taken before
frames.len() is spent as ffmpeg's budget, so it was never the tautology that
comment described -- and ten_bit_tool_gate, whose count is its own 'frames'
PARAMETER, the same value handed to encode_10bit_gradients_seed: 1 for the
key-frame callers, 24 for the --lag-in-frames=16 inter ones.

count-vacuity sweep: 29 unpinned -> 25.
stream: hoist the narrow-kernel gate's FRAMES assert above its oracle callAhmet Kaan Gümüş · 6e9d8a0
stream: hoist the narrow-kernel gate's FRAMES assert above its oracle call

a_real_aomenc_rect_inter_block_predicts_chroma_with_the_narrow_kernel already
had the right assert -- frames.len() == FRAMES, with 'const FRAMES: usize = 6'
driving both '-vframes {FRAMES}' and '--limit={FRAMES}' -- but BELOW the call,
so the oracle had already been handed frames.len(). Hoisted, not duplicated.

The 'rect_narrow_kern_hits()' read stays where it was, above the call, so a
mismatch report still says whether the arm fired; a first attempt at this edit
moved the assert above that read and dropped the binding, which would have left
the failure message unable to name the arm's hit count.

count-vacuity sweep: 5 unpinned -> 4.
stream: pin the band and chroma-rect sweep family to one frame eachAhmet Kaan Gümüş · a2f865b
stream: pin the band and chroma-rect sweep family to one frame each

Four gates, eight sites: the 4:1/sub8 rect-chroma gate, the excluded-seed-46
chroma-rect gate, the seed-46 band stream gate, and the frame-edge-partition-bit
gate. The first three encode through rectchroma_stream or its byte-identical
inline twin -- 'duration=0.04:rate=25' rendered with '-t 0.04', one frame, no
'--limit' -- and the fourth renders with '-t 1' AND '-vframes 1'. One assert
per gate sits above the depth branch, so it covers both the 8-bit and the
10-bit site.

count-vacuity sweep: 13 unpinned -> 5.
stream: pin the restoration sweep and edge32_gate, whose spec is a parameterAhmet Kaan Gümüş · ae84402
stream: pin the restoration sweep and edge32_gate, whose spec is a parameter

a_real_aomenc_stream_with_restoration_reads_lr_symbols_correctly: every
EC_FISTRIP_SRC branch and the gradients_source default render at rate 25 with
a 1-frame duration=0.04, and aomenc runs with no '--limit', so each attempt's
stream codes 1 frame. This gate had NO frame-count assert at all -- not even
the tautological one -- so its zip over pics and reference would have
truncated silently on a short decode.

edge32_gate's count is PER ARM: the arm tuple's frame_count field is what the
y4m is built from (duration = frame_count / 25.0) and aomenc runs with neither
'--limit' nor '--lag-in-frames', so 1 for the intra arms and 5 for the
inter/straddling ones. Asserting against that field is a spec rather than a
literal and is already in scope at the call, which is why this is a pin and
not a hand-forward.

count-vacuity sweep: 15 unpinned -> 13.
stream: pin the ignored rect-tx recipe sweep and the 32-level AB gateAhmet Kaan Gümüş · f9d88f7
stream: pin the ignored rect-tx recipe sweep and the 32-level AB gate

sweep_rectx_recipes asserts no verdict -- it counts mismatching frames and
prints an 8x8 map -- but that COUNT is the number it reports, so a decode that
showed fewer frames than the wire would silently under-report it. Pinned
against '-vframes 1' like every other arm in that sweep, and the gate still
runs only under --ignored.

a_real_aomenc_stream_with_a_32_level_ab_partition renders
'gradients_source(..., duration=0.04:rate=25)' with '-frames:v 1' and runs
aomenc with '--limit=1 --kf-max-dist=0', so all 16 seeds code 1 frame.

count-vacuity sweep: 17 unpinned -> 15.
stream: pin the encode's frame count in the intrabc rect/census familyAhmet Kaan Gümüş · 8644bc7
stream: pin the encode's frame count in the intrabc rect/census family

Seven sites across the coded-rect-intrabc gate (both the arms and skip_arms
loops), the sb128 screen intrabc gate, the two intrabc censuses, the mixed
vart-tx tree gate and the tx-mode-select gate. All encode through
screen_intrabc_stream_at_depth, which renders '-t 0.2' at rate 25 with
'-vf tile=2x2' (5 frames in, 1 tiled frame out) and runs aomenc with
'--limit=1', so every arm codes exactly 1 frame.

The two censuses are report-only about their COUNTS, but their Ok arms assert
pixel-exactness, so the budget handed to ffmpeg there is pinned for the same
reason as everywhere else. The skip_arms loop re-decodes the same bytes at
each recon-thread count, so one assert covers both of that loop's sites.

count-vacuity sweep: 36 unpinned -> 29.
stream: pin the encode's frame count above 7 oracle calls (palette, rect-tx tool, screen intrabc, 16x4 pair)Ahmet Kaan Gümüş · 6867062
stream: pin the encode's frame count above 7 oracle calls (palette, rect-tx tool, screen intrabc, 16x4 pair)

These seven count sites handed ffmpeg_decode_sequence{,_10bit} the length of
OUR OWN decode as the oracle's expected frame count. A decode that showed
fewer frames therefore asked ffmpeg for the same short count, and the helper's
byte-length assert fired naming ffmpeg for a number our decoder chose. The
count is now asserted against the ENCODE -- '-frames:v 1', '-vframes 1',
'--limit=1', or 'rate=25 x -t 0.60' = 15 for rect_tx_tool_gate -- and that
assert sits ABOVE the call, so a dropped frame reds naming the encode.

Three of the seven already carried the literal but BELOW the call, where the
oracle had already been handed frames.len(); those are hoisted, not
duplicated. rect_tx_tool_gate is the one multi-frame site and the count is
named, since 15 comes from an arithmetic fact about the fixture
(rate 25 x -t 0.60) rather than from a flag someone typed.

count-vacuity sweep: 43 unpinned -> 36. The call still spends frames.len();
the assert above makes that value a spec, which is the shape the 17
already-pinned sites use, so the site population stays 60 and the class stays
enumerable.
4:4:4 witness pin + ss-derived chroma extent at the 128-root intra-BC stripAhmet Kaan Gümüş · 287d79c
4:4:4 witness pin + ss-derived chroma extent at the 128-root intra-BC strip

Pins crates/ec-av1/fixtures/r512.obu (6948 B, blob bff992e9, taken from
lane-chromahalvings-r3 -- the only one of the three chromahalvings refs
that carries it) and replaces `decode_intrabc_owned_rect`'s hardcoded
`(bw / 2, bh / 2)` chroma extent and its eight `px / 2, py / 2` chroma MV
origin pairs with the ss-derived `>> ss_x` / `>> ss_y` forms.

libaom: `av1_get_max_uv_txsize` (blockd.h:1372) is
`max_txsize_rect_lookup[get_plane_block_size(bsize, ss_x, ss_y)]` through
`av1_get_adjusted_tx_size`, and `get_plane_block_size` is
`ss_size_lookup[bsize]` -- at ss (0,0) the chroma plane block IS the
luma footprint. At 4:2:0 the two forms are the same arithmetic.

RED-BEFORE, measured on the UNPATCHED line in this worktree, per-plane
sample counts against the instrumented aomdec (`EC_AV1_FINAL_DUMP`):

  f0  Y 166229 wrong from 65728 | U 155383 from 32848 | V 153498 from 32848
  f1  Y       0 (byte-exact)   | U 74708 from 49282  | V 73501 from 49280
  f2  Y       0 (byte-exact)   | U  9216 from 114880 | V  8192 from 229760

Luma byte-exact on f1 and f2 while chroma is wrong is the signature that
makes this a chroma-plane sizing defect and not a block-geometry one.

New counter IBC_OWNED_RECT_CHROMA_FOOTPRINT_444_HITS: the 128-root
intra-BC strips whose chroma plane block was sized at ss (0,0). At 4:2:0
the corrected and halving forms are identical, so >= 1 cannot be
satisfied by a 4:2:0 stream; the arm is exclusive to this function.

Gate `a_444_intrabc_owned_rect_strip_refuses_the_missing_rect_chroma_
coefficient_set` asserts -- deliberately -- that the witness is now
REFUSED with the exact string "a rectangular inter chroma transform unit
whose shape has no coefficient table set here". That is the state this
commit lands in: the extent is libaom-correct, and a 4:4:4 32x64 luma
block's chroma plane block is 32x64, which this crate has no
`TxbSet` for. The gate exists so the day that arm lands the gate goes RED
and the assertion has to become the pixel-exactness check. Reach proof
for the site, on the whole witness with EC_HALVSWEEP=1: 5 strips
(mi 32x64 skip=false at mi(32,40); 32x64 skip=true at mi(48,64); 16x64
skip=true at mi(64,108); 32x64 skip=true at mi(112,96) and mi(112,104)).
Merge lane-chromahalvings-r5: EC_HALVSWEEP rungs + the 4:4:4 intrabc rect blocker reportAhmet Kaan Gümüş · ecb98e2
Merge lane-chromahalvings-r5: EC_HALVSWEEP rungs + the 4:4:4 intrabc rect blocker report

The 4:4:4 lossy witness, its chroma-only red-before and the exact refusal string are recorded
so the next lane starts warm. The fix needs a chroma TxbSet (ChromaRect32x64/ChromaRect64x32)
this crate lacks, so the halving is left in place deliberately: turning a decoding stream into
a refusal is a behaviour change with its own decision.
chroma halvings r5: rebased on 3b691e13; item (3) already fixed by C1, item (2) confirmed still deferredAhmet Kaan Gümüş · 26946b2
chroma halvings r5: rebased on 3b691e13; item (3) already fixed by C1, item (2) confirmed still deferred

Two of the three chartered items change status on the rebase, and both changes
are retractions in this lane's favour.

ITEM (3) suppress_internal_lf_edges -- ALREADY FIXED by Agent09-4's C1. On
3b691e13 the function now takes fctx and reads
  ((w_mi * MI) >> ss_x(fctx)).max(4), ((h_mi * MI) >> ss_y(fctx)).max(4)
which is exactly the fix r1/r2 chartered. The r1/r2 claim that this site is
"format-blind today, a structural constraint" was true of f33b9d41 and is
FALSE of current main. Retracted.

ITEM (2) cfl_ac_q3_at -- still format-blind, now with a measured reason
rather than an assumption. Post-rebase the signature is still
  fn cfl_ac_q3_at(px, py, bw, bh, sample) -> Vec<i32>
with `let (cw, ch) = (bw / 2, bh / 2);` at 19957 and no fctx, so the
subsampling cannot be derived inside the function. The witness is real (188
rung hits on the 4:4:4 set); what is missing is only the threading through
the CfL call tree plus a CfL-specific pixel gate. Deferred with that reason.

ITEM (1) -- the ChromaRect32x64 / ChromaRect64x32 coefficient sets and the
ss-derived extent -- NOT STARTED. Witness committed, red-before measured, the
refusal string exact, and the remaining work is real engineering rather than a
swap: a CDF set per shape, its rect_scan, and the rect forms of
base_ctx_rect/br_ctx_rect, following lane-inter4's precedent for the rect
inter sets. Shipping a partial version would put a silent wrongness into the
tree, which is the outcome this lane has been removing. Unblock order is in
the report.

decode_intra_sub8_leaf (decode.rs:45340, body 45340..46168) RECORDED as a
named gap: it takes has_chroma: bool and has NO chroma_444 branch and NO
chroma_422 branch -- a single chroma path, so at 4:4:4 it computes the 4:2:0
geometry and 4:2:2 has no path at all. Callers: decode.rs:44470 and
decode.rs:46356, both passing has_chroma. Not implemented: the 4:2:2 lift
needs the shape, but this lane has no 4:2:2 witness (the decoder refuses 4:2:2
by name at the sequence header), so a fix here would be unmeasured.

The stale-binary tell is written into the report: a green gate result
alongside a target that does not compile is a stale binary, and
`git checkout <branch> -- <file>` is what produces it. It bit this lane twice
in one turn. Any --no-run error that coincides with green gates invalidates
every gate result in that turn.
lanes: wave-3e report final -- chromahalvings deferred, ref hazard closedAhmet Kaan Gümüş · d9e6745
lanes: wave-3e report final -- chromahalvings deferred, ref hazard closed

Adds what the wave's second pass measured: the intra-in-inter family (7/0
with the oracle forced on) covering the 305-line decode.rs delta, the
libtest pattern-semantics note (four positional filters are a union of
substrings, not four module selectors -- 42 and 43 are per-module sums, the
combined run is smaller), and the promotion of the cmp-byte-identical
diff-vs-branch technique as the standing form of the foreign-file check:
--stat proves the file SET, cmp on the two diffs is what proves the hunks.

lane-chromahalvings is deferred(next wave): 69e80133 says "none fixed here"
and is five merges stale, so there is no region to resolve yet. The
decode_intrabc_owned_rect bw/2, bh/2 line stays untouched for its witness.

Main has repointed lane-av1txsizeaudit to c0727d64; it is now an ancestor of
main and the ref hazard section 4 documented is closed.
lanes: wave-3e report -- pins5 and txsizeaudit merged, chromahalvings heldAhmet Kaan Gümüş · e03cd90
lanes: wave-3e report -- pins5 and txsizeaudit merged, chromahalvings held

7ec417ad merges lane-av1pins5 (e1f78b8e), 5f39325d merges
lane-av1txsizeaudit-r5 (c0727d64). Both predicted clean by merge-tree and
both clean in fact; cargo check 0 warnings after each; the four guard
families read 18/0, 20/0, 2/0, 3/0 on the merged tree with sources touched
first. Shape checks: each merge's diff against its first parent is
byte-identical to the branch delta, and the per-file removal counts match
the branch one-for-one.

Recorded: the ref `lane-av1txsizeaudit` points at dc80b6fa, a divergent
pre-rebase line 67 files and -13617 lines away, not at the merged
c0727d64 -- merging it by name would have conflicted and landed an ancient
decode.rs. The sha was merged instead.

lane-chromahalvings is held: 69e80133 says "none fixed here" and is five
merges stale. decode_intrabc_owned_rect's bw/2, bh/2 region was left
untouched for its witness.
Merge commit 'c0727d64'Ahmet Kaan Gümüş · a1b35a5Browse files
lanes/av1txsizeaudit r5: re-rebase onto ec4e9528, declare provenance of the foreign workAhmet Kaan Gümüş · 4e9b008
lanes/av1txsizeaudit r5: re-rebase onto ec4e9528, declare provenance of the foreign work

PROVENANCE, declared before wave 3e rather than at merge time. This branch
carries TWO lanes' work, not one.

  lane-av1txsizeaudit (this lane): the tx-size audit, the C1 fix + source-scan
  gate, the av1tilerows retraction.
  lane-av1ibc128arm, commit 4bfe8d8e "av1: 4:4:4 intra-in-inter 128-root
  mu-chunk chroma as a per-unit walk": 279 lines of decode.rs, 192 of
  stream.rs, 5 of examples/decode_probe.rs, 196 of lanes/av1ibc128arm.report.md
  -- and it has NEVER been merged to main.

Three checks against main:
  git merge-base --is-ancestor 4bfe8d8e main  -> NO
  git grep -c 'a_real_aomenc_444_intra_in_inter_128_root_codes_chroma_per_mu_chunk'
      main -- crates/ec-av1/src/stream.rs    -> 0
  git grep -n 'luma_span = cu_tx * 2' main -- crates/ec-av1/src/decode.rs
                                            -> main:...:43185

That last line is the proof of non-merge rather than a re-implementation: main
still carries the collapsed 4:2:0 arm verbatim -- `let luma_span = cu_tx * 2;`
-- which is exactly the line 4bfe8d8e deletes, and the string appears 0 times
on this branch. `git log --all -S"luma_span = cu_tx * 2"` finds only the two
lanes that CREATED the class (2050a065 lane-av1-ibc128chunk, 29550383
lane-av1-422bigblock) and the commit that removed it. `git grep -ln
"intra_in_inter_128_root" main -- lanes/` returns nothing, and
`git cat-file -e main:lanes/av1ibc128arm.report.md` fails -- so no other lane's
report claims it. Branch lane-av1ibc128arm still exists at 4bfe8d8e, so this is
not an orphan.

THE TWO FOREIGN REPORT FILES, individually:
 - lanes/av1ibc128arm.report.md (+196): deliberately KEPT, and it belongs to
   lane-av1ibc128arm, not to this lane. It is the only provenance record for
   the 279-line decode.rs change and the 4:4:4 gate. Not cherry-pick residue:
   it arrived with 4bfe8d8e whole. MERGE OWNER: if lane-av1ibc128arm is also
   merged, take code+report from whichever lands first and drop the duplicate;
   if it is not merged separately, this branch must carry it, because there is
   no other copy.
 - lanes/av1tilerows.report.md (38 changed): MINE and deliberate. The retraction
   of the `cu_tx = 32 << ss_x` rule at that report's own origin (lines 265-281,
   the section 8 "Recommendation") -- the one committed instance of the refuted
   rule in the repo. Zero code, zero gate. It must land whenever this branch
   lands or the rule stays re-derivable.

CONTENTION HANDED OVER, NOT PRE-RESOLVED: decode_intrabc_owned_rect's `let
(cw, ch) = (bw / 2, bh / 2);` -- the open cell this report lists at 2.3 and
5.0, line 16832 on this base -- is being fixed by another lane now. This branch
does not touch that line; it appears here only as a finding. Resolve at merge
there, where the witness lives.

RE-REBASE, and a second patch-base trap in the same family as r4's:
r4 nearly dropped the unmerged fix commit by patching from "my base"; r5 nearly
swept in all of main's wave-3 changes by patching from "the old main" 9b2f6c9d,
which produced an 18041-line patch touching crates/ec-aac and binary fixtures.
THE RULE, both times: the patch's left-hand side must be the commit this
branch's base actually is (git merge-base HEAD main) -- never a remembered
ancestor, never a self-describing "my base". Verify with `git apply --stat`
BEFORE applying; the wrong base names files you have never touched and is
invisible in --3way's exit status.

Correct patch: git diff 08f8ffb3 99f25b1f, 1894 lines, 7 files. Applied onto
ec4e9528:

  git diff ec4e9528 --shortstat -> 7 files, 1671 insertions(+), 103 deletions(-)

identical in shape to the pre-rebase measurement, with per-file removed-line
counts unchanged (decode.rs 97, av1tilerows 6, rest 0). Main's move touched
NOTHING under crates/ec-av1/, so decode.rs is 56316 lines with
suppress_internal_lf_edges at 9277 and C2 at 43315 -- report section 5.0's
line-shift table is valid verbatim on this base, no adjustment. Silent-restore
check against this move: 0/0/0.

Re-run after touch: cargo check --all-targets clean; the new source-scan gate
1/1; gate_coverage 13/13; refusal_inventory 20/20; the 13-gate identity set
13/13. 47 tests, 0 failures, 4:4:4 gate present and green.
Merge branch 'lane-av1pins5'Ahmet Kaan Gümüş · 46d3571Browse files
test(av1): generalise the count-vacuity guard, and hand the 43-site ledger forwardAhmet Kaan Gümüş · 9c0e824
test(av1): generalise the count-vacuity guard, and hand the 43-site ledger forward

Rebased onto main 97b4ee04. The preflight lane had independently landed the r5 pin
work, with a BETTER shape -- `crate_pin` string literals are resolvable name-by-name
and so never create the runtime-name blind spot my r5 form did. All three
conflicted hunks resolved to main's side; the duplicate pin commit became a no-op.
Diff vs main is now 3 files, +1215/-8, additions only.

The r7 anchor asserted ONE literal at the fixed gate and would have gone quiet as
other sites are fixed. It now asserts the general rule -- no decode-derived count
(`pictures.len()` / `decoded.len()` / `frames.len()`) may reappear at that gate
under any binding name -- plus an unpinned CEILING of 43, so a NEW site is an
immediate red and the ceiling drops only when a site is actually fixed.

The report carries the full 43-row ledger (a=1, b=37, c=4, ?=1) with bucket,
candidate, spec_in_scope and a per-row disposition; names the one genuinely
unclassified gate with its reason rather than guessing; records the three
detection bugs that each produced a plausible clean output (a line index handed to
a byte-offset walk; `assert_eq!` split by rustfmt; a `}` inside a format string
counted as a closing brace); and states the class note so the next reader does not
chase a nonexistent silent-pass bug -- a wrong count cannot pass silently, the
helper's length assert fires, and the defect is a MISATTRIBUTED RED that
`frame_count_diagnosis` now explains.

gate_coverage 18, refusal_inventory 19, count_vacuity 2, pin_inventory 3, 0 warnings.
lanes/av1pins r7: the bucket table, the one fix, and 38 handed backAhmet Kaan Gümüş · 572204b
lanes/av1pins r7: the bucket table, the one fix, and 38 handed back

Classification by reading, printed per row with its reason: 37 bucket-b (live
aomenc), 1 bucket-a (disk), 4 bucket-c (probe), 1 unclassified with the reason.
Fixed stream.rs:3895 to pass the ENCODE's frame count instead of our decode's
length. Handed back the other 38 with a per-gate recipe rather than editing them
on a heuristic that has now been wrong three times in this lane.

Records a third offset bug: the sweep passed a line index to a byte-offset walk,
so 40 of 44 rows read 'unclassified' as though it were a result.
test(av1): classify the count-vacuity sites by reading, and fix the first oneAhmet Kaan Gümüş · 862cfda
test(av1): classify the count-vacuity sites by reading, and fix the first one

Main's r7 item 1, done by READING rather than by regex, and printed per site so
the classification is auditable: `ROW <line> | <gate> | <count expr> | bucket |
candidate | spec_in_scope | <reason> | pixel_comparing`, on every run.

Buckets, computed from each gate's own body (string-aware extent):
  b  38  live aomenc encode -> the count belongs to the ENCODER
  a   1  stream read from disk -> the count belongs to the pin
  c   4  census/probe -> report only, never fix
  ?   1  unclassified, with the reason printed rather than a guess

A third offset bug, same family as the two r6 caught: the sweep handed its
body-walk a LINE index where a BYTE offset was required, so every
body-dependent classification read "unclassified" -- 40 of 44. It is the third
time in this lane that a line/byte or slice-boundary confusion has silently
produced a plausible-looking clean result.

FIXED: stream.rs:3895, `a_real_aomenc_segmentation_stream_with_map_inheritance_
decodes_pixel_exact`. `ffmpeg_decode_sequence(..., pictures.len())` now passes
`ENCODED_FRAMES` (40), the count its own `encode_aomenc_stream(...)` call
encodes. Our decode's length was the thing UNDER TEST, so using it as the
oracle's expected count was circular. Gate green, 2.05 s, now comparing 40
frames against ffmpeg's 40 rather than a self-fulfilling number.

The sweep's "known site" anchor MOVED with the fix: it used to assert
`pictures.len()` was still present, which went red the moment the fix landed.
It now asserts the opposite -- no site may pass `pictures.len()` again -- plus
that the dominant `frames.len()` shape is still found, so the sweep cannot go
quiet by either route.

NOT DONE, and this is the honest part: 38 of the 39 fixable sites. The sweep
prints a `candidate` (the numeric frame count in the gate's own encode call) and
it resolves for exactly ONE gate; the rest encode inside loops or through
per-gate helpers whose frame-count argument must be read per gate. I am handing
those back with the method rather than editing 38 call sites on a guess, for the
same reason r6 refused the 44-row table on an untrustworthy column.

gate_coverage 15, refusal_inventory 15, count_vacuity 2, pin_inventory 3, and the
fixed gate all green. 0 warnings. Lane-scoped CARGO_TARGET_DIR with touch-first.
lanes/av1pins r6: the frame-count diagnosis, the two defect classes, and the 44 reportedAhmet Kaan Gümüş · 23576c3
lanes/av1pins r6: the frame-count diagnosis, the two defect classes, and the 44 reported

The helper change is the deliverable: the failure now names the caller's count,
ffmpeg's actual count, the byte arithmetic, and says the disagreement is OURS if
the count came from our own decode. That converts most of the 44 from confusing
to diagnosable without touching a caller.

count_vacuity keeps its floor and gains the misattributed-red vs silent-pass
distinction so r4's mistake is not repeated. 61 sites, 17 spec-pinned, 44 not,
30 gates -- after fixing two detection bugs of mine (a rustfmt-split assert_eq!
missed by one-line containment, and a brace walk that did not skip string
literals).

The pixel_comparing column is approximate and under-reports; three sampled gates
it marks false all compare planes. Reported rather than tabulated, because a
44-row table on an untrustworthy column sends a lane after the wrong gates.

Canonical branch is lane-av1pins5; av1pinslive is a stale duplicate at 2e5509e9
and can be dropped. No pins at risk: all 18 are committed.
test(av1): make the frame-count failure name the real cause, and classify the defectAhmet Kaan Gümüş · e107603
test(av1): make the frame-count failure name the real cause, and classify the defect

Main's r6 item 1, and it is the change that matters: a caller passing our own
decode's length as the oracle's expected count used to get

    expected N 4:2:0 frames, ffmpeg said: <empty>

with an EMPTY tail, because ffmpeg runs at `-v error` and succeeds. The message
named ffmpeg, said nothing about where N came from, and sent the next reader
hunting ffmpeg for a count ffmpeg never chose. All three helpers
(`ffmpeg_decode_sequence`, `_10bit`, `_444`) now share `frame_count_diagnosis`,
which reports the caller's count, ffmpeg's ACTUAL count, the byte arithmetic, and
states that `frames` is the caller's assertion rather than a measurement -- and
that if it came from our own decode_stream(), the disagreement is OURS.

Measured, same probe as r5:
    FRAME COUNT MISMATCH (4:2:0 192x128): the caller passed `frames=0`, ffmpeg
    produced 1 frame(s) (36864 bytes, 0 byte(s) not a whole frame, at 36864 B/frame).
    `frames` is the EXPECTED count the CALLER asserted -- it is NOT measured from
    ffmpeg... the fix is on OUR side, not ffmpeg's. ffmpeg itself exited cleanly.

This converts most of the 44 from confusing to diagnosable WITHOUT touching a
single caller, which is the whole point: 44 edits of unclear value was the risk.

`count_vacuity` keeps the floor and gains the note r6 item 3 asked for, naming
the TWO defect classes so the next reader does not repeat r4's mistake:
MISATTRIBUTED RED (what these sites are) vs SILENT PASS (a different defect with
a different fix, which these are NOT).

Sweep result, after fixing two detection bugs of mine: 61 sites, 17 spec-pinned,
44 not, across 30 distinct gates. The line/gate/count columns are exact (a
line-based scan with no body slicing). The `pixel_comparing` column is
APPROXIMATE and under-reports -- I sampled three gates it marks `false` and all
three plainly compare planes (4-5 plane-compare lines each). Its body slice is a
hand-rolled brace walk, and this crate's compare idioms vary enough that the
heuristic is not trustworthy. I am reporting that rather than shipping a 44-row
table derived from it: the classification needs a reader, not a regex.

Sites FIXED at the source: none beyond r4's. The 44 are reported with gate and
count expression, and fixing them means deriving each count from the fixture or
from the encoder's own frame count -- per-gate work across 30 gates, which is the
next lane, not this commit.

gate_coverage 15 passed, refusal_inventory 15, count_vacuity 2, pin_inventory 3,
pinned_golden3 green. 0 warnings. `#[ignore]` unchanged at 34.
lanes/av1pins r5: the scanner, the 14 recovered pins, and a correction to r4Ahmet Kaan Gümüş · 32ee762
lanes/av1pins r5: the scanner, the 14 recovered pins, and a correction to r4

pin_inventory resolves five shapes; the fifth is the one this fix itself
introduced (crate_pin(&format!("{n}.ext"))), which made the gate correct and
simultaneously invisible to the check watching it -- caught by the reads.len()
floor. Capability tests use synthetic source so they cannot rot when the fix
lands; two scanner bugs (a format! brace escape, and find(')') stopping at
len()'s own paren and yielding zero sites) were found that way.

count_vacuity enumerates 61 locally-derived oracle counts, 13 spec-pinned, 48 not.
Reported, not fixed: unbounded across gates this lane does not own.

CORRECTION to r4: this shape is a MISATTRIBUTED RED, not a vacuous pass. Measured
by calling ffmpeg_decode_sequence(..., 0) under catch_unwind -- it panics at
stream.rs:5110 blaming ffmpeg. r4's fix stands; its justification did not.
test(av1): a pin scanner that sees every shape, and a count-vacuity sweepAhmet Kaan Gümüş · 6049140
test(av1): a pin scanner that sees every shape, and a count-vacuity sweep

The r3 inventory matched two single-name call shapes and reported "the
machine-local-pin population is zero". `pinned_warp_stream_decodes_pixel_exact`
read 14 pins through a directory `concat!` literal plus a runtime
`format!("{fixtures}/{n}.obu")`, matched neither, and was invisible to it.

`pin_inventory` resolves FIVE shapes: crate_pin("X"), pin_dir().join("X"),
a whole-file concat! literal, a directory literal + runtime name, and (e) the
shape THIS FIX INTRODUCED -- `crate_pin(&format!("{n}.ext"))`.

Shape (e) is the one worth reading. Rewriting the directory literal as a
committed-path lookup made the gate CORRECT and simultaneously INVISIBLE:
`crate_pin("` no longer appears, shape (a) found nothing, and the enumerator
reported a CLEAN tree while 14 pins were read. A false pass is worse than the
original gap -- the original at least showed up in a filesystem audit. It was
caught by the `reads.len() >= 20` floor in the invariant test, which is why that
floor is there. This is the general lesson: fixing a shape can blind the check
that was watching it, so the check needs a floor AND a capability test that does
not depend on the live tree.

Capability tests use SYNTHETIC source, not the live file -- asserting against
the live tree would rot the moment the fix lands, which is exactly how a scanner
loses its edge and reports a clean tree again. Two of the three bugs in this
scanner were found that way: a `format!` brace-escape that emitted `{n` instead
of `{n}`, and a `find(')')` that stopped at `len()`'s own paren and silently
yielded ZERO sites.

`count_vacuity` enumerates every site that passes a locally-derived count as the
oracle's expected frame count: 61 found, 13 spec-pinned by a prior assert, 48 not.

CORRECTION to r4, which reported this shape as a "vacuous pass" and told Main
so. MEASURED by calling `ffmpeg_decode_sequence(&stream, 192, 128, 0)` on a real
pinned stream under `catch_unwind`: it PANICS at `stream.rs:5110` with
"expected 0 4:2:0 frames, ffmpeg said: ". The helper asserts
`out.stdout.len() == frame_bytes * frames` unconditionally, so a wrong count
cannot pass silently -- it REDS, with a message blaming FFMPEG for a count OUR
decoder chose. The consequence is a MISATTRIBUTED RED, not a silent pass. r4's
FIX is still right (the count now comes from the fixture, so the red names the
real cause); the justification was wrong, and a sweep repeating it would send the
next reader after a bug that does not exist.

The 48 unpinned sites are REPORTED, not fixed: that is an unbounded change across
gates this lane does not own. The pin-class gates are all clean -- 0 unpinned
count sites in lr_sgr, check_pinned_warp_stream, golden3, sbpart and film-grain.

`pinned_warp_stream_decodes_pixel_exact` is live and green: 14 pins read from
`crates/ec-av1/fixtures/`, 1 passed 0 failed 0 ignored, 1.47 s.
`#[ignore]` 36 -> 35. gate_coverage 15 passed, refusal_inventory 15 passed.
Tests and test helpers only; the frames=0 probe was deleted before this commit.
test(av1): commit the 14 warp/ii/rect pins — recovered originals, not re-encodesAhmet Kaan Gümüş · 58978d8
test(av1): commit the 14 warp/ii/rect pins — recovered originals, not re-encodes

Same defect as r3's four, one level deeper, found by a scanner that could not
see it. `pinned_warp_stream_decodes_pixel_exact` read its pins through a
DIRECTORY `concat!(env!("CARGO_MANIFEST_DIR"), "/../../fixtures")` literal plus a
runtime `format!("{fixtures}/{n}.obu")` over a name list. A scanner built on
single-name call shapes (`crate_pin("X")`, `pin_dir().join("X")`) matched neither,
so r3's "the machine-local-pin population is zero" was wrong: these 14 existed,
uncommitted, the whole time.

PROVENANCE: `recovered-original` for all 14. Fetched byte-for-byte from the runner
library (`~/gates/library/fixtures`), verified identical in three independent
locations (this worktree's staged copy, a local /tmp copy, and the runner library
itself) before committing — 14/14 identical, 0 mismatches. NOT regenerated: these
are the actual historical mismatch witnesses (a warp-mismatch, a warp-sample
clamp, interintra neighbour flakes, rect-strip flakes), and a re-encode would be a
different stream that must not be called the pin.

  warp-mismatch.obu    621 B  24cca5beb41c1078f8109d8fa7e35f10cc1eefb67c6d1d1ea248a0b6842287bb
  warp-flake-5.obu     602 B  1a99f9e5b257eed0ebae055441904d6c40962a26c0c2d63c3e051732569ff0a0
  warp-flake-7.obu     723 B  c2f8b93f5a59c56b1c4453ea789e0fc955557ed9b63c0e2cb8683fa483eff2b5
  ii-flake-1.obu       579 B  700ded3e61e15bc3573d339d7fcc6ab94500adb796c30021094d354306662238
  ii-flake-2.obu       581 B  edc4ad3a6c00c6bc909c626fa24433ef31a88ed519ed57403f5373a160e590af
  ii-flake-3.obu       670 B  994bfbdc952ecef18ae1560d5e7f121ba1000172e0bc2ad05e5b8cfaa17b15cb
  ii-flake-5.obu       681 B  f43fe77ea0e8ddd9c1524b642e09f935921cb0d00c4a60061a52d2260af38b9a
  ii-flake-6.obu       632 B  84a1f60011dfdb77ede98ce95a25d247d270b0af1cff2c44aa1e6b311ca63dce
  ii-flake-7.obu       654 B  61ba4d114aa55ebcf95ae691abbce3307146a2d969c0627ea3ceea02f3875574
  ii-flake-8.obu       635 B  f19d3d80ed564850cec02a26cfe7ab00e282afa7896821c535a117f5541bef5d
  ii-flake-9.obu       690 B  0df4874737cc615258c0fdfb4bcb157c9a3663127cbf0a896af44d4deb83c653
  rect-flake-1.obu     607 B  a3869b5d2bd8a8bc5413e0d039d5e3375a48601cdeb2edb8d4b732402926d357
  rect-flake-2.obu     601 B  c780ddee1adf25cf63a6ba70ff449820f6f4474b23ef16615c1e843ad0c86adb
  rect-flake-3.obu     572 B  3b23d204549b7bcfbd7166b1b3e2920580236c78de12e8f23f7fb64c1864f3e6

The gate now resolves them through `crate_pin` and its helper through
`require_pin`, so a missing pin is a hard failure naming the path and the
generator rather than a raw io panic. `.gitignore`'s
`!crates/*/fixtures/**` negation means a plain `git add` suffices — verified with
`git check-ignore -q` (returns 1, "not ignored") and by staging with no `-f`.

Committed on its own so the bytes are durable independently of the scanner and
gate-rewiring work that follows.