• Mans Rullgard's avatar
    x86: vc1: fix and enable optimised loop filter · f2fd1678
    Mans Rullgard authored
    The problem is that the ssse3 psign instruction does the wrong
    thing here.  Commit ea60dfe2 incorrectly removed a macro emulating
    this instruction for pre-ssse3 code.  However, the emulation is
    incorrect, and the code relies on the behaviour of the macro.
    Specifically, the psign sets destination elements to zero where
    the corresponding source element is zero, whereas the emulation
    only negates destination elements where the source is negative.
    
    Furthermore, the PSIGNW_MMX macro in x86util.asm is totally bogus,
    which is why the original VC-1 code had an additional right shift
    when using it.  Since the psign instruction cannot be used here,
    skip all the macro hell and use the working instruction sequence
    directly.
    
    None of this was noticed due a stray return statement in
    ff_vc1dsp_init_mmx() which meant that only the mmx version of the
    loop filter was ever used (before being removed in ea60dfe2).
    Signed-off-by: 's avatarMans Rullgard <mans@mansr.com>
    f2fd1678
Name
Last commit
Last update
doc Loading commit data...
libavcodec Loading commit data...
libavdevice Loading commit data...
libavfilter Loading commit data...
libavformat Loading commit data...
libavresample Loading commit data...
libavutil Loading commit data...
libswscale Loading commit data...
presets Loading commit data...
tests Loading commit data...
tools Loading commit data...
.gitignore Loading commit data...
COPYING.GPLv2 Loading commit data...
COPYING.GPLv3 Loading commit data...
COPYING.LGPLv2.1 Loading commit data...
COPYING.LGPLv3 Loading commit data...
CREDITS Loading commit data...
Changelog Loading commit data...
Doxyfile Loading commit data...
INSTALL Loading commit data...
LICENSE Loading commit data...
Makefile Loading commit data...
README Loading commit data...
RELEASE Loading commit data...
arch.mak Loading commit data...
avconv.c Loading commit data...
avplay.c Loading commit data...
avprobe.c Loading commit data...
avserver.c Loading commit data...
cmdutils.c Loading commit data...
cmdutils.h Loading commit data...
cmdutils_common_opts.h Loading commit data...
common.mak Loading commit data...
configure Loading commit data...
library.mak Loading commit data...
version.sh Loading commit data...