Commit f3181b3c authored by fbarchard@google.com's avatar fbarchard@google.com

Fix aligned version of SSSE3 alpha blend and re-enable SSE2 alpha blend for…

Fix aligned version of SSSE3 alpha blend and re-enable SSE2 alpha blend for performance evaluation on low end CPUs where pshufb is slow.
BUG=none
TEST=none
Review URL: https://webrtc-codereview.appspot.com/728009

git-svn-id: http://libyuv.googlecode.com/svn/trunk@322 16f28f9a-4ce2-e073-06de-1de4eb20be90
parent f877e719
Name: libyuv Name: libyuv
URL: http://code.google.com/p/libyuv/ URL: http://code.google.com/p/libyuv/
Version: 321 Version: 322
License: BSD License: BSD
License File: LICENSE License File: LICENSE
......
...@@ -11,6 +11,6 @@ ...@@ -11,6 +11,6 @@
#ifndef INCLUDE_LIBYUV_VERSION_H_ // NOLINT #ifndef INCLUDE_LIBYUV_VERSION_H_ // NOLINT
#define INCLUDE_LIBYUV_VERSION_H_ #define INCLUDE_LIBYUV_VERSION_H_
#define LIBYUV_VERSION 321 #define LIBYUV_VERSION 322
#endif // INCLUDE_LIBYUV_VERSION_H_ NOLINT #endif // INCLUDE_LIBYUV_VERSION_H_ NOLINT
...@@ -80,6 +80,9 @@ extern "C" { ...@@ -80,6 +80,9 @@ extern "C" {
#define HAS_CUMULATIVESUMTOAVERAGE_SSE2 #define HAS_CUMULATIVESUMTOAVERAGE_SSE2
#define HAS_ARGBSHADE_SSE2 #define HAS_ARGBSHADE_SSE2
#define HAS_ARGBAFFINEROW_SSE2 #define HAS_ARGBAFFINEROW_SSE2
// HAS_ARGBBLENDROW_SSE2 may be faster than SSSE3 version on some CPUs, so
// enable it here instead of LIBYUV_SSSE3_ONLY section.
#define HAS_ARGBBLENDROW_SSE2
#endif #endif
// The following are Windows only: // The following are Windows only:
...@@ -96,7 +99,6 @@ extern "C" { ...@@ -96,7 +99,6 @@ extern "C" {
!defined(LIBYUV_SSSE3_ONLY) !defined(LIBYUV_SSSE3_ONLY)
#define HAS_MIRRORROW_SSE2 #define HAS_MIRRORROW_SSE2
#define HAS_ARGBATTENUATE_SSE2 #define HAS_ARGBATTENUATE_SSE2
#define HAS_ARGBBLENDROW_SSE2
#endif #endif
// The following are available on Neon platforms // The following are available on Neon platforms
......
...@@ -2548,16 +2548,16 @@ void ARGBBlendRow_SSSE3(const uint8* src_argb0, const uint8* src_argb1, ...@@ -2548,16 +2548,16 @@ void ARGBBlendRow_SSSE3(const uint8* src_argb0, const uint8* src_argb1,
// 4 pixel loop. // 4 pixel loop.
".p2align 2 \n" ".p2align 2 \n"
"40: \n" "40: \n"
"movdqu (%0),%%xmm3 \n" "movdqa (%0),%%xmm3 \n"
"lea 0x10(%0),%0 \n" "lea 0x10(%0),%0 \n"
"movdqa %%xmm3,%%xmm0 \n" "movdqa %%xmm3,%%xmm0 \n"
"pxor %%xmm4,%%xmm3 \n" "pxor %%xmm4,%%xmm3 \n"
"movdqu (%1),%%xmm2 \n" "movdqa (%1),%%xmm2 \n"
"pshufb %4,%%xmm3 \n" "pshufb %4,%%xmm3 \n"
"pand %%xmm6,%%xmm2 \n" "pand %%xmm6,%%xmm2 \n"
"paddw %%xmm7,%%xmm3 \n" "paddw %%xmm7,%%xmm3 \n"
"pmullw %%xmm3,%%xmm2 \n" "pmullw %%xmm3,%%xmm2 \n"
"movdqu (%1),%%xmm1 \n" "movdqa (%1),%%xmm1 \n"
"lea 0x10(%1),%1 \n" "lea 0x10(%1),%1 \n"
"psrlw $0x8,%%xmm1 \n" "psrlw $0x8,%%xmm1 \n"
"por %%xmm4,%%xmm0 \n" "por %%xmm4,%%xmm0 \n"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment