# HG changeset patch # User lorenm # Date 1144210421 0 # Node ID fec9bc8d63fcd1a01980c9f3da4c20f2438dac1e # Parent ad3d12d04645febd485d5dce74d77964ec3b1061 gmc_mmx tweaks diff -r ad3d12d04645 -r fec9bc8d63fc i386/dsputil_mmx.c --- a/i386/dsputil_mmx.c Tue Apr 04 12:35:55 2006 +0000 +++ b/i386/dsputil_mmx.c Wed Apr 05 04:13:41 2006 +0000 @@ -2406,7 +2406,6 @@ static void gmc_mmx(uint8_t *dst, uint8_t *src, int stride, int h, int ox, int oy, int dxx, int dxy, int dyx, int dyy, int shift, int r, int width, int height){ const int w = 8; - const int s = 1<>(16+shift); const int iy = oy>>(16+shift); const int oxs = ox>>4; @@ -2437,14 +2436,21 @@ return; } + src += ix + iy*stride; if( (unsigned)ix >= width-w || (unsigned)iy >= height-h ) { - ff_emulated_edge_mc(edge_buf, src+ix+iy*stride, stride, w+1, h+1, ix, iy, width, height); + ff_emulated_edge_mc(edge_buf, src, stride, w+1, h+1, ix, iy, width, height); src = edge_buf; } - else - src += ix + iy*stride; + + asm volatile( + "movd %0, %%mm6 \n\t" + "pxor %%mm7, %%mm7 \n\t" + "punpcklwd %%mm6, %%mm6 \n\t" + "punpcklwd %%mm6, %%mm6 \n\t" + :: "r"(1<