mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-05-24 22:09:54 +00:00
apply simplified sve2 macro protection
This commit is contained in:
committed by
Sam Lantinga
parent
296231e999
commit
8d9d6b1b2b
@@ -25,7 +25,7 @@
|
||||
#include "SDL_pixels_c.h"
|
||||
#include "SDL_surface_c.h"
|
||||
|
||||
#if defined(SDL_SVE2_INTRINSICS) && (__ARM_ARCH >= 8) && (defined(__aarch64__) || defined(_M_ARM64))
|
||||
#ifdef SDL_SVE2_INTRINSICS
|
||||
#include "./arm/SDL_sve2_blit_A.h"
|
||||
#endif
|
||||
|
||||
@@ -1481,7 +1481,7 @@ SDL_BlitFunc SDL_CalculateBlitA(SDL_Surface *surface)
|
||||
}
|
||||
|
||||
case 2:
|
||||
#if defined(SDL_SVE2_INTRINSICS) && (__ARM_ARCH >= 8) && (defined(__aarch64__) || defined(_M_ARM64))
|
||||
#ifdef SDL_SVE2_INTRINSICS
|
||||
if (SDL_HasSVE2()) {
|
||||
if (sf->bytes_per_pixel == 4 &&
|
||||
df->bytes_per_pixel == 2 &&
|
||||
@@ -1519,11 +1519,11 @@ SDL_BlitFunc SDL_CalculateBlitA(SDL_Surface *surface)
|
||||
return Blit8888to8888PixelAlphaSwizzleLSX;
|
||||
}
|
||||
#endif
|
||||
#if defined(SDL_SVE2_INTRINSICS) && (__ARM_ARCH >= 8) && (defined(__aarch64__) || defined(_M_ARM64))
|
||||
#ifdef SDL_SVE2_INTRINSICS
|
||||
if (SDL_HasSVE2()
|
||||
/* NEON is faster than SVE2 when vector size is 128bit */
|
||||
#if defined(SDL_NEON_INTRINSICS)
|
||||
&& SDL_GetSVEVectorSize() > 128
|
||||
&& (SDL_GetSVEVectorSize() > 128 || !SDL_HasNEON())
|
||||
#endif
|
||||
) {
|
||||
// To prevent "unused function" compiler warnings/errors
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
#include "SDL_surface_c.h"
|
||||
#include "SDL_blit_copy.h"
|
||||
|
||||
#if defined(SDL_SVE2_INTRINSICS) && (__ARM_ARCH >= 8) && (defined(__aarch64__) || defined(_M_ARM64))
|
||||
#ifdef SDL_SVE2_INTRINSICS
|
||||
#include "./arm/SDL_sve2_blit_N.h"
|
||||
#endif
|
||||
|
||||
@@ -3121,7 +3121,7 @@ SDL_BlitFunc SDL_CalculateBlitN(SDL_Surface *surface)
|
||||
return Blit8888to8888PixelSwizzleSSE41;
|
||||
}
|
||||
#endif
|
||||
#if defined(SDL_SVE2_INTRINSICS) && (__ARM_ARCH >= 8) && (defined(__aarch64__) || defined(_M_ARM64))
|
||||
#ifdef SDL_SVE2_INTRINSICS
|
||||
if (SDL_HasSVE2()) {
|
||||
return Blit8888to8888PixelSwizzleSVE2;
|
||||
}
|
||||
@@ -3132,7 +3132,7 @@ SDL_BlitFunc SDL_CalculateBlitN(SDL_Surface *surface)
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#if defined(SDL_SVE2_INTRINSICS) && (__ARM_ARCH >= 8) && (defined(__aarch64__) || defined(_M_ARM64))
|
||||
#ifdef SDL_SVE2_INTRINSICS
|
||||
if (SDL_HasSVE2()) {
|
||||
/* RGBA8888/ARGB8888/XRGB8888 -> RGB565 */
|
||||
if (srcfmt->bytes_per_pixel == 4 &&
|
||||
|
||||
Reference in New Issue
Block a user