Repository navigation
gpu-kernels: the fused-swiglu prefill tile follows m128_sb(), with per-format device proof (closes #1064) - #1246
Conversation
…r-format device proof (engine #1064)
Merging on the add-on's own device evidence — hw-gate queued behind a saturated FIFOThe Merging on green |
Bumps the private HIP-kernel add-on pin (
config/gpu-kernels.config)17a882640fa8→94bc42e55c60(merge of 1bit-MONSTER/gpu-kernels#59), for engine#1064: the fused-swiglu prefill tile now followsm128_sb()likemm_tile()instead of forcing_sbfor every fused FFN gate/up dispatch.What the kernel change does
swiglu_tile(type, tokens): for>= 256tokens it takesconst bool sb = m128_sb(type), soq4_k/q5_k/q6_kfollowGGML_HRX_HIP_DENSE_PREFILL_M128_SBexactly asmm_tile()does, and every other admitted format takes the plain tile likemm_tile(). The<256decode branch stays onm64_w8_f1_sb(no plain m64 build exists).register_kernels()now registers the plain 128-row swiglu tile.Per-format device proof (strixhalo gfx1151,
dense-prefill-bench, A B B A, T=4096, real GGUFs)_sbms / TFLOP/sWhole-output f32+f16 FNV hashes are identical plain vs
_sbin every row (bit-identical on all T*N values), andmax_erris identical (e.g. 5.28e-04 q4_k).bad=0everywhere. Logs on strixhalo:~/wt/tile1064-bench-20261106T024951. The add-on's owntools/check.sh gfx1151: kernel ids match the manifest (409), 45 add-on objects ok, probes PASS at both knob settings (only the 10 pre-existing hyperconn/lightning-indexer fingerprint failures, engine#52).What this does not change
The shipped default
GGML_HRX_HIP_DENSE_PREFILL_M128_SB=1still selects_sbfor q4_k/q5_k/q6_k — the 2.1-2.8x FFN win needs the knob off (or the default flip tracked by gpu-kernels#48). What #1064 asks for is that the knob has an effect on the fused-swiglu tile, which it did not before. Serving-level identity is left to the hw-gate'skat/kldrows (the P4 logprob harness the issue names is an NPU path and cannot run against the HRX GPU).Merge gate
hw-gateis labelled: it fetches the private kernels at the new pin, builds them (the default build path), and runs build/ops/kat/kld/needle/placement on thestrixhalo-enginerunner. The engine's plainbuilddoes not compile the add-on. The kernel sources stay in the private repo; only the compiled code objects ship, perdocs/hrx.md.