aarch64: Generalize Windows cpu detection to any Windows variant
authorMartin Storsjo <martin@martin.st>
Fri, 15 Sep 2023 09:29:32 +0000 (12:29 +0300)
committerJames Zern <jzern@google.com>
Mon, 18 Sep 2023 18:56:51 +0000 (11:56 -0700)
This cpu detection implementation doesn't do anything MSVC specific,
it just calls the IsProcessorFeaturePresent function. This can be
compiled with mingw compilers just as well.

Change-Id: I55e607a47c8f5b70d9f707ef96b2fa7553f2f79f

vpx_ports/aarch64_cpudetect.c
vpx_ports/arm_cpudetect.h

index a3054ad..dad081c 100644 (file)
@@ -58,7 +58,7 @@ static int arm_get_cpu_caps(void) {
   return flags;
 }
 
-#elif defined(_MSC_VER)  // end __APPLE__
+#elif defined(_WIN32)  // end __APPLE__
 
 static int arm_get_cpu_caps(void) {
   int flags = 0;
index 24095d1..881397a 100644 (file)
@@ -14,7 +14,7 @@
 #include "vpx_config.h"
 #include "vpx_ports/arm.h"
 
-#if defined(_MSC_VER)
+#if defined(_WIN32)
 #undef WIN32_LEAN_AND_MEAN
 #define WIN32_LEAN_AND_MEAN
 #undef WIN32_EXTRA_LEAN