From 547f53c4ba37ea56091634c673c4c15b06942fbb Mon Sep 17 00:00:00 2001 From: Anonymous Maarten Date: Mon, 27 Mar 2023 19:00:43 +0200 Subject: [PATCH] Fix -Wundef warnings due to use of unguarded SDL_AVX2_INTRINSICS --- test/testautomation_intrinsics.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/testautomation_intrinsics.c b/test/testautomation_intrinsics.c index e513641771..91bc76c68a 100644 --- a/test/testautomation_intrinsics.c +++ b/test/testautomation_intrinsics.c @@ -291,7 +291,7 @@ SDL_TARGETING("avx") static void kernel_floats_add_avx(float *dest, const float } #endif -#if SDL_AVX2_INTRINSICS +#if defined(SDL_AVX2_INTRINSICS) SDL_TARGETING("avx2") static void kernel_ints_add_avx2(Sint32 *dest, const Sint32 *a, const Sint32 *b, size_t size) { for (; size >= 8; size -= 8, dest += 8, a += 8, b += 8) { _mm256_storeu_si256((__m256i*)dest, _mm256_add_epi32(_mm256_loadu_si256((__m256i*)a), _mm256_loadu_si256((__m256i*)b))); @@ -567,7 +567,7 @@ static int intrinsics_testAVX2(void *arg) { if (SDL_HasAVX2()) { SDLTest_AssertCheck(SDL_TRUE, "CPU of test machine has AVX2 support."); -#if SDL_AVX2_INTRINSICS +#if defined(SDL_AVX2_INTRINSICS) { size_t size; Sint32 *dest, *a, *b;