From 4ad956470f8124edd08a669ed5c6e01a02b4ceab Mon Sep 17 00:00:00 2001 From: Frank Denis Date: Thu, 9 May 2024 22:21:10 +0200 Subject: [PATCH] Explicitly enabling evex512 is now required with LLVM 18 --- .../crypto_pwhash/argon2/argon2-fill-block-avx512f.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-avx512f.c b/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-avx512f.c index 033f7c21..ea20fa83 100644 --- a/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-avx512f.c +++ b/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-avx512f.c @@ -23,7 +23,11 @@ defined(HAVE_EMMINTRIN_H) && defined(HAVE_TMMINTRIN_H) && defined(HAVE_SMMINTRIN_H) # ifdef __clang__ -# pragma clang attribute push(__attribute__((target("sse2,ssse3,sse4.1,avx2,avx512f"))), apply_to = function) +# if __clang_major__ >= 18 +# pragma clang attribute push(__attribute__((target("sse2,ssse3,sse4.1,avx2,avx512f,evex512"))), apply_to = function) +# else +# pragma clang attribute push(__attribute__((target("sse2,ssse3,sse4.1,avx2,avx512f"))), apply_to = function) +# endif # elif defined(__GNUC__) # pragma GCC target("sse2,ssse3,sse4.1,avx2,avx512f") # endif