From: Johannes Gäßler Date: Mon, 9 Dec 2024 19:07:12 +0000 (+0100) Subject: CUDA: fix shared memory access condition for mmv (llama/10740) X-Git-Tag: upstream/0.0.1642~79 X-Git-Url: https://git.djapps.eu/?a=commitdiff_plain;h=e6a76b1abc8f1b4b84aa54bc665703aeb45380ce;p=pkg%2Fggml%2Fsources%2Fggml CUDA: fix shared memory access condition for mmv (llama/10740) --- diff --git a/src/ggml-cuda/mmv.cu b/src/ggml-cuda/mmv.cu index cfe91f42..a4b4f6bc 100644 --- a/src/ggml-cuda/mmv.cu +++ b/src/ggml-cuda/mmv.cu @@ -57,7 +57,7 @@ static __global__ void mul_mat_vec( if (block_size > WARP_SIZE) { buf_iw[tid/WARP_SIZE] = sumf; __syncthreads(); - if (tid > WARP_SIZE) { + if (tid >= WARP_SIZE) { return; } sumf = buf_iw[tid];