mirror of
https://github.com/libretro/RetroArch
synced 2025-01-29 09:32:52 +00:00
performance.c - detect MMX too
This commit is contained in:
parent
1eafcfe1a2
commit
831f708ede
@ -613,6 +613,7 @@ struct retro_log_callback
|
||||
#define RETRO_SIMD_NEON (1 << 5)
|
||||
#define RETRO_SIMD_SSE3 (1 << 6)
|
||||
#define RETRO_SIMD_SSSE3 (1 << 7)
|
||||
#define RETRO_SIMD_MMX (1 << 8)
|
||||
|
||||
typedef uint64_t retro_perf_tick_t;
|
||||
typedef int64_t retro_time_t;
|
||||
|
@ -257,6 +257,9 @@ uint64_t rarch_get_cpu_features(void)
|
||||
|
||||
x86_cpuid(1, flags);
|
||||
|
||||
if (flags[3] & (1 << 23))
|
||||
cpu |= RETRO_SIMD_MMX;
|
||||
|
||||
if (flags[3] & (1 << 25))
|
||||
cpu |= RETRO_SIMD_SSE;
|
||||
|
||||
@ -273,6 +276,7 @@ uint64_t rarch_get_cpu_features(void)
|
||||
if ((flags[2] & avx_flags) == avx_flags)
|
||||
cpu |= RETRO_SIMD_AVX;
|
||||
|
||||
RARCH_LOG("[CPUID]: MMX: %u\n", !!(cpu & RETRO_SIMD_MMX));
|
||||
RARCH_LOG("[CPUID]: SSE: %u\n", !!(cpu & RETRO_SIMD_SSE));
|
||||
RARCH_LOG("[CPUID]: SSE2: %u\n", !!(cpu & RETRO_SIMD_SSE2));
|
||||
RARCH_LOG("[CPUID]: SSE3: %u\n", !!(cpu & RETRO_SIMD_SSE3));
|
||||
|
Loading…
x
Reference in New Issue
Block a user