Skip to content

Commit 97151f4

Browse files
quic-sszotlhez
authored andcommitted
opencl: fix for token length < 4
1 parent 097f869 commit 97151f4

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

ggml/src/ggml-opencl/ggml-opencl.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2857,6 +2857,9 @@ static void ggml_cl_mul_mat(ggml_backend_t backend, const ggml_tensor * src0, co
28572857
CL_CHECK(status);
28582858

28592859
int height_B = N/4;
2860+
if (height_B == 0) {
2861+
height_B = 1;
2862+
}
28602863
int width_B = K/4;
28612864
int padded_height_B = (N + padding)/4;
28622865

0 commit comments

Comments
 (0)