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

Unified Diff: source/planar_functions.cc

Issue 2397693002: Add MSA optimized YUY2ToI422, YUY2ToI420, UYVYToI422, UYVYToI420 functions (Closed)
Patch Set: Created 4 years, 2 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
« no previous file with comments | « source/convert.cc ('k') | source/row_any.cc » ('j') | source/row_msa.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: source/planar_functions.cc
diff --git a/source/planar_functions.cc b/source/planar_functions.cc
index 53248ee34d0d38f1924e93d8afb318f37625559f..55e598fd3e0405c8b281fd60fb7ebb18a9021f5a 100644
--- a/source/planar_functions.cc
+++ b/source/planar_functions.cc
@@ -480,6 +480,18 @@ int YUY2ToI422(const uint8* src_yuy2, int src_stride_yuy2,
}
}
#endif
+#if defined(HAS_YUY2TOYROW_MSA)
+ if (TestCpuFlag(kCpuHasMSA)) {
+ YUY2ToYRow = YUY2ToYRow_Any_MSA;
+ if (width >= 16) {
fbarchard1 2016/10/05 22:03:58 todo - make Any handle remainder better so this te
manojkumar.bhosale 2016/10/07 10:42:09 Done.
+ YUY2ToUV422Row = YUY2ToUV422Row_Any_MSA;
+ }
+ if (IS_ALIGNED(width, 64)) {
+ YUY2ToYRow = YUY2ToYRow_MSA;
+ YUY2ToUV422Row = YUY2ToUV422Row_MSA;
+ }
+ }
+#endif
for (y = 0; y < height; ++y) {
YUY2ToUV422Row(src_yuy2, dst_u, dst_v, width);
@@ -552,6 +564,18 @@ int UYVYToI422(const uint8* src_uyvy, int src_stride_uyvy,
}
}
#endif
+#if defined(HAS_UYVYTOYROW_MSA)
+ if (TestCpuFlag(kCpuHasMSA)) {
+ UYVYToYRow = UYVYToYRow_Any_MSA;
+ if (width >= 16) {
+ UYVYToUV422Row = UYVYToUV422Row_Any_MSA;
+ }
+ if (IS_ALIGNED(width, 64)) {
+ UYVYToYRow = UYVYToYRow_MSA;
+ UYVYToUV422Row = UYVYToUV422Row_MSA;
+ }
+ }
+#endif
for (y = 0; y < height; ++y) {
UYVYToUV422Row(src_uyvy, dst_u, dst_v, width);
« no previous file with comments | « source/convert.cc ('k') | source/row_any.cc » ('j') | source/row_msa.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698