From 58770bd163912925a41f12d252b215ed18eac7a3 Mon Sep 17 00:00:00 2001 From: "Wang, Xiang" Date: Sun, 6 Jul 2025 21:49:59 +0800 Subject: [PATCH] Detect and enable LSX/LASX on LoongArch based on compiler predefined macros. --- ppsspp_config.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/ppsspp_config.h b/ppsspp_config.h index d38c4be254..faef7e4780 100644 --- a/ppsspp_config.h +++ b/ppsspp_config.h @@ -81,9 +81,15 @@ //https://github.com/gcc-mirror/gcc/blob/master/gcc/config/loongarch/loongarch-c.cc #define PPSSPP_ARCH_LOONGARCH64 1 #define PPSSPP_ARCH_64BIT 1 - #define PPSSPP_ARCH_LOONGARCH64_LSX 1 -#endif + #if defined(__loongarch_asx) + #define PPSSPP_ARCH_LOONGARCH64_LASX 1 + #endif + + #if defined(__loongarch_asx) || defined(__loongarch_sx) + #define PPSSPP_ARCH_LOONGARCH64_LSX 1 + #endif +#endif // PLATFORM defines #if defined(_WIN32) // Covers both 32 and 64bit Windows