[x265] [PATCH] sse_pp8: Eliminated shift

praveen at multicorewareinc.com praveen at multicorewareinc.com
Fri Aug 16 14:40:15 CEST 2013


# HG changeset patch
# User praveentiwari
# Date 1376656788 -19800
# Node ID c9e01bc92c308c64e5183312d179822154782e6a
# Parent  1cf5ed68ab58a0ab891d53dd3d810c6b2b0c7af5
sse_pp8: Eliminated shift

diff -r 1cf5ed68ab58 -r c9e01bc92c30 source/common/vec/sse.inc
--- a/source/common/vec/sse.inc	Fri Aug 16 02:25:38 2013 -0500
+++ b/source/common/vec/sse.inc	Fri Aug 16 18:09:48 2013 +0530
@@ -69,8 +69,8 @@
         fref += strideFref;
     }
 
-    sum = _mm_add_epi32(sum, _mm_srli_si128(sum, 8));
-    sum = _mm_add_epi32(sum, _mm_srli_si128(sum, 4));
+    sum = _mm_hadd_epi32(sum, sum);
+    sum = _mm_hadd_epi32(sum, sum);
     return _mm_cvtsi128_si32(sum);
 }
 


More information about the x265-devel mailing list