Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1047)

Unified Diff: source/cpu_id.cc

Issue 2285683002: Add MIPS SIMD Arch (MSA) optimized MirrorRow function (Closed)
Patch Set: Changes as per review comments Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: source/cpu_id.cc
diff --git a/source/cpu_id.cc b/source/cpu_id.cc
index 84927ebc3e2b730fd637ee3519d6881c8751d556..4cb076d6ad94c33cc206194e21f74fcd1a89db81 100644
--- a/source/cpu_id.cc
+++ b/source/cpu_id.cc
@@ -259,6 +259,15 @@ int InitCpuFlags(void) {
cpu_info &= ~kCpuHasDSPR2;
}
#endif
+#if defined(__mips__) && defined(__linux__)
fbarchard1 2016/09/14 01:48:04 this code block can be moved inside the previous #
manojkumar.bhosale 2016/09/14 12:45:30 Done.
+#if defined(__mips_msa)
+ cpu_info |= kCpuHasMSA;
fbarchard1 2016/09/14 01:48:04 this is a compile time test. If built with MSA, b
manojkumar.bhosale 2016/09/14 12:45:30 Done.
+#endif
+ cpu_info |= kCpuHasMIPS;
+ if (getenv("LIBYUV_DISABLE_MSA")) {
+ cpu_info &= ~kCpuHasMSA;
+ }
+#endif
#if defined(__arm__) || defined(__aarch64__)
// gcc -mfpu=neon defines __ARM_NEON__
// __ARM_NEON__ generates code that requires Neon. NaCL also requires Neon.

Powered by Google App Engine
This is Rietveld 408576698