[FFmpeg-cvslog] x86: hevc_mc: remove unneeded shift

Christophe Gisquet git at videolan.org
Sun Jun 1 23:46:46 CEST 2014


ffmpeg | branch: master | Christophe Gisquet <christophe.gisquet at gmail.com> | Sun Jun  1 14:12:58 2014 +0000| [dcd2a6ca36a42b39867c39720344422161893178] | committer: Michael Niedermayer

x86: hevc_mc: remove unneeded shift

The immediate value may be 0.

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=dcd2a6ca36a42b39867c39720344422161893178
---

 libavcodec/x86/hevc_mc.asm |   10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/libavcodec/x86/hevc_mc.asm b/libavcodec/x86/hevc_mc.asm
index 0c1a431..5cf37d0 100644
--- a/libavcodec/x86/hevc_mc.asm
+++ b/libavcodec/x86/hevc_mc.asm
@@ -379,8 +379,10 @@ QPEL_TABLE 10, 4, w, sse4
     pmaddwd           m3, %4
     paddd             m1, m3
 %endif
+%if %1 != 8
     psrad             m0, %1-8
     psrad             m1, %1-8
+%endif
     packssdw          m0, m1
 %endif
 %endmacro
@@ -408,7 +410,9 @@ QPEL_TABLE 10, 4, w, sse4
     paddd             m0, m2
     paddd             m4, m6
     paddd             m0, m4
+%if %2 != 8
     psrad             m0, %2-8
+%endif
 %if %1 > 4
     pmaddwd           m1, [rfilterq + %3q*8   ]
     pmaddwd           m3, [rfilterq + %3q*8+16]
@@ -417,8 +421,10 @@ QPEL_TABLE 10, 4, w, sse4
     paddd             m1, m3
     paddd             m5, m7
     paddd             m1, m5
+%if %2 != 8
     psrad             m1, %2-8
 %endif
+%endif
     p%4               m0, m1
 %endif
 %endmacro
@@ -449,7 +455,9 @@ QPEL_TABLE 10, 4, w, sse4
     paddd             m0, m2
     paddd             m4, m6
     paddd             m0, m4
+%if %2 != 8
     psrad             m0, %2-8
+%endif
 %if %1 > 4
     pmaddwd           m1, m12
     pmaddwd           m3, m13
@@ -458,9 +466,11 @@ QPEL_TABLE 10, 4, w, sse4
     paddd             m1, m3
     paddd             m5, m7
     paddd             m1, m5
+%if %2 != 8
     psrad             m1, %2-8
 %endif
 %endif
+%endif
 %endmacro
 
 %macro BI_COMPUTE 7     ; width, bitd, src1l, src1h, scr2l, scr2h, pw



More information about the ffmpeg-cvslog mailing list