Skip to content

Commit 474527f

Browse files
committed
cpu: x64: brgemm unrolled kernel: don't load from dst if bd_mask exists
1 parent 87e8ea9 commit 474527f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/cpu/x64/brgemm/jit_brgemm_amx_uker.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1623,7 +1623,8 @@ void jit_brgemm_amx_uker_base_t::generate() {
16231623
// if beta == 1 and C datatype is f32 it is better to perform addition by
16241624
// reading tiles directly from C instead of by reading/writing by vectors
16251625
may_load_accumulators_
1626-
= (brg.beta == 1.f && brg.dt_c == data_type::f32 && !brg.is_bf32);
1626+
= (brg.beta == 1.f && brg.dt_c == data_type::f32 && !brg.is_bf32)
1627+
&& brg.brgattr.bd_mask_level == 0;
16271628
need_to_apply_alpha_beta_
16281629
= (brg.beta != 0.f && !may_load_accumulators_) || brg.alpha != 1.f;
16291630
const bool has_zero_points = !everyone_is(brgemm_broadcast_t::none,

0 commit comments

Comments
 (0)