diff options
author | Zack Weinberg <zackw@panix.com> | 2021-03-16 13:22:45 -0400 |
---|---|---|
committer | Zack Weinberg <zackw@panix.com> | 2021-03-16 13:23:20 -0400 |
commit | 2defd89c480bad950cb0101ee7b1afb9c2265fd0 (patch) | |
tree | de148d1ac93042003126ea35c5fae5bbb5c3162e | |
parent | b05c1ff0ae8101ee49722bbb7d81486eeda81b56 (diff) | |
download | libxcrypt-2defd89c480bad950cb0101ee7b1afb9c2265fd0.tar.gz libxcrypt-2defd89c480bad950cb0101ee7b1afb9c2265fd0.tar.bz2 libxcrypt-2defd89c480bad950cb0101ee7b1afb9c2265fd0.zip |
Fix more CI failures.
This time it's spurious -Wcast-qual warnings with older clang.
(I continue to be Not Happy about yescrypt's lint problem, but
this one genuinely isn't its fault, _mm_prefetch is supposed
to be usable with const data.)
-rw-r--r-- | lib/alg-yescrypt-opt.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/alg-yescrypt-opt.c b/lib/alg-yescrypt-opt.c index b707196..60a6ccd 100644 --- a/lib/alg-yescrypt-opt.c +++ b/lib/alg-yescrypt-opt.c @@ -115,7 +115,12 @@ #endif #ifdef __SSE__ -#define PREFETCH(x, hint) _mm_prefetch((const char *)(x), (hint)); +#define PREFETCH(x, hint) _mm_prefetch((x), (hint)); +/* Older versions of clang have a bug in their xmmintrin.h that causes + spurious -Wcast-qual warnings on uses of _mm_prefetch. */ +# if defined __clang_major__ && __clang_major__ < 11 +# pragma clang diagnostic ignored "-Wcast-qual" +# endif #else #undef PREFETCH #endif |