]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commitdiff
k-quants : fix zero-weight guard in Q6_K (ref #3040)
authorGeorgi Gerganov <redacted>
Wed, 6 Sep 2023 09:40:57 +0000 (12:40 +0300)
committerGeorgi Gerganov <redacted>
Wed, 6 Sep 2023 09:40:57 +0000 (12:40 +0300)
k_quants.c

index 8742d4aee6f546efcc0cebbb53b918efbda0d3c0..eb702ce86acd98bf8bc4e626853bdd16437d799c 100644 (file)
@@ -1089,6 +1089,7 @@ void quantize_row_q6_K_reference(const float * restrict x, block_q6_K * restrict
         if (!max_abs_scale) {
             memset(&y[i], 0, sizeof(block_q6_K));
             y[i].d = ggml_fp32_to_fp16(0.f);
+            x += QK_K;
             continue;
         }