From bd8fe4becc6323192861e0b7e15cdf0e2ce53e3b Mon Sep 17 00:00:00 2001 From: bong-water-water-bong Date: Thu, 12 Nov 2026 19:40:03 -0400 Subject: [PATCH 1/2] gpu-kernels: pin eb0f3839, which carries the 2^-6 prefill prescale (#2159), the routed GEMM fit (#572) and the registration guard MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Upstream merged three kernel fixes today and the engine still pinned the commit before them: gpu-kernels main eb0f383972039bb2292f0d9f740b1020fcd3a1e1 gpu-kernels#68 the prefill GEMM keeps activations inside the f16 range (2^-6 prescale, the llama.cpp #285/#288 shape) gpu-kernels#67 the routed-expert prefill GEMM fitted to Qwen3.8-Flash-Next gpu-kernels#66 registration fails when a HipKernel has no launch engine pin was fd69590c6c471507f6d804751f38473261436350 So the engine now builds the kernels that carry them. The sha is advertised by the remote (checked with `git ls-remote`, not assumed) and the config's format is unchanged: `scripts/fetch-private.sh` checks out exactly this commit at build time. This changes the compiled kernels in every HRX build, which is the point and also the risk: the code objects the release ships come from this checkout, so the first HRX build after this PR is the one that proves the bump. #2159's fix was measured by the kernel lane on these kernels (the MUL_MAT_ID rows and the 12 dense magnitude rows in #2293), so the prescale is not a guess. One doc line had to change with it: docs/hetero-prefill.md said "`origin/main`'s `config/gpu-kernels.config` pins fd69590c…", which stops being true the moment this lands. It now says "at the time of this capture pinned", which keeps the argument (the pin carried the fix then; the capture's runtime was stale) without asserting anything about today's pin. --- config/gpu-kernels.config | 2 +- docs/hetero-prefill.md | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/config/gpu-kernels.config b/config/gpu-kernels.config index e718232bb..0b87d51b7 100644 --- a/config/gpu-kernels.config +++ b/config/gpu-kernels.config @@ -22,6 +22,6 @@ # # Move the pin by hand, after the HRX checks on Strix Halo (docs/hrx.md). repo=1bit-MONSTER/gpu-kernels -sha=fd69590c6c471507f6d804751f38473261436350 +sha=eb0f383972039bb2292f0d9f740b1020fcd3a1e1 path=addons/hip-hrx require=addon.cmake kernels diff --git a/docs/hetero-prefill.md b/docs/hetero-prefill.md index 381bf66a1..b555ac6dc 100644 --- a/docs/hetero-prefill.md +++ b/docs/hetero-prefill.md @@ -170,8 +170,8 @@ numbers of this document dated, and to re-run the ratio before anyone quotes a c > therefore comes from the binary's RUNPATH, `~/wt/release-rc/work/build/hrx/llama/bin/libggml-hrx.so.0.18.0`, and that file is > dated **2026-11-02 07:03** - four days before the #782 fix. Two device-free checks settle it: that library references > `m128_w8_f2_sb` **24 times**, while the post-fix build at `~/.cache/hw-gate/build-13a7fda57a/bin` (2026-11-06 16:12, -> gpu-kernels `fd69590`) references it **0 times**, and `origin/main`'s `config/gpu-kernels.config` pins -> `fd69590c6c471507f6d804751f38473261436350` - i.e. **the pin already carries the fix; the installed runtime the capture +> gpu-kernels `fd69590`) references it **0 times**, and `config/gpu-kernels.config` **at the time of this capture** pinned +> `fd69590c6c471507f6d804751f38473261436350` - i.e. **the pin already carried the fix; the installed runtime the capture > used was stale**. The pp2048 anchor could not have caught this: pp2048 is below the M=2048 knee, which is why it is fast > on both builds. > From 762a35cae623ff245c64f854f6bcde17b9cbaae2 Mon Sep 17 00:00:00 2001 From: bong-water-water-bong Date: Thu, 12 Nov 2026 21:17:22 -0400 Subject: [PATCH 2/2] gpu-kernels: pin b0ed206, which carries both f16-range fixes (#2159, #2293) and the QSA/mask work behind them Two commits past the previous bump, and both are the ones the issue threads are waiting on: #68 aa25474 the prefill GEMM keeps activations inside the f16 range (2^-6 prescale, undone before the epilogue) #70 dccd024 dense prefill and small-batch K-quant activations finite above the f16 range (engine #2293) #70 is #2293's part 2 -- the 12 dense magnitude rows that had no fix when the issue was filed. Its comment in hrx_dense_prefill.hip names the issue and the rows: "an activation above 65504 became inf in the narrowing and the result NaN (engine #2293: test-backend-ops MUL_MAT magnitude=91000 on q8_0 / iq4_xs / q5_K / q6_K)". #68's comment in hrx_prefill_gemm.hip names #2159's failure the same way. Verified by fetching the pin with this branch's config (1.4 s, shallow sparse checkout) and reading the two files, not by trusting the PR titles: both carry kXs = 0.015625f / kXsInv = 64.0f with those comments. The range is TEN commits, not the three the previous body named -- the full inventory is in the PR body, because the review at bd8fe4b was right that a count of three understated what a reader is being asked to accept. --- config/gpu-kernels.config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/gpu-kernels.config b/config/gpu-kernels.config index 0b87d51b7..96c77c2cf 100644 --- a/config/gpu-kernels.config +++ b/config/gpu-kernels.config @@ -22,6 +22,6 @@ # # Move the pin by hand, after the HRX checks on Strix Halo (docs/hrx.md). repo=1bit-MONSTER/gpu-kernels -sha=eb0f383972039bb2292f0d9f740b1020fcd3a1e1 +sha=b0ed2060e413754cacde6f6d03ae60b46491b25a path=addons/hip-hrx require=addon.cmake kernels