diff --git a/CMakeLists.txt b/CMakeLists.txt index 92c9929cff..d68552ccd8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -115,6 +115,9 @@ if (NOT ENABLE_GENERIC) detect_architecture("__i386__" x86) detect_architecture("__arm__" ARM) detect_architecture("__aarch64__" ARM64) + if (${ARCHITECTURE} STREQUAL "x86_64" AND ${CMAKE_SYSTEM_NAME} STREQUAL "Linux") + add_compile_options(-march=ivybridge -mbmi -mfma -mlzcnt -mno-rdrnd -mtune=haswell) + endif() endif() endif()