Replaces a very hackish hack to fix the same issue (call instruction
overwriting stack variables).
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
gcc 4.6 no longer decrements esp to account for local variables.
Thus using call will end up overwriting some local variable.
So add an extra one it can safely clobber.
This is a huge hack because it's basically pure chance it works,
no idea how this is supposed to be done.
Fixes trac ticket #397.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
Speed: from 3.9x to 9.6x speed improvement over C, and some small
(up to 15%) speed improvements over existing MMX code (particularly
for bigger filters).
Author of the fix is ronald, the enabling & commit message are mine.
This fixes
commit 4e3e333a79
Author: Ronald S. Bultje <rsbultje@gmail.com>
Date: Tue Jul 5 12:49:11 2011 -0700
swscale: error dithering for 16/9/10-bit to 8-bit.
Based on a somewhat similar idea in FFmpeg's swscale copy.
The Fix was originally commited in: (and i missed it due to the commit message)
commit 5c391a161a
Author: Ronald S. Bultje <rsbultje@gmail.com>
Date: Fri Jul 8 14:39:04 2011 -0700
swscale: rename uv_off/uv_off2 to uv_off_px/byte.
This allows using more specific implementations for chroma/luma, e.g.
we can make assumptions on filterSize being constant, thus avoiding
that test at runtime.
Remove unused variables "flags" and "dstFormat" in yuv2packed1,
merge source rows per plane for yuv2packed[12], and make every
source argument int16_t (some where invalidly set to uint16_t).
This prevents stack pollution and is part of the Great Evil Plan
to simplify swscale.
Remove inline keyword for functions that are only called through
their function pointers (and thus cannot be inlined); add av_cold
keyword to init function, and use av_always_inline instead of
inline for functions that must be inlined for performance reasons.
This prevents the following compiler warnings: "warning:
initialization from incompatible pointer type". Since the
variables are only ever used in inline assembly, their type
is actually irrelevant (so the part where it was wrong did
not invoke any buggy behaviour).
commit 93681fbd50
Author: Ronald S. Bultje <rsbultje@gmail.com>
Date: Thu May 26 11:32:32 2011 -0400
swscale: fix compile on ppc.
commit e758573a88
Author: Ronald S. Bultje <rsbultje@gmail.com>
Date: Thu May 26 10:36:47 2011 -0400
swscale: fix compile on x86-32.
commit 0f4eb8b043
Author: Ronald S. Bultje <rsbultje@gmail.com>
Date: Thu May 26 09:17:52 2011 -0400
swscale: remove VOF/VOFW.
commit b4a224c5e4
Author: Ronald S. Bultje <rsbultje@gmail.com>
Date: Wed May 25 14:30:09 2011 -0400
swscale: split chroma buffers into separate U/V planes.
Preparatory step to implement support for sizes > VOFW.
Many functions have such a prefix, but do not actually use any
instructions or features from that set, thus giving the false
impression that swscale is highly optimized for a particular
system, whereas in reality it is not.
Interleave macros and code so that it's easier to find the
actual code that belongs to a function. Also reindent where
appropriate and remove dead code.