Skip to content

Commit 256fe66

Browse files
committed
sycl : fix supports_op for MXFP4
ggml-ci
1 parent 60ab08a commit 256fe66

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

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

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4191,15 +4191,9 @@ static bool ggml_backend_sycl_device_supports_op(ggml_backend_dev_t dev, const g
41914191
case GGML_OP_MUL_MAT:
41924192
case GGML_OP_MUL_MAT_ID:
41934193
{
4194-
struct ggml_tensor * a;
4195-
struct ggml_tensor * b;
4196-
if (op->op == GGML_OP_MUL_MAT) {
4197-
a = op->src[0];
4198-
b = op->src[1];
4199-
} else {
4200-
a = op->src[2];
4201-
b = op->src[1];
4202-
}
4194+
struct ggml_tensor * a = op->src[0];
4195+
struct ggml_tensor * b = op->src[1];
4196+
42034197
if (a->ne[3] != b->ne[3]) {
42044198
return false;
42054199
}
@@ -4214,7 +4208,9 @@ static bool ggml_backend_sycl_device_supports_op(ggml_backend_dev_t dev, const g
42144208
}
42154209
}
42164210
ggml_type src0_type = op->src[0]->type;
4217-
if (src0_type == GGML_TYPE_BF16) {
4211+
if (src0_type == GGML_TYPE_BF16 || src0_type == GGML_TYPE_MXFP4) {
4212+
// TODO: support MXFP4
4213+
// FIXME: keep a list of supported types to avoid breaking the backend when a new type is added
42184214
return false;
42194215
}
42204216
return true;

0 commit comments

Comments
 (0)