qwen4exp: verify/decode pass launch order, prefetch width, chain polling, turnover slots

Lossless (no kernel arithmetic or operand change): the router weight is read beside the mixer
all-reduce; k/v projections before q|gate; the indexer's keys behind the attention launches within
the exact bound; verify-height prefetch at 32 workgroups (`prefetch` takes an optional `blocks`
param) and the shared down arm before the routed down from 2 rows (kVerifyRows); chain waits poll by
grid size (R4D_CHAIN_TINY/SMALL/MID); the mover's kept-free turnover slots follow the swaps the
engine asked for (MoverConfig::turnover_adaptive) instead of a fixed 640.

arch_test: new a_flash_next_decode_step_orders_its_small_launches; the pinned graph fingerprints and
step hashes of qwen4exp_fp8 move (re-pinned). place_test: the adaptive turnover. r4d_selftest: the
`blocks` param of prefetch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Code000andClaude Opus 5.5 authored and StillDeadcode committed 2026-11-17 20:33:07 +01:00
1 parent 946a6f9e2b
commit ca7a7212ec
20 files changed
+598 -44

No files matched your search

+3
View File
@@ -1017,6 +1017,9 @@ void Engine::tiering_dispatch(Rank& r, int step) {
* credited; the next unstaged step swaps on them. */
std::vector<Swap> swaps;
if (!r.stager.staged() && r.heat.step(&swaps) < 0) return;
/* What the turnover slots follow (MoverConfig::turnover_adaptive). A staged step proposes
* nothing and holds the turnover filled anyway (below), so it is not a quiet step. */
if (!r.stager.staged()) r.mover.swap_demand((int64_t)swaps.size());
for (const Swap& s : swaps) {
/* Contract: every proposed unit is busy until `issue` takes it or `abandon` returns it;
* a dropped proposal stays busy forever. */