[FFmpeg-devel] [PATCH] motion_est_mmx: prefer xmm registers below xmm6 when they are available

Michael Niedermayer michaelni
Sun Oct 31 22:04:10 CET 2010


On Sun, Oct 31, 2010 at 01:19:09PM -0200, Ramiro Polla wrote:
> On Sun, Oct 31, 2010 at 9:59 AM, Ronald S. Bultje <rsbultje at gmail.com> wrote:
> > On Sat, Oct 30, 2010 at 3:41 PM, Ramiro Polla <ramiro.polla at gmail.com> wrote:
> >> $subj
> > [..]
> > --- a/libavcodec/x86/motion_est_mmx.c
> > +++ b/libavcodec/x86/motion_est_mmx.c
> >> @@ -111,9 +111,9 @@ static int sad16_sse2(void *v, uint8_t *blk2, uint8_t *blk1, int stride, int h)
> >> ? ? ? ? ?: "r" ((x86_reg)stride)
> >> ? ? ?);
> >> ? ? ?__asm__ volatile(
> >> - ? ? ? ?"movhlps %%xmm6, %%xmm0 ? ? ? ? \n\t"
> >> - ? ? ? ?"paddw ? %%xmm0, %%xmm6 ? ? ? ? \n\t"
> >> - ? ? ? ?"movd ? ?%%xmm6, %0 ? ? ? ? ? ? \n\t"
> >> + ? ? ? ?"movhlps %%xmm2, %%xmm0 ? ? ? ? \n\t"
> >> + ? ? ? ?"paddw ? %%xmm0, %%xmm2 ? ? ? ? \n\t"
> >> + ? ? ? ?"movd ? ?%%xmm2, %0 ? ? ? ? ? ? \n\t"
> >> ? ? ? ? ?: "=r"(ret)
> >> ? ? ?);
> >> ? ? ?return ret;
> >
> > The blocks should probably be merged.
> 
> attached

>  motion_est_mmx.c |   17 +++++++----------
>  1 file changed, 7 insertions(+), 10 deletions(-)
> 442848221a8ab3bea40dbed045a8eb61f5bddb70  merge_sad16_sse2.diff

should be ok if tested

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The greatest way to live with honor in this world is to be what we pretend
to be. -- Socrates
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20101031/89d22332/attachment.pgp>



More information about the ffmpeg-devel mailing list