opencl: limit local workgroup size for GLU operation (#26383)

This commit is contained in:
mgroeber9110
2026-08-02 20:44:00 +02:00
committed by GitHub
parent fffbcbdb9d
commit 0ab9d6fed7

View File

@@ -24260,7 +24260,7 @@ static void ggml_cl_glu(ggml_backend_t backend, const ggml_tensor * src0, const
}
const size_t nrows = ggml_nrows(src0);
size_t nth = 512;
size_t nth = backend_ctx->max_workgroup_size < 512 ? backend_ctx->max_workgroup_size : 512;
size_t global_work_size[] = {nrows*nth, 1, 1};
size_t local_work_size[] = {nth, 1, 1};