From 4793296821c61c75b4af2f24fb542921ee931aaf Mon Sep 17 00:00:00 2001 From: Fadi Arafeh Date: Mon, 18 Nov 2024 14:28:14 +0000 Subject: [PATCH] cpu: aarch64: Re-enable ACL indirect conv for BF16 --- src/cpu/aarch64/acl_indirect_gemm_convolution.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/cpu/aarch64/acl_indirect_gemm_convolution.cpp b/src/cpu/aarch64/acl_indirect_gemm_convolution.cpp index 19ee68062da..44cd03620d9 100644 --- a/src/cpu/aarch64/acl_indirect_gemm_convolution.cpp +++ b/src/cpu/aarch64/acl_indirect_gemm_convolution.cpp @@ -96,11 +96,13 @@ status_t acl_indirect_gemm_convolution_fwd_t::pd_t::init(engine_t *engine) { const bool is_fp16_ok = expect_data_types(f16, f16, f16, f16, undef) && attr()->has_default_values(smask_t::post_ops, f16); + const bool is_bf16_ok = expect_data_types(bf16, bf16, bf16, bf16, undef) + && attr_.post_ops_.len() == 0; const bool is_fp32_ok = expect_data_types(f32, f32, f32, f32, undef) && attr()->has_default_values( smask_t::post_ops | smask_t::fpmath_mode, f32); bool ok = is_fwd() && set_default_alg_kind(alg_kind::convolution_direct) - && utils::one_of(true, is_fp16_ok, is_fp32_ok) + && utils::one_of(true, is_fp16_ok, is_bf16_ok, is_fp32_ok) && !has_zero_dim_memory(); if (!ok) return status::unimplemented;