Merge commit '096cc11ec102701a18951b4f0437d609081ca1dd'
authorMichael Niedermayer <michaelni@gmx.at>
Wed, 27 Feb 2013 10:59:25 +0000 (11:59 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Wed, 27 Feb 2013 10:59:31 +0000 (11:59 +0100)
* commit '096cc11ec102701a18951b4f0437d609081ca1dd':
  x86: vc1dsp: Move ff_avg_vc1_mspel_mc00_mmxext out of dsputil_mmx.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/x86/dsputil_mmx.c
libavcodec/x86/dsputil_mmx.h
libavcodec/x86/h264_qpel.c
libavcodec/x86/vc1dsp_init.c
libavcodec/x86/vc1dsp_mmx.c

index e331858..231e0c5 100644 (file)
@@ -130,8 +130,6 @@ void ff_put_no_rnd_pixels8_y2_exact_mmxext(uint8_t *block,
 void ff_put_no_rnd_pixels8_y2_exact_3dnow(uint8_t *block,
                                           const uint8_t *pixels,
                                           ptrdiff_t line_size, int h);
-void ff_avg_pixels8_mmxext(uint8_t *block, const uint8_t *pixels,
-                           ptrdiff_t line_size, int h);
 void ff_avg_pixels8_3dnow(uint8_t *block, const uint8_t *pixels,
                           ptrdiff_t line_size, int h);
 void ff_avg_pixels8_x2_mmxext(uint8_t *block, const uint8_t *pixels,
@@ -1382,12 +1380,6 @@ void ff_put_vc1_mspel_mc00_mmx(uint8_t *dst, const uint8_t *src,
 {
     ff_put_pixels8_mmx(dst, src, stride, 8);
 }
-
-void ff_avg_vc1_mspel_mc00_mmxext(uint8_t *dst, const uint8_t *src,
-                                  int stride, int rnd)
-{
-    ff_avg_pixels8_mmxext(dst, src, stride, 8);
-}
 #endif /* HAVE_YASM */
 
 #if CONFIG_DIRAC_DECODER
index 033a175..f365970 100644 (file)
@@ -22,7 +22,9 @@
 #ifndef AVCODEC_X86_DSPUTIL_MMX_H
 #define AVCODEC_X86_DSPUTIL_MMX_H
 
+#include <stddef.h>
 #include <stdint.h>
+
 #include "libavcodec/dsputil.h"
 #include "libavutil/x86/asm.h"
 
@@ -87,13 +89,15 @@ void ff_add_pixels_clamped_mmx(const int16_t *block, uint8_t *pixels, int line_s
 void ff_put_pixels_clamped_mmx(const int16_t *block, uint8_t *pixels, int line_size);
 void ff_put_signed_pixels_clamped_mmx(const int16_t *block, uint8_t *pixels, int line_size);
 
+void ff_avg_pixels8_mmxext(uint8_t *block, const uint8_t *pixels,
+                           ptrdiff_t line_size, int h);
+
 void ff_put_cavs_qpel8_mc00_mmxext(uint8_t *dst, uint8_t *src, int stride);
 void ff_avg_cavs_qpel8_mc00_mmxext(uint8_t *dst, uint8_t *src, int stride);
 void ff_put_cavs_qpel16_mc00_mmxext(uint8_t *dst, uint8_t *src, int stride);
 void ff_avg_cavs_qpel16_mc00_mmxext(uint8_t *dst, uint8_t *src, int stride);
 
 void ff_put_vc1_mspel_mc00_mmx(uint8_t *dst, const uint8_t *src, int stride, int rnd);
-void ff_avg_vc1_mspel_mc00_mmxext(uint8_t *dst, const uint8_t *src, int stride, int rnd);
 
 void ff_put_rv40_qpel8_mc33_mmx(uint8_t *block, uint8_t *pixels, int line_size);
 void ff_put_rv40_qpel16_mc33_mmx(uint8_t *block, uint8_t *pixels, int line_size);
index a467878..c1e7fb7 100644 (file)
@@ -31,7 +31,6 @@
 void ff_put_pixels4_mmxext(uint8_t *block, const uint8_t *pixels, int line_size, int h);
 void ff_avg_pixels4_mmxext(uint8_t *block, const uint8_t *pixels, int line_size, int h);
 void ff_put_pixels8_mmxext(uint8_t *block, const uint8_t *pixels, int line_size, int h);
-void ff_avg_pixels8_mmxext(uint8_t *block, const uint8_t *pixels, int line_size, int h);
 static void ff_put_pixels16_mmxext(uint8_t *block, const uint8_t *pixels,
                                    int line_size, int h)
 {
index 230d06f..3f0b67c 100644 (file)
@@ -27,6 +27,7 @@
 #include "libavutil/cpu.h"
 #include "libavutil/x86/cpu.h"
 #include "libavcodec/vc1dsp.h"
+#include "dsputil_mmx.h"
 #include "vc1dsp.h"
 #include "config.h"
 
@@ -60,6 +61,12 @@ static void vc1_h_loop_filter16_sse4(uint8_t *src, int stride, int pq)
     ff_vc1_h_loop_filter8_sse4(src,          stride, pq);
     ff_vc1_h_loop_filter8_sse4(src+8*stride, stride, pq);
 }
+
+static void avg_vc1_mspel_mc00_mmxext(uint8_t *dst, const uint8_t *src,
+                                      int stride, int rnd)
+{
+    ff_avg_pixels8_mmxext(dst, src, stride, 8);
+}
 #endif /* HAVE_YASM */
 
 void ff_put_vc1_chroma_mc8_nornd_mmx  (uint8_t *dst, uint8_t *src,
@@ -100,6 +107,8 @@ av_cold void ff_vc1dsp_init_x86(VC1DSPContext *dsp)
     if (mm_flags & AV_CPU_FLAG_MMXEXT) {
         ASSIGN_LF(mmxext);
         dsp->avg_no_rnd_vc1_chroma_pixels_tab[0] = ff_avg_vc1_chroma_mc8_nornd_mmxext;
+
+        dsp->avg_vc1_mspel_pixels_tab[0]         = avg_vc1_mspel_mc00_mmxext;
     } else if (mm_flags & AV_CPU_FLAG_3DNOW) {
         dsp->avg_no_rnd_vc1_chroma_pixels_tab[0] = ff_avg_vc1_chroma_mc8_nornd_3dnow;
     }
index 1c735eb..287e5a3 100644 (file)
@@ -720,9 +720,6 @@ av_cold void ff_vc1dsp_init_mmx(VC1DSPContext *dsp)
 
 av_cold void ff_vc1dsp_init_mmxext(VC1DSPContext *dsp)
 {
-#if HAVE_YASM
-        dsp->avg_vc1_mspel_pixels_tab[ 0] = ff_avg_vc1_mspel_mc00_mmxext;
-#endif /* HAVE_YASM */
         dsp->avg_vc1_mspel_pixels_tab[ 4] = avg_vc1_mspel_mc01_mmxext;
         dsp->avg_vc1_mspel_pixels_tab[ 8] = avg_vc1_mspel_mc02_mmxext;
         dsp->avg_vc1_mspel_pixels_tab[12] = avg_vc1_mspel_mc03_mmxext;