From: Daniel Salzman Date: Sat, 18 Oct 2025 17:05:02 +0000 (+0200) Subject: kru: don't expect obsolete Clang < 12 for optimized implementation X-Git-Tag: v3.4.9~10 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0133fbea66c8098221dfd15cf5cbc6cbcf3fbc00;p=thirdparty%2Fknot-dns.git kru: don't expect obsolete Clang < 12 for optimized implementation --- diff --git a/src/knot/modules/rrl/kru-avx2.c b/src/knot/modules/rrl/kru-avx2.c index a4a6d1960d..4e7a939191 100644 --- a/src/knot/modules/rrl/kru-avx2.c +++ b/src/knot/modules/rrl/kru-avx2.c @@ -14,17 +14,14 @@ along with this program. If not, see . */ -// Checked with clang 5 (2017) and gcc 6 (2016). +// Checked with clang 12 (2021) and gcc 6 (2016). // For other cases we'll rather keep just the generic implementation. -#if defined(__x86_64__) && (__clang_major__ >= 5 || __GNUC__ >= 6) && !defined(__APPLE__) +#if defined(__x86_64__) && (__clang_major__ >= 12 || __GNUC__ >= 6) && !defined(__APPLE__) // This file has code for new-ish x86 (2015+ usually, Atom 2021+) - AES + AVX2 -#if __clang_major__ >= 12 +#ifdef __clang__ #pragma clang attribute push (__attribute__((target("arch=x86-64-v3,aes"))), \ apply_to = function) -#elif __clang__ - #pragma clang attribute push (__attribute__((target("avx2,aes"))), \ - apply_to = function) #else #pragma GCC push_options #if __GNUC__ >= 11