Verba/Rapida

Esperimenti #175dr3va

Fused per-row verify attention for the row-exact verify: one dispatch runs every row's decode-shaped...

done

Il testo degli esperimenti resta in inglese, come l'ha scritto il laboratorio.

Cosa è stato provato

Fused per-row verify for the row-exact verify: one dispatch runs every row's decode-shaped attention (copies of MLX's `sdpa_vector_2pass_1`/`_2` with a per-row key window, key count and block count from MLX's host formula at the call's gqa, and of the one-pass `sdpa_vector`), so each row is bit for bit its own decode call, replacing one MLX call a row plus a concatenate (`sdpaRowsAsDecode`, LESTO 0437d9b `transformer.zig:18808`); target the attention's +1,083 us a round (39% of the verify delta) in [mac diag175dr3vt29]; a narrow gate (after three rounds) fuses only the traced shapes on an s-class : sliding layers (head dim 256, gqa 2, window 1,024) with every row past the window (two-pass, float mask) or every row inside it (one-pass), and global layers (head dim 512, gqa 8) with every row at 1,024 keys or more; every other block keeps the per-row path. Opt-in `MLX_SERVE_VERIFY_ATTN_ROWS=1`, Lesto `row/175dr3va` 0e59ae80. First steps: unit exactness (Bf16Tally over a million outputs) and a timing ubench on the M4, cost sheet `2026-11-29-verify-attn-rows` (measure-first)

Modello e configurazione

the row-exact (lesto_r175dr3v_rowl)

Guadagno atteso

about +3% decode (sheet: -3.6% session, -2.0% Codex, budget -2%)

Da dove viene l'idea

[mac diag175dr3vt29]

Esito

done 2026-11-30 03:39 M4: exact (0 of 2,031,616 elements differ, 96 fused calls) and the fused call saves 893 to 1,743 us a 30-layer batch of 3 rows (26 to 33%) in the isolated ubench; measure-first again, Codex agreed; the pair is [mac gen175dr3va] (`docs/experiments/2026-11-28-mac-r175dr3v-row-exact-verify/README.md` § Result, row [mac 175dr3va])

Vuoi vedere cosa hanno prodotto questi esperimenti? Lesto, il motore di inferenza per Gemma 4 sui Mac con Apple silicon, è su lestoengine.com

Creato da Federico Andrioli, @fedeandri su X Le misure di un laboratorio di ricerca, ricavate direttamente dai suoi file. Dati aggiornati al