diff --git a/cmake/QtCompilerOptimization.cmake b/cmake/QtCompilerOptimization.cmake index 151d06925b..5ca28c4de4 100644 --- a/cmake/QtCompilerOptimization.cmake +++ b/cmake/QtCompilerOptimization.cmake @@ -24,6 +24,21 @@ if (MSVC) set(QT_CFLAGS_SSE4_2 "${QT_CFLAGS_SSE2}") set(QT_CFLAGS_AESNI "${QT_CFLAGS_SSE2}") set(QT_CFLAGS_SHANI "${QT_CFLAGS_SSE2}") + + # FIXME to be Visual Studio version specific, like in mkspecs/common/msvc-version.conf + set(QT_CFLAGS_AVX "-arch:AVX") + set(QT_CFLAGS_AVX2 "-arch:AVX2") + set(QT_CFLAGS_F16C "-arch:AVX") + set(QT_CFLAGS_RDRND "") + set(QT_CFLAGS_AVX512F "-arch:AVX512") + set(QT_CFLAGS_AVX512ER "-arch:AVX512") + set(QT_CFLAGS_AVX512CD "-arch:AVX512") + set(QT_CFLAGS_AVX512PF "-arch:AVX512") + set(QT_CFLAGS_AVX512DQ "-arch:AVX512") + set(QT_CFLAGS_AVX512BW "-arch:AVX512") + set(QT_CFLAGS_AVX512VL "-arch:AVX512") + set(QT_CFLAGS_AVX512IFMA "-arch:AVX512") + set(QT_CFLAGS_AVX512VBMI "-arch:AVX512") endif() if(GCC OR CLANG)