Fix -Wundef warnings due to use of unguarded SDL_AVX2_INTRINSICS
This commit is contained in:
1 parent
bb2737efbe
commit
547f53c4ba
1 file changed
+2
-2
@@ -291,7 +291,7 @@ SDL_TARGETING("avx") static void kernel_floats_add_avx(float *dest, const float
|
|||||||
}
|
}
|
||||||
#endif
|
#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) {
|
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) {
|
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)));
|
_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()) {
|
if (SDL_HasAVX2()) {
|
||||||
SDLTest_AssertCheck(SDL_TRUE, "CPU of test machine has AVX2 support.");
|
SDLTest_AssertCheck(SDL_TRUE, "CPU of test machine has AVX2 support.");
|
||||||
#if SDL_AVX2_INTRINSICS
|
#if defined(SDL_AVX2_INTRINSICS)
|
||||||
{
|
{
|
||||||
size_t size;
|
size_t size;
|
||||||
Sint32 *dest, *a, *b;
|
Sint32 *dest, *a, *b;
|
||||||
|
|||||||
Reference in new issue
Block a user