aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorLasse Collin <lasse.collin@tukaani.org>2023-01-07 19:31:15 +0200
committerLasse Collin <lasse.collin@tukaani.org>2023-01-09 16:58:27 +0200
commit52bc1ee34dda9bb6fb40175e5952863066681b77 (patch)
tree90b492f6fb5f18ffab6177f9bc86fb03a543b927 /CMakeLists.txt
parentTests: Creates test_index_hash.c (diff)
downloadxz-52bc1ee34dda9bb6fb40175e5952863066681b77.tar.xz
Build: Require that _mm_set_epi64x() is usable to enable CLMUL support.
VS2013 doesn't have _mm_set_epi64x() so this way CLMUL gets disabled with VS2013. Thanks to Iouri Kharon for the bug report.
Diffstat (limited to '')
-rw-r--r--CMakeLists.txt3
1 files changed, 2 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3a58d740..ef17563e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -434,8 +434,9 @@ if(HAVE_IMMINTRIN_H)
#if (defined(__GNUC__) || defined(__clang__)) && !defined(__EDG__)
__attribute__((__target__(\"ssse3,sse4.1,pclmul\")))
#endif
- __m128i my_clmul(__m128i a, __m128i b)
+ __m128i my_clmul(__m128i a)
{
+ const __m128i b = _mm_set_epi64x(1, 2);
return _mm_clmulepi64_si128(a, b, 0);
}
int main(void) { return 0; }