From 106964e3d266740f571b5aad7b57545b4a901ac9 Mon Sep 17 00:00:00 2001 From: Georgi Gerganov Date: Mon, 25 Nov 2024 21:49:31 +0200 Subject: [PATCH] metal : enable mat-vec kernels for bs <= 4 (#10491) --- ggml/src/ggml-metal/ggml-metal.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ggml/src/ggml-metal/ggml-metal.m b/ggml/src/ggml-metal/ggml-metal.m index 63baaf163..c47f07a9e 100644 --- a/ggml/src/ggml-metal/ggml-metal.m +++ b/ggml/src/ggml-metal/ggml-metal.m @@ -1927,7 +1927,7 @@ static void ggml_metal_encode_node( // find the break-even point where the matrix-matrix kernel becomes more efficient compared // to the matrix-vector kernel - int ne11_mm_min = 1; + int ne11_mm_min = 4; #if 0 // the numbers below are measured on M2 Ultra for 7B and 13B models