forge
Explore
Log in

Don't you dare go Hollow

Lane-ctx report -- pricer context sites, per-arm gate tables, deferrals

Browse files at this commit

6ea5a699bd64157ba8eeb74727817907c0ea4a01Ahmet Kaan GümüşParent: c73918f
  • docs
    • lane-ctx report -- pricer context sites, per-arm gate tables, deferrals
Show full message
docs(av1): lane-ctx report -- pricer context sites, per-arm gate tables, deferrals
lanes/ctx.report.mdmodified+62 -0
@@ -23,3 +23,65 @@ Open, found while enumerating: the single-reference candidates pay **no**
23 `comp_mode = 0` term at all while the compound ones pay `comp_mode = 1`, so23 `comp_mode = 0` term at all while the compound ones pay `comp_mode = 1`, so
24 compound is still overcharged by `comp_mode(0)` relative to single. Left alone24 compound is still overcharged by `comp_mode(0)` relative to single. Left alone
25 here so arm C measures one thing.25 here so arm C measures one thing.
26+
27+## 2. Arms and gates (12-frame native gate, BD-rate vs libaom cpu-used 6 / rav1e speed 6)
28+
29+Control reproduced in this worktree at `e74e7229`, exactly the charter's numbers.
30+
31+| row | control | arm A (skip + is_inter) | arm C (cumulative, + compound tree) |
32+|---|---|---|---|
33+| film A | +21.5 / −4.4 | +21.5 / −4.5 | **+21.0 / −4.8** |
34+| film B | +26.9 / −0.4 | +26.4 / −0.7 | **+25.0 / −1.8** |
35+| screen | +14.4 / −33.2 | +14.5 / −33.2 | **+14.5 / −33.2** |
36+| bars 1080p | −1.4 / −17.2 | −1.8 / −17.4 | −1.8 / −17.5 |
37+| bars 2160p | +8.8 / −13.2 | +8.5 / −13.5 | +8.8 / −13.3 |
38+
39+**arm A ships** under the second keep rule: film B is 0.5 down on libaom and
40+0.3 down on rav1e, film A flat on both (0.0 / −0.1), screen 0.1 up on libaom
41+(inside the 0.3 the rule allows).
42+
43+**arm C ships** under the first keep rule: both film rows improve on both
44+columns (−0.5/−0.3 and −1.4/−1.1), screen flat.
45+
46+Cumulative long-GOP gate (`bd_rate_film_long_gop`), both arms in:
47+
48+| row | control | shipped |
49+|---|---|---|
50+| film A | +26.4 / −6.4 | **+25.2 / −7.1** |
51+| film B | +89.6 / +9.1 | **+87.1 / +7.7** |
52+
53+## 3. Unit tests
54+
55+* `encode::tests::the_skip_and_intra_inter_pricers_use_the_writers_own_contexts`
56+ — RED at row 0: `skip false at ctx 1: priced 0.049125199808023, writer codes
57+ 0.9885106508271125`. Green after arm A.
58+* `encode::tests::the_compound_ref_pricer_pays_the_writers_own_symbol_sequence`
59+ — RED against the old constant pricer: `pair (1, 2) ... priced
60+ 10.19573638784928 bits, writer codes 5.455955052750427` (a LAST+LAST2 pair
61+ priced as LAST+GOLDEN). Green after arm C.
62+
63+## 4. Pins and suite
64+
65+* Stream pins re-taken: `[(150, 8311, 0xfb6d_75a4_5d13_3833), (60, 33087,
66+ 0x4d11_a03c_bdc6_e2d5)]` (was 8535 / 33221), green at the default preset and
67+ at `EC_AV1_SPEED=6`.
68+* `mi_info_cell_stays_compact` / `mi_info_stays_small_enough_for_a_4k_grid`
69+ went RED mid-lane: `skip` as a `MiInfo` field took the cell 16 → 18 bytes,
70+ and that struct is the mv-stack scan's memory traffic. The flag moved to a
71+ `Vec<bool>` beside `MiGrid::cells`, filled only by the encoder's `record_mi`
72+ and read only by the stack. Both pins unchanged by that move, so the gate
73+ numbers above stand.
74+* `timeout 900 cargo check --workspace --all-targets -j4`: 0 errors, 0 ec-av1
75+ warnings (the workspace's 22 warnings are pre-existing, in ec-opus and
76+ ec-vorbis).
77+
78+## 5. Deferred
79+
80+`deferred: arm B (tx_size depth category context) — the pricer's
81+tx_depth_bits lives in code_square, which takes neither the mi grid nor the
82+block's mi coordinates, and the writer's tx_size_ctx/tx_size_ctx_txfm read a
83+PER-TRANSFORM-UNIT published side (Neighbours::record_tx) that MiGrid does not
84+carry at all; reproducing it needs a new published tx band plus a parameter
85+through every code_square caller — what unblocks it: publish the resolved
86+transform side per mi cell beside MiGrid::cells the way this lane's skip band
87+now rides, then thread (grid, mi) into code_square.`