commit b066f62: [Minor] Always enable sse2 on x86_64
Vsevolod Stakhov
vsevolod at highsecure.ru
Thu Jun 27 14:42:03 UTC 2019
Author: Vsevolod Stakhov
Date: 2019-06-27 14:16:12 +0100
URL: https://github.com/rspamd/rspamd/commit/b066f62bfafd0e3dc0ebb181e0990fede4f32d47
[Minor] Always enable sse2 on x86_64
---
CMakeLists.txt | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index b3fd7cae1..80e00e67e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -74,6 +74,17 @@ IF (NOT "${ARCH}" STREQUAL "x86_64")
SET(ENABLE_HYPERSCAN "OFF")
ENDIF()
+IF ("${ARCH}" STREQUAL "x86_64")
+ MESSAGE(STATUS "Enable sse2 on x86_64 architecture")
+ IF((CMAKE_C_COMPILER_ID MATCHES "GNU") OR (CMAKE_C_COMPILER_ID MATCHES "Clang"))
+ ADD_COMPILE_OPTIONS(-msse2)
+ ELSEIF(CMAKE_C_COMPILER_ID MATCHES "Intel")
+ ADD_COMPILE_OPTIONS(/QxSSE2)
+ ELSEIF((CMAKE_C_COMPILER_ID MATCHES "MSVC"))
+ ADD_COMPILE_OPTIONS(/arch:SSE2)
+ ENDIF()
+ENDIF()
+
IF(ENABLE_PCRE2 MATCHES "ON")
SET(WITH_PCRE2 1)
# For utf8 API
More information about the Commits
mailing list