Skip to content

Commit 4c01b7a

Browse files
committed
Added AVX10.1 flags for gcc and clang
1 parent 8df7fb0 commit 4c01b7a

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

common/cmake/check_isa.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@
1414
// limitations under the License. //
1515
// ======================================================================== //
1616

17-
#if \
17+
if defined(__AVX10_1__)
18+
char const *info_isa = "ISA" ":" "AVX10.1"
19+
#elif \
1820
defined(__AVX512F__) && defined(__AVX512CD__) && \
1921
defined(__AVX512DQ__) && defined(__AVX512BW__) && defined(__AVX512VL__)
2022
char const *info_isa = "ISA" ":" "AVX512";

common/cmake/clang.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ ELSE ()
2828
_SET_IF_EMPTY(FLAGS_AVX "-mavx")
2929
_SET_IF_EMPTY(FLAGS_AVX2 "-mf16c -mavx2 -mfma -mlzcnt -mbmi -mbmi2")
3030
_SET_IF_EMPTY(FLAGS_AVX512 "-march=skx")
31+
_SET_IF_EMPTY(FLAGS_AVX10_1 "-mlzcnt -mavx10.1-512")
3132
ENDIF ()
3233

3334
IF (WIN32)

common/cmake/gnu.cmake

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ ELSE ()
1818
_SET_IF_EMPTY(FLAGS_AVX "-mavx")
1919
_SET_IF_EMPTY(FLAGS_AVX2 "-mf16c -mavx2 -mfma -mlzcnt -mbmi -mbmi2")
2020
_SET_IF_EMPTY(FLAGS_AVX512 "-march=skylake-avx512")
21+
_SET_IF_EMPTY(FLAGS_AVX10_1 "-mlzcnt -mavx10.1")
2122
ENDIF ()
2223

2324
OPTION(EMBREE_IGNORE_CMAKE_CXX_FLAGS "When enabled Embree ignores default CMAKE_CXX_FLAGS." ON)

0 commit comments

Comments
 (0)