Skip to content

Commit

Permalink
cuda : fix dmmv cols requirement to 2*GGML_CUDA_DMMV_X ggerganov#8800
Browse files Browse the repository at this point in the history
Fix provided by Slaren
  • Loading branch information
Nexesenex committed Jul 31, 2024
1 parent 69fce39 commit b6d8b2a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions ggml/src/ggml-cuda.cu
Original file line number Diff line number Diff line change
Expand Up @@ -1902,8 +1902,7 @@ static void ggml_cuda_mul_mat(ggml_backend_cuda_context & ctx, const ggml_tensor

bool use_dequantize_mul_mat_vec = (ggml_is_quantized(src0->type) || src0->type == GGML_TYPE_F16)
&& src1->type == GGML_TYPE_F32 && dst->type == GGML_TYPE_F32
&& src0->ne[0] % GGML_CUDA_DMMV_X == 0 && src0->ne[0] >= GGML_CUDA_DMMV_X*2
&& src1->ne[1] == 1;
&& src0->ne[0] % (GGML_CUDA_DMMV_X*2) == 0 && src1->ne[1] == 1;
bool use_mul_mat_vec_q = ggml_is_quantized(src0->type)
&& src1->type == GGML_TYPE_F32 && dst->type == GGML_TYPE_F32
&& src1->ne[1] <= MMVQ_MAX_BATCH_SIZE;
Expand Down

0 comments on commit b6d8b2a

Please sign in to comment.