From b1eaad6a9107418635e70fe130a43c82ef105d75 Mon Sep 17 00:00:00 2001 From: Georgi Gerganov Date: Mon, 25 Nov 2024 10:36:48 +0200 Subject: [PATCH] metal : enable mat-vec kernels for bs <= 4 --- 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 d1abb3cef..ba4f2e65f 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