[FFmpeg-devel] AAC encoder 3x performance drop in 3.0 since Oct 2014

Andrey Utkin andrey_utkin at fastmail.com
Tue Feb 23 05:34:53 CET 2016


Hi!
I am aware of news that AAC encoder got stable status recently.

But you could find this interesting. We've got an ffmpeg build from
October 2014, and it performs three times faster on AAC encoding than
recent 3.0 release. There is no complaints about audio quality on old
version, and I can honestly say the audio quality is really
satisfiable on old version. The performance is paramount in our
particular usecase, so it is silly to deploy a new version which
performs so noticeably worse. Still deploying new release is needed due
to other particular bugfixes.

Obvious things like lowering bitrace, setting "-aac_coder fast" don't
help.

You can check this yourself with this script (it is also inlined below):
https://gist.github.com/andrey-utkin/c60cd4070eb962d58075

On my workstation, the old version finishes the transcoding in 2.5s,
the new one in 6.6s.

Is there any workaround? Or is the old times speed is buried by
correctness and stability?


#!/bin/bash
set -e

ffmpeg -f lavfi -i aevalsrc="sin(440*2*PI*t):s=48000" -t 300 -y sin.flac

git clone git://source.ffmpeg.org/ffmpeg.git || true
pushd ffmpeg
for REV in 16f9f7b n3.0
do
    if [[ -e ../ffmpeg_$REV ]]
    then
        continue
    fi
    git checkout $REV
    git clean -dxf
    ./configure
    make
    cp ffmpeg ../ffmpeg_$REV
done
popd

for REV in 16f9f7b n3.0
do
    time ./ffmpeg_$REV -i sin.flac -acodec aac -strict -2 -y \
	sin_${REV}.aac
done


More information about the ffmpeg-devel mailing list