diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2002-03-28 13:41:04 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2002-03-28 13:41:04 +0000 |
commit | 649c00c96d7044aed46d70623e47d7434318e6b9 (patch) | |
tree | 90601636422687ba1e0f307b7919bfcda92710dc /libavcodec/i386/dsputil_mmx.c | |
parent | cf8039b2cf590416a6402b31b444b25e593d5d62 (diff) | |
download | ffmpeg-649c00c96d7044aed46d70623e47d7434318e6b9.tar.gz |
sizeof(s->block) isnt 64*6*2 anymore bugfix
mpeg12 decoding optimization
Originally committed as revision 364 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/i386/dsputil_mmx.c')
-rw-r--r-- | libavcodec/i386/dsputil_mmx.c | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/libavcodec/i386/dsputil_mmx.c b/libavcodec/i386/dsputil_mmx.c index 09a7174126..bf729d9638 100644 --- a/libavcodec/i386/dsputil_mmx.c +++ b/libavcodec/i386/dsputil_mmx.c @@ -1025,6 +1025,23 @@ static void sub_pixels_xy2_mmx( DCTELEM *block, const UINT8 *pixels, int line } while(--h); } +static void clear_blocks_mmx(DCTELEM *blocks) +{ + asm volatile( + "pxor %%mm7, %%mm7 \n\t" + "movl $-128*6, %%eax \n\t" + "1: \n\t" + "movq %%mm7, (%0, %%eax) \n\t" + "movq %%mm7, 8(%0, %%eax) \n\t" + "movq %%mm7, 16(%0, %%eax) \n\t" + "movq %%mm7, 24(%0, %%eax) \n\t" + "addl $32, %%eax \n\t" + " js 1b \n\t" + : : "r" (((int)blocks)+128*6) + : "%eax" + ); +} + static void just_return() { return; } void dsputil_init_mmx(void) @@ -1049,7 +1066,8 @@ void dsputil_init_mmx(void) get_pixels = get_pixels_mmx; put_pixels_clamped = put_pixels_clamped_mmx; add_pixels_clamped = add_pixels_clamped_mmx; - + clear_blocks= clear_blocks_mmx; + pix_abs16x16 = pix_abs16x16_mmx; pix_abs16x16_x2 = pix_abs16x16_x2_mmx; pix_abs16x16_y2 = pix_abs16x16_y2_mmx; |