AMD Zen3 architecture supports the VAES instruction set but not the 512bit variants, add a feature gate on AVX512F to avoid raising a compile error (due to __m512i being undefined) whenever a user imports the intrinsic module.
Details
Diff Detail
Event Timeline
We can't use preprocessor defines in the intrinsic header files. It prevents being able to use the intrinsics with attribute(target("avx512f,vaes")). What's preventing __m512i from being defined?
Are you compiling in MSVC compatibility mode?
__VAES__ is defined but __AVX512F__ is not hence avx512fintrin.h is never included in immintrin.h.
I think I've fixed this in 3fb40ce167ff5f05afadf8f525ff9e17350d6d7f. We need to use the preprocessor define that says avx512fintrin.h was included rather than the feature define. We already did a similar thing in gfniintrin.h.
clang-tidy: error: "Never use <vaesintrin.h> directly; include <immintrin.h> instead." [clang-diagnostic-error]
not useful