@@ -2924,7 +2924,7 @@ static bool should_reorder_tensor(ggml_backend_sycl_context& ctx, const ggml_ten
29242924 return !g_ggml_sycl_disable_optimize && // allow optimize, controlled by $GGML_SYCL_DISABLE_OPT
29252925 ctx.opt_feature .reorder && // allow this device due to good perf, skip the devices with bad perf.
29262926 dst->op == GGML_OP_MUL_MAT && // limit to some supported cases of Q4_0, to do for more cases.
2927- dst->src [1 ]->ne [2 ]==1 && dst->src [1 ]->ne [3 ]==1 ;
2927+ dst->src [1 ]->ne [1 ]== 1 && dst-> src [ 1 ]-> ne [ 2 ]==1 && dst->src [1 ]->ne [3 ]==1 ;
29282928}
29292929
29302930static void opt_for_reorder (ggml_backend_sycl_context * ctx, const ggml_tensor * src0, const ggml_tensor * /* src1 */ ,
@@ -3041,8 +3041,6 @@ static void ggml_sycl_mul_mat(ggml_backend_sycl_context & ctx, const ggml_tensor
30413041 ggml_sycl_op_mul_mat (ctx, src0, src1, dst, ggml_sycl_op_mul_mat_q, convert_src1_to_q8_1);
30423042 } else {
30433043 constexpr bool convert_src1_to_q8_1 = false ;
3044- // MUL_MAT_SYCL supports reorder
3045- opt_for_reorder (&ctx, src0, src1, dst, mul_mat_algo::MUL_MAT_SYCL);
30463044 ggml_sycl_op_mul_mat (ctx, src0, src1, dst, ggml_sycl_op_mul_mat_sycl, convert_src1_to_q8_1);
30473045 }
30483046 GGML_SYCL_DEBUG (" call %s done\n " , __func__);
0 commit comments