changeset 8033:b661cf8690a1 libavcodec

VP3 loop filter is mmx2 not mmx
author conrad
date Sun, 19 Oct 2008 04:40:24 +0000
parents 0839f325edb5
children 9b690041e298
files i386/dsputil_mmx.c i386/vp3dsp_mmx.c i386/vp3dsp_mmx.h
diffstat 3 files changed, 10 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/i386/dsputil_mmx.c	Fri Oct 17 03:18:08 2008 +0000
+++ b/i386/dsputil_mmx.c	Sun Oct 19 04:40:24 2008 +0000
@@ -2593,11 +2593,6 @@
             c->h263_v_loop_filter= h263_v_loop_filter_mmx;
             c->h263_h_loop_filter= h263_h_loop_filter_mmx;
         }
-        if ((ENABLE_VP3_DECODER || ENABLE_THEORA_DECODER) &&
-            !(avctx->flags & CODEC_FLAG_BITEXACT)) {
-            c->vp3_v_loop_filter= ff_vp3_v_loop_filter_mmx;
-            c->vp3_h_loop_filter= ff_vp3_h_loop_filter_mmx;
-        }
         c->put_h264_chroma_pixels_tab[0]= put_h264_chroma_mc8_mmx_rnd;
         c->put_h264_chroma_pixels_tab[1]= put_h264_chroma_mc4_mmx;
         c->put_no_rnd_h264_chroma_pixels_tab[0]= put_h264_chroma_mc8_mmx_nornd;
@@ -2638,6 +2633,12 @@
                 c->avg_pixels_tab[1][3] = avg_pixels8_xy2_mmx2;
             }
 
+            if ((ENABLE_VP3_DECODER || ENABLE_THEORA_DECODER) &&
+                !(avctx->flags & CODEC_FLAG_BITEXACT)) {
+                c->vp3_v_loop_filter= ff_vp3_v_loop_filter_mmx2;
+                c->vp3_h_loop_filter= ff_vp3_h_loop_filter_mmx2;
+            }
+
 #define SET_QPEL_FUNCS(PFX, IDX, SIZE, CPU) \
             c->PFX ## _pixels_tab[IDX][ 0] = PFX ## SIZE ## _mc00_ ## CPU; \
             c->PFX ## _pixels_tab[IDX][ 1] = PFX ## SIZE ## _mc10_ ## CPU; \
--- a/i386/vp3dsp_mmx.c	Fri Oct 17 03:18:08 2008 +0000
+++ b/i386/vp3dsp_mmx.c	Sun Oct 19 04:40:24 2008 +0000
@@ -84,7 +84,7 @@
     "shr    $16, %0        \n\t" \
     "movw   %w0, -1"#dst3" \n\t"
 
-void ff_vp3_v_loop_filter_mmx(uint8_t *src, int stride, int *bounding_values)
+void ff_vp3_v_loop_filter_mmx2(uint8_t *src, int stride, int *bounding_values)
 {
     __asm__ volatile(
         "movq          %0, %%mm6 \n\t"
@@ -105,7 +105,7 @@
     );
 }
 
-void ff_vp3_h_loop_filter_mmx(uint8_t *src, int stride, int *bounding_values)
+void ff_vp3_h_loop_filter_mmx2(uint8_t *src, int stride, int *bounding_values)
 {
     x86_reg tmp;
 
--- a/i386/vp3dsp_mmx.h	Fri Oct 17 03:18:08 2008 +0000
+++ b/i386/vp3dsp_mmx.h	Sun Oct 19 04:40:24 2008 +0000
@@ -29,7 +29,7 @@
 void ff_vp3_idct_put_mmx(uint8_t *dest, int line_size, DCTELEM *block);
 void ff_vp3_idct_add_mmx(uint8_t *dest, int line_size, DCTELEM *block);
 
-void ff_vp3_v_loop_filter_mmx(uint8_t *src, int stride, int *bounding_values);
-void ff_vp3_h_loop_filter_mmx(uint8_t *src, int stride, int *bounding_values);
+void ff_vp3_v_loop_filter_mmx2(uint8_t *src, int stride, int *bounding_values);
+void ff_vp3_h_loop_filter_mmx2(uint8_t *src, int stride, int *bounding_values);
 
 #endif /* AVCODEC_I386_VP3DSP_MMX_H */