mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-06 16:29:04 +00:00
The tile rule picked 64 rows for the staged K-quant pairs of UD-Q4_K_XL (Q4_K / Q5_K gate/up with a Q5_K / Q6_K down) above 112 rows an expert on an sm_86 card with 80+ SMs, which is every prompt chunk of 4,096 tokens (the chunk the engine uses when the experts are resident: 32,768 routed rows over 256 experts). The staged 128-row kernels are faster there. One layer of Qwen3.6's shape (256 experts, top 8), MMQ ms / fused ms at 2,048 / 4,096 / 8,192 / 20,000 tokens, two repeats, the output bits hash equal at every tile: RTX A6000 (84 SMs), tile 64: Q4_K / Q5_K 0.91 0.85 0.71 0.65 Q4_K / Q6_K 0.82 0.73 0.61 0.53 Q5_K / Q6_K 0.71 0.63 0.52 0.46 RTX A6000 (84 SMs), tile 128: Q4_K / Q5_K 1.42 1.08 0.95 0.91 Q4_K / Q6_K 1.47 1.17 1.02 0.91 Q5_K / Q6_K 1.37 1.14 0.98 0.86 RTX PRO 5000 (110 SMs, sm_120), tile 64: 0.99 0.85 0.72 0.63 0.92 0.77 0.66 0.58 0.83 0.70 0.60 0.52 RTX PRO 5000 (110 SMs, sm_120), tile 128: 1.28 1.07 1.02 0.87 1.33 1.12 0.99 0.96 1.23 1.08 0.93 0.90 On the sm_120 card the rule already picks 128 there, so its default row equals the forced-128 row. At 2,048 tokens (64 rows an expert) both rules pick 128 already. fused_tile::wide_pair names the pairs of the existing wide class (a Q6_K or Q8_0 gate/up) and now also a Q4_K / Q5_K gate/up with a Q5_K / Q6_K down; experts_native_ext in the Qwen3.6 copy of the kernels passes it as the launch's wide argument. Flash-Next's K-quant gate/up (Q5_1 / Q8_0 down), the i-quant pairs, sm_120 cards, cards under 80 SMs (staged rule) and HIP are unchanged. The output bits are the same at either tile. No kernel changes; the unit test pins wide_pair over the type grid and the rule at the engine's chunk sizes on 84-, 108-, 128-SM sm_86 cards, the 48-SM staged card and the sm_120 cards, with a grid oracle for staged + wide on sm_86 cards.