summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2015-10-26 22:29:05 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2015-10-26 22:29:05 +0000
commit2b474794d03d3f52cd1474cf31f5631029d7c141 (patch)
tree4cda260b0c2bbe8dacf5fcb86a80f8274f4e3569
parent38a129e5d3bbb438a63f2a390c4579ac74671a4a (diff)
downloadrspamd-2b474794d03d3f52cd1474cf31f5631029d7c141.tar.gz
rspamd-2b474794d03d3f52cd1474cf31f5631029d7c141.zip
Fix assembly in i386 mode.
-rw-r--r--src/libcryptobox/CMakeLists.txt32
1 files changed, 16 insertions, 16 deletions
diff --git a/src/libcryptobox/CMakeLists.txt b/src/libcryptobox/CMakeLists.txt
index 171a4d0f9..a5c883ec5 100644
--- a/src/libcryptobox/CMakeLists.txt
+++ b/src/libcryptobox/CMakeLists.txt
@@ -14,6 +14,22 @@ SET(BLAKE2SRC ${CMAKE_CURRENT_SOURCE_DIR}/blake2/blake2.c
SET(CURVESRC ${CMAKE_CURRENT_SOURCE_DIR}/curve25519/ref.c
${CMAKE_CURRENT_SOURCE_DIR}/curve25519/curve25519.c)
+SET(ASM_CODE "
+ .macro TEST1 op
+ \\op %eax, %eax
+ .endm
+ TEST1 xorl
+ ")
+ASM_OP(HAVE_SLASHMACRO "slash macro convention")
+
+SET(ASM_CODE "
+ .macro TEST1 op
+ $0 %eax, %eax
+ .endm
+ TEST1 xorl
+ ")
+ASM_OP(HAVE_DOLLARMACRO "dollar macro convention")
+
# For now we support only x86_64 architecture with optimizations
IF("${ARCH}" STREQUAL "x86_64")
SET(ASM_CODE "vpaddq %ymm0, %ymm0, %ymm0")
@@ -28,22 +44,6 @@ IF("${ARCH}" STREQUAL "x86_64")
ASM_OP(HAVE_SSSE3 "ssse3")
SET(ASM_CODE "pblendw \$0, %xmm0, %xmm0")
ASM_OP(HAVE_SSE41 "sse41")
-
- SET(ASM_CODE "
- .macro TEST1 op
- \\op %eax, %eax
- .endm
- TEST1 xorl
- ")
- ASM_OP(HAVE_SLASHMACRO "slash macro convention")
-
- SET(ASM_CODE "
- .macro TEST1 op
- $0 %eax, %eax
- .endm
- TEST1 xorl
- ")
- ASM_OP(HAVE_DOLLARMACRO "dollar macro convention")
if ("${CMAKE_C_COMPILER_ID}" STREQUAL "Clang" OR "${CMAKE_C_COMPILER_ID}" STREQUAL "GNU")
SET(POLYSRC ${POLYSRC} ${CMAKE_CURRENT_SOURCE_DIR}/poly1305/ref-64.c)