Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 280b305

Browse files
antonvorazhai219
authored andcommittedDec 3, 2024··
[FORK][FEATURE] jit_uni_reorder: relaxed isa condition to enable FP16 precision support on AVX2 platforms
The feature is required to enable fast FP16->BF16/FP32 precision conversion. Most commonly used for fast weights decompression which improves model compilation time.
1 parent 27ff9bc commit 280b305

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

‎src/cpu/x64/jit_uni_reorder.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ struct jit_uni_reorder_kernel_f32_t : public kernel_t, public jit_generator {
214214
&& IMPLICATION(utils::one_of(bf16, p.itype, p.otype),
215215
mayiuse(avx512_core) || mayiuse(avx2_vnni_2))
216216
&& IMPLICATION(utils::one_of(f16, p.itype, p.otype),
217-
mayiuse(avx512_core_fp16) || mayiuse(avx2_vnni_2))
217+
mayiuse(avx512_core_fp16) || mayiuse(avx2))
218218
&& IMPLICATION(utils::one_of(f8_e5m2, p.itype, p.otype)
219219
|| utils::one_of(f8_e4m3, p.itype, p.otype),
220220
mayiuse(avx512_core_amx))
@@ -313,7 +313,7 @@ struct jit_uni_reorder_kernel_f32_t : public kernel_t, public jit_generator {
313313
vcvtph2psx(dst, src);
314314
else
315315
vcvtph2psx(dst, Xmm(src.getIdx()));
316-
} else if (is_superset(isa_, avx2_vnni_2)) {
316+
} else if (is_superset(isa_, avx2)) {
317317
if (src.isMEM())
318318
vcvtph2ps(dst, src);
319319
else

0 commit comments

Comments
 (0)
Please sign in to comment.