[FFmpeg-devel] [PATCH] Faster SSE FFT/MDCT

Aurelien Jacobs aurel
Mon May 14 01:47:55 CEST 2007


On Sun, 13 May 2007 18:33:41 +0200
"Guillaume POIRIER" <poirierg at gmail.com> wrote:

> Hi,
> 
> On 5/12/07, Michael Niedermayer <michaelni at gmx.at> wrote:
> > On Fri, May 11, 2007 at 04:51:21PM +0800, Zuxy Meng wrote:
> > > 2007/5/11, Zuxy Meng <zuxy.meng at gmail.com>:
> > > >The patch unrolls some loops, utilizing all 8 xmm registers. fft-test
> > > >shows ~10% speed up in (I)FFT and ~5% speed up in (I)MDCT on my
> > > >Dothan. Of course with x86-64 we can unroll one more time but I don't
> > > >have a test bench....
> > > >
> > > >Full test passed on x86, and a test on x86-64 would be prudent: I used
> > > >xmm8 to save a memory access.
> > >
> > > I just unrolled another loop in imdct. Now IMDCT is about ~8% faster
> > > compared to SVN head. Please ignore the last patch and try this one
> > > instead:-)
> >
> > looks ok if it passes regression tests
> 
> Regression tests do pass here on AMD64.
> Patch applied.

This patch generate some assembler warning messages which weren't
present before:

gcc -I"/data/ffmpeg/ffmpeg"/libswscale  -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_ISOC9X_SOURCE -I"/data/ffmpeg/ffmpeg" -I"/data/ffmpeg/ffmpeg" -I"/data/ffmpeg/ffmpeg"/libavutil -fomit-frame-pointer -g -Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -O3  -c -o i386/fft_sse.o i386/fft_sse.c
In file included from i386/../dsputil.h:34,
                 from i386/fft_sse.c:22:
i386/../avcodec.h:2505: warning: ?ImgReSampleContext? is deprecated
i386/../avcodec.h:2511: warning: ?ImgReSampleContext? is deprecated
/tmp/cc7UvDpX.s: Assembler messages:
/tmp/cc7UvDpX.s:229: Warning: missing operand; zero assumed
/tmp/cc7UvDpX.s:230: Warning: missing operand; zero assumed
/tmp/cc7UvDpX.s:233: Warning: missing operand; zero assumed
/tmp/cc7UvDpX.s:234: Warning: missing operand; zero assumed
/tmp/cc7UvDpX.s:431: Warning: missing operand; zero assumed
/tmp/cc7UvDpX.s:433: Warning: missing operand; zero assumed
/tmp/cc7UvDpX.s:437: Warning: missing operand; zero assumed
/tmp/cc7UvDpX.s:457: Warning: missing operand; zero assumed

I've verified this to happen both on x86 and 86-64.

$ gcc --version
gcc (GCC) 4.1.3 20070429 (prerelease) (Debian 4.1.2-6)

$ as --version
GNU assembler (GNU Binutils for Debian) 2.17.50.20070426

Aurel




More information about the ffmpeg-devel mailing list