Skip to content

Commit b16b20f

Browse files
committed
SYCL: disable faulty fp16 exp kernel (ggml-org#14395)
* SYCL: disable faulty fp16 CPU exponent for now * Revert "SYCL: disable faulty fp16 CPU exponent for now" This reverts commit ed0aab1. * SYCL: disable faulty fp16 CPU exponent for now * Fix logic of disabling exponent kernel
1 parent c048a56 commit b16b20f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4221,7 +4221,6 @@ static bool ggml_backend_sycl_device_supports_op(ggml_backend_dev_t dev, const g
42214221
case GGML_UNARY_OP_GELU_QUICK:
42224222
case GGML_UNARY_OP_GELU_ERF:
42234223
case GGML_UNARY_OP_TANH:
4224-
case GGML_UNARY_OP_EXP:
42254224
case GGML_UNARY_OP_SGN:
42264225
case GGML_UNARY_OP_ABS:
42274226
case GGML_UNARY_OP_ELU:
@@ -4230,6 +4229,9 @@ static bool ggml_backend_sycl_device_supports_op(ggml_backend_dev_t dev, const g
42304229
#else
42314230
return ggml_is_contiguous(op->src[0]) && (op->src[0]->type == GGML_TYPE_F32 && op->type == GGML_TYPE_F32) && (op->type == op->src[0]->type);
42324231
#endif
4232+
case GGML_UNARY_OP_EXP:
4233+
// Disable FP16 until we find out the root cause of failing fp16 sycl::exp
4234+
return ggml_is_contiguous(op->src[0]) && (op->type == op->src[0]->type) && op->src[0]->type == GGML_TYPE_F32;
42334235
default:
42344236
return false;
42354237
}

0 commit comments

Comments
 (0)