Skip to content

Commit 4245e62

Browse files
authored
sycl: disable reorder for sycl mulmat (#13536)
1 parent c9c64de commit 4245e62

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

ggml/src/ggml-sycl/ggml-sycl.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3028,7 +3028,7 @@ static bool should_reorder_tensor(ggml_backend_sycl_context& ctx, const ggml_ten
30283028
return !g_ggml_sycl_disable_optimize && //allow optimize, controlled by $GGML_SYCL_DISABLE_OPT
30293029
ctx.opt_feature.reorder && //allow this device due to good perf, skip the devices with bad perf.
30303030
dst->op == GGML_OP_MUL_MAT && //limit to some supported cases of Q4_0, to do for more cases.
3031-
dst->src[1]->ne[2]==1 && dst->src[1]->ne[3]==1;
3031+
dst->src[1]->ne[1]==1 && dst->src[1]->ne[2]==1 && dst->src[1]->ne[3]==1;
30323032
}
30333033

30343034
static void opt_for_reorder(ggml_backend_sycl_context * ctx, const ggml_tensor * src0, const ggml_tensor * /* src1 */,
@@ -3151,8 +3151,6 @@ static void ggml_sycl_mul_mat(ggml_backend_sycl_context & ctx, const ggml_tensor
31513151
ggml_sycl_op_mul_mat(ctx, src0, src1, dst, ggml_sycl_op_mul_mat_q, convert_src1_to_q8_1);
31523152
} else {
31533153
constexpr bool convert_src1_to_q8_1 = false;
3154-
// MUL_MAT_SYCL supports reorder
3155-
opt_for_reorder(&ctx, src0, src1, dst, mul_mat_algo::MUL_MAT_SYCL);
31563154
ggml_sycl_op_mul_mat(ctx, src0, src1, dst, ggml_sycl_op_mul_mat_sycl, convert_src1_to_q8_1);
31573155
}
31583156
GGML_SYCL_DEBUG("call %s done\n", __func__);

0 commit comments

Comments
 (0)