diff --git a/include/SDL3/SDL_intrin.h b/include/SDL3/SDL_intrin.h index adec1346d..d3fb696ff 100644 --- a/include/SDL3/SDL_intrin.h +++ b/include/SDL3/SDL_intrin.h @@ -113,6 +113,7 @@ _m_prefetch(void *__P) #if defined(__loongarch_asx) && !defined(SDL_DISABLE_LASX) #include #endif +#if defined(__x86_64__) || defined(_M_X64) || defined(__i386__) || defined(_M_IX86) #if (defined(__AVX__) || defined(SDL_HAS_TARGET_ATTRIBS)) && !defined(SDL_DISABLE_AVX) #include #endif @@ -128,5 +129,6 @@ _m_prefetch(void *__P) #if (defined(__SSE3__) || defined(SDL_HAS_TARGET_ATTRIBS)) && !defined(SDL_DISABLE_SSE3) #include #endif +#endif /**/ #endif /* SDL_intrin_h_ */ diff --git a/src/SDL_internal.h b/src/SDL_internal.h index fd65cf864..9e8487e2f 100644 --- a/src/SDL_internal.h +++ b/src/SDL_internal.h @@ -194,6 +194,8 @@ #define HAVE_NEON_INTRINSICS 1 #endif +#if defined(__x86_64__) || defined(_M_X64) || defined(__i386__) || defined(_M_IX86) + #if (defined(__MMX__) || defined(SDL_HAS_TARGET_ATTRIBS)) && !defined(SDL_DISABLE_MMX) #define HAVE_MMX_INTRINSICS 1 #endif @@ -214,6 +216,8 @@ #define HAVE_AVX_INTRINSICS 1 #endif +#endif /* x86/x64 */ + #if defined(__loongarch_sx) && !defined(SDL_DISABLE_LSX) #define HAVE_LSX_INTRINSICS 1 #endif