metal : add f16 type support to leaky relu (llama/25981)

This commit is contained in:
Ilia Ilmer 2026-07-22 23:45:46 -04:00 committed by Georgi Gerganov
parent 818f9e9787
commit 571687089f
No known key found for this signature in database
GPG Key ID: 449E073F9DC10735
1 changed files with 2 additions and 1 deletions

View File

@ -1218,8 +1218,9 @@ bool ggml_metal_device_supports_op(ggml_metal_device_t dev, const struct ggml_te
(ggml_get_op_params_i32(op, 4) == 0) && (ggml_get_op_params_i32(op, 6) == 0);
case GGML_OP_PAD_REFLECT_1D:
case GGML_OP_TIMESTEP_EMBEDDING:
case GGML_OP_LEAKY_RELU:
return op->src[0]->type == GGML_TYPE_F32;
case GGML_OP_LEAKY_RELU:
return op->src[0]->type == GGML_TYPE_F32 || op->src[0]->type == GGML_TYPE_F16;
case GGML_OP_ARGSORT:
case GGML_OP_TOP_K:
case GGML_OP_ARANGE: