Repository navigation
Conversation
|
Thanks @gputier, each fix checks out against main. Could you rebase onto 0.1.26? |
… fewer slots than the resolve block
…eam does for the others
78edddc to
de33f38
Compare
|
Rebased onto 0.1.26. |
… the order of the next PRs
|
Thanks, all addressed. This goes through our full gate first thing for 0.1.29 (the bf16 NaN change is the one that can change output). |
|
Released in 0.1.29: all five fixes, byte-identical on our four quants; the new bf16/element-wise/s_gemv tests pass. Merged under your name (cherry-picked, so GitHub doesn't show it as merged). Thank you! |
….1.29 (issue tags removed); comments only, no code change
…pstream base and what was not picked
…iko1221#197), faster prompt kernels (Niko1221#187, Niko1221#188, Niko1221#207), correctness fixes (Niko1221#154); setup requires it
…iko1221#197), faster prompt kernels (Niko1221#187, Niko1221#188, Niko1221#207), correctness fixes (Niko1221#154); setup requires it
…iko1221#197), faster prompt kernels (Niko1221#187, Niko1221#188, Niko1221#207), correctness fixes (Niko1221#154); setup requires it Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0154bwiad8gY7wRehCXy27pN
The correctness fixes offered in #149, on top of 0.1.26 (ac8b251). One commit per fix; each is small and changes no result outside the case it fixes.
s_gemv: ins_gemv_q8_split_kernel, a warp with no row returned before the__syncthreads()that follows the codebook load. The codebook is now loaded first, then the rowless warp returns.s_gemv_q8k_paritygains output widths that are not a multiple of the eight rows per block.bf16: the rounding add inbf16_from_f32carried a NaN out of the mantissa (0x7FFFFFFF came back as -0, 0x7F800001 as +inf). A NaN now stays a quiet NaN, as in ggml;bf16_bits_testchecks all 2^32 inputs against ggml's rule, andelementwise_paritycovers the device side, including the second copy indequant_bf16.cu. The HIP__builtin_memcpybranch is kept as is; the NaN check comes right after it, so it applies to every backend.qsa: a cell whose KV-streaming page did not resolve (-1) was read anyway inqsa_decode_attn; it is now masked with weight 0.kv_streamstops with a message when asked to sweep fewer slots than the resolve block, where two threads could take the same slot (the engine never goes below 5,120 slots, so this is a guard).expert_source: the verify window's fixed tables (kind[128],distinct[128]) are bounded by astatic_assertand a runtime check onn_tok * k, ands2_expert_groupedasserts its group limit covers the window.gguf_reader.hpp:NOMINMAXbeforewindows.h, so every file that reaches this header can usestd::min/std::maxunder MSVC (gguf_reader_test.cpp,native_dense.cppandnative_head.cppinclude it without defining it).graph_registry_testandpinned_captureon their file. The twobench/micro/targets still unguarded,native_mmvq_multiandhit_cpu_order_parity, get the sameEXISTScheck, with the backend variables.Before the rebase: tested on an RTX 5090 (Windows 11, MSVC 2022, CUDA 13.4, sm_120), ctest 30 of 33, the three failures being missing model files on my side (
ple_paritywants a Q2_0 PLE table,expert_parityandpool_testwantpack/full/experts.bin).After the rebase on 0.1.26: the four code fixes are byte-identical to the tested ones (
git range-diff); only thebf16_bits.hppconflict and the CMake commit changed. Checked on x86-64 Linux, CPU only: configure and build clean,bf16_bits_testpasses (0 differences from ggml over 2^32 inputs), 10 of 11 CPU tests pass, and the failing one,expert_multi_test, fails the same way on plain 0.1.26. The CUDA and HIP paths were not rebuilt after the rebase, so your byte-identity gate is the check there.qsa_decode_attnands2_expert_groupedhave no ctest target, so the build is their only check.