On 2013-04-27 8:20 PM, Diego Biurrun wrote: > --- > libavcodec/x86/Makefile | 4 +- > libavcodec/x86/dsputil_mmx.c | 68 ++--------------------------- > libavcodec/x86/dsputil_mmx.h | 5 +++ > libavcodec/x86/fpel_mmx.c | 94 > +++++++++++++++++++++++++++++++++++++++++ > libavcodec/x86/hpeldsp_init.c | 72 ++----------------------------- > 5 files changed, 109 insertions(+), 134 deletions(-) > create mode 100644 libavcodec/x86/fpel_mmx.c
[...] > diff --git a/libavcodec/x86/Makefile b/libavcodec/x86/Makefile > index f6581f9..e8357a6 100644 > --- a/libavcodec/x86/Makefile > +++ b/libavcodec/x86/Makefile > @@ -10,7 +10,8 @@ OBJS-$(CONFIG_H264CHROMA) += > x86/h264chroma_init.o > OBJS-$(CONFIG_H264DSP) += x86/h264dsp_init.o > OBJS-$(CONFIG_H264PRED) += x86/h264_intrapred_init.o > OBJS-$(CONFIG_H264QPEL) += x86/h264_qpel.o > -OBJS-$(CONFIG_HPELDSP) += x86/hpeldsp_init.o > +OBJS-$(CONFIG_HPELDSP) += x86/fpel_mmx.o \ > + x86/hpeldsp_init.o > OBJS-$(CONFIG_LPC) += x86/lpc.o > OBJS-$(CONFIG_MLP_DECODER) += x86/mlpdsp.o > OBJS-$(CONFIG_MPEGAUDIODSP) += x86/mpegaudiodec.o > @@ -33,6 +34,7 @@ OBJS-$(CONFIG_XMM_CLOBBER_TEST) += x86/w64xmmtest.o > > MMX-OBJS-$(CONFIG_DSPUTIL) += x86/dsputil_mmx.o \ > x86/fdct.o \ > + x86/fpel_mmx.o \ > x86/idct_mmx_xvid.o \ > x86/idct_sse2_xvid.o \ > x86/simple_idct.o \ Given the code was duplicated before, I am assuming that these are indeed the only two things which rely on it? They've passed your "build everything alone" script, I assume. > static void vector_clipf_sse(float *dst, const float *src, > diff --git a/libavcodec/x86/dsputil_mmx.h b/libavcodec/x86/dsputil_mmx.h > index ca80e07..df0c85a 100644 > --- a/libavcodec/x86/dsputil_mmx.h > +++ b/libavcodec/x86/dsputil_mmx.h > @@ -155,6 +155,11 @@ 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_put_pixels8_mmx(uint8_t *block, const uint8_t *pixels, > + ptrdiff_t line_size, int h); > +void ff_put_pixels16_mmx(uint8_t *block, const uint8_t *pixels, > + ptrdiff_t line_size, int h); Any particular reason they're still in dsputil's header? > new file mode 100644 > index 0000000..3470cf2 > --- /dev/null > +++ b/libavcodec/x86/fpel_mmx.c > @@ -0,0 +1,94 @@ > +/* > + * MMX optimized DSP utils Kind of vague. > + * Copyright (c) 2000, 2001 Fabrice Bellard > + * Copyright (c) 2002-2004 Michael Niedermayer <[email protected]> > + * > + * MMX optimization by Nick Kurshev <[email protected]> This is confusing. Shouldn't this just be Nick Kurshev here, since this file only contains MMX? > +#if HAVE_INLINE_ASM HAVE_MMX_INLINE? > diff --git a/libavcodec/x86/hpeldsp_init.c b/libavcodec/x86/hpeldsp_init.c > index 73892ef..36e93c4 100644 > --- a/libavcodec/x86/hpeldsp_init.c > +++ b/libavcodec/x86/hpeldsp_init.c > @@ -74,6 +74,10 @@ void ff_avg_pixels8_xy2_mmxext(uint8_t *block, const > uint8_t *pixels, > void ff_avg_pixels8_xy2_3dnow(uint8_t *block, const uint8_t *pixels, > ptrdiff_t line_size, int h); > > +#define put_pixels8_mmx ff_put_pixels8_mmx > +#define put_pixels16_mmx ff_put_pixels16_mmx > +#define put_no_rnd_pixels8_mmx ff_put_pixels8_mmx > +#define put_no_rnd_pixels16_mmx ff_put_pixels16_mmx Eww... I know it's unrelated. But still. Ew. Oh well. - Derek _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
