@@ -211,7 +211,8 @@ struct jit_uni_reorder_kernel_f32_t : public kernel_t, public jit_generator {
211
211
&& utils::everyone_is (0 , p.ioff , p.ooff ) /* do we need this? */
212
212
&& utils::one_of (p.beta , 0 .f , 1 .f ) /* anything else? */
213
213
&& simple_impl_desc_init (p, nullptr ) && mayiuse (sse41)
214
- && IMPLICATION (utils::one_of (bf16, p.itype , p.otype ),
214
+ && IMPLICATION (bf16 == p.itype , mayiuse (avx2))
215
+ && IMPLICATION ((bf16 == p.otype ) && (bf16 != p.itype ),
215
216
mayiuse (avx512_core) || mayiuse (avx2_vnni_2))
216
217
&& IMPLICATION (utils::one_of (f16, p.itype , p.otype ),
217
218
mayiuse (avx512_core_fp16) || mayiuse (avx2))
@@ -1657,7 +1658,7 @@ struct jit_uni_reorder_kernel_f32_t : public kernel_t, public jit_generator {
1657
1658
otype_sz_ = data_type_size (prb_.otype );
1658
1659
stype_sz_ = sizeof (float );
1659
1660
if (prb_.otype == data_type::bf16 && !mayiuse (avx512_core_bf16)
1660
- && !mayiuse (avx2_vnni_2)) {
1661
+ && !mayiuse (avx2_vnni_2) && mayiuse (avx512_core) ) {
1661
1662
bf16_emu_ = utils::make_unique<bf16_emulation_t >(this ,
1662
1663
bf16_emu_reserv_1_, bf16_emu_reserv_2_, bf16_emu_reserv_3_,
1663
1664
bf16_emu_scratch_, bf16_emu_reserv_4_);
0 commit comments