Diego Biurrun
6be7944ee2
x86: Add missing colons after assembly labels
...
This fixes many warnings of the sort
warning: label alone on a line without a colon might be in error
8 years ago
Diego Biurrun
dc40a70c57
Drop unnecessary libavutil/x86/asm.h #includes
9 years ago
Henrik Gramner
ab43beefab
x86inc: Drop SECTION_TEXT macro
...
The .text section is already 16-byte aligned by default on all supported
platforms so `SECTION_TEXT` isn't any different from `SECTION .text`.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
9 years ago
James Almer
d68c05380c
x86: check for AV_CPU_FLAG_AVXSLOW where useful
...
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
10 years ago
Kieran Kunhya
96fda42a8f
vf_interlace: get rid of useless loads
...
Signed-off-by: Anton Khirnov <anton@khirnov.net>
10 years ago
Michael Niedermayer
ca5c3ff909
vf_interlace: x86: improve asm performance
...
4775 decicycles -> 3688 decicycles
10 years ago
Kieran Kunhya
2e1704059a
vf_interlace: Add SIMD for lowpass filter
...
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
10 years ago
Diego Biurrun
01c5779f56
x86: Drop some unnecessary YASM ifdefs
...
Dead code elimination is enough to avoid undefined references in these cases.
11 years ago
Robert Krüger
d8e763fda7
vf_yadif: Relicense from GPL to LGPL
...
All copyright holders have agreed to the relicensing.
11 years ago
Diego Biurrun
ed1a11ed52
gradfun: x86: Factor out common code for some gradfun_filter_line() variants
11 years ago
Diego Biurrun
ee80cf741a
avfilter: x86: K&R formatting cosmetics
11 years ago
Daniel Kang
0e73049416
avfilter: x86: Port gradfun filter optimizations to yasm
...
Signed-off-by: Diego Biurrun <diego@biurrun.de>
11 years ago
Diego Biurrun
f6633c55a3
avfilter: Fix typo in Loren's email address
11 years ago
Diego Biurrun
3ac7fa81b2
Consistently use "cpu_flags" as variable/parameter name for CPU flags
11 years ago
James Darnley
b0ef0ae776
yadif: restore speed of the C filtering code
...
Always use the special filter for the first and last 3 columns (only).
Changes made in 64ed397
slowed the filter to just under 3/4 of what it
was. This commit restores the speed while maintaining identical output.
For reference, on my Athlon64:
1733222 decicycles in old
2358563 decicycles in new
1727558 decicycles in this
Signed-off-by: Anton Khirnov <anton@khirnov.net>
12 years ago
Diego Biurrun
6e9f8d6a7d
x86: vf_yadif: Remove stray dsputil_mmx #include
12 years ago
Diego Biurrun
093804a93c
avfilter: Add av_cold attributes to init/uninit functions
12 years ago
Diego Biurrun
c1ad70c3cb
x86: Move some conditional code around to avoid unused variable warnings
12 years ago
Clément Bœsch
1ae44c87c9
lavfi/gradfun: remove rounding to match C and SSE code.
...
There is no noticable benefit for such precision.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
12 years ago
Clément Bœsch
38a2f88d39
lavfi/gradfun: fix dithering in MMX code.
...
Current dithering only uses the first 4 instead of the whole 8 random values.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
12 years ago
Clément Bœsch
2d66fc543b
lavfi/gradfun: fix rounding in MMX code.
...
Current code divides before increasing precision.
Also reduce upper bound for strength from 255 to 64. This will prevent
an overflow in the SSSE3 and MMX filter_line code: delta is expressed as
an u16 being shifted by 2 to the left. If it overflows, having a
strength not above 64 will make sure that m is set to 0 (making the
m*m*delta >> 14 expression void).
A value above 64 should not make any sense unless gradfun is used as
a blur filter.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
12 years ago
Loren Merritt
5b3c1aecb2
hqdn3d: Fix out of array read in LOWPASS
...
CC:libav-stable@libav.org
Signed-off-by: Anton Khirnov <anton@khirnov.net>
12 years ago
Anton Khirnov
64ed397635
vf_yadif: fix out-of line reads
...
Some changes in the border pixels, visually indistinguishable.
12 years ago
Anton Khirnov
99162f8d46
vf_yadif: silence a warning.
...
clang says:
libavfilter/vf_yadif.c:192:28: warning: incompatible pointer types assigning to
'void (*)(uint8_t *, uint8_t *, uint8_t *, uint8_t *, int, int, int, int, int)'
from 'void (uint16_t *, uint16_t *, uint16_t *, uint16_t *, int, int, int, int, int)'
12 years ago
Diego Biurrun
e66240f22e
avfilter: x86: consistent filenames for filter optimizations
12 years ago
Diego Biurrun
76d90125cd
vf_hqdn3d: x86: Add proper arch optimization initialization
12 years ago
Daniel Kang
67360ccd51
yadif: x86: fix build for compilers without aligned stack
...
Manually load registers to avoid using 8 registers on x86_32 with
compilers that do not align the stack (e.g. MSVC).
Signed-off-by: Diego Biurrun <diego@biurrun.de>
12 years ago
Daniel Kang
899157b308
yadif: Port inline assembly to yasm
...
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
12 years ago
Justin Ruggles
b30a363331
x86: af_volume: add SSE2/SSSE3/AVX-optimized s32 volume scaling
12 years ago
Justin Ruggles
f96f1e06a4
x86: af_volume: add SSE2-optimized s16 volume scaling
12 years ago
Diego Biurrun
d8eda37080
x86: mmx2 ---> mmxext in function names
12 years ago
Diego Biurrun
04581c8c77
x86: yasm: Use complete source path for macro helper %includes
...
This is more consistent with the way we handle C #includes and
it simplifies the build system.
12 years ago
Diego Biurrun
6860b4081d
x86: include x86inc.asm in x86util.asm
...
This is necessary to allow refactoring some x86util macros with cpuflags.
12 years ago
Diego Biurrun
f6c38c5f4e
avfilter: call x86 init functions under if (ARCH_X86), not if (HAVE_MMX)
12 years ago
Diego Biurrun
17337f54c0
x86: Split inline and external assembly #ifdefs
12 years ago
Diego Biurrun
cdaec0b240
avfilter: x86: Use more precise compile template names
12 years ago
Loren Merritt
7a1944b907
vf_hqdn3d: x86 asm
...
13% faster on penryn, 16% on sandybridge, 15% on bulldozer
Not simd; a compiler should have generated this, but gcc didn't.
12 years ago
Martin Storsjö
1d9c2dc89a
Don't include common.h from avutil.h
...
Signed-off-by: Martin Storsjö <martin@martin.st>
12 years ago
Mans Rullgard
480178a295
x86: yadif: fix asm with suncc
...
Under some circumstances, suncc will use a single register for the
address of all memory operands, inserting lea instructions loading
the correct address prior to each memory operand being used in the
code. In the yadif code, the branch in the asm block bypasses such
an lea instruction, causing an incorrect address to be used in the
following load.
This patch replaces the tmpX arrays with a single array and uses a
register operand to hold its address. Although this prevents using
offsets from the stack pointer to access these locations, the code
still builds as 32-bit PIC even with old compilers.
Signed-off-by: Mans Rullgard <mans@mansr.com>
12 years ago
Mans Rullgard
c318626ce2
x86: rename libavutil/x86_cpu.h to libavutil/x86/asm.h
...
This puts x86-specific things in the x86/ subdirectory where they
belong.
Signed-off-by: Mans Rullgard <mans@mansr.com>
12 years ago
Diego Biurrun
239fdf1b4a
x86: build: replace mmx2 by mmxext
...
Refactoring mmx2/mmxext YASM code with cpuflags will force renames.
So switching to a consistent naming scheme beforehand is sensible.
The name "mmxext" is more official and widespread and also the name
of the CPU flag, as reported e.g. by the Linux kernel.
12 years ago
Diego Biurrun
d1505db067
x86: yadif: Mark mmxext optimizations as such
...
The yadif mmx optimizations contain the pmaxsw and pmaxub mmxext
instructions, causing sigills on CPUs that do not support mmxext.
12 years ago
Ronald S. Bultje
3124886554
lavfi: place x86 inline assembly under HAVE_INLINE_ASM.
...
This allows compiling this code using compilers that do not understand
gcc-style inline assembly.
12 years ago
Mans Rullgard
fb93e61e2b
x86: lavfi: fix gradfun/yadif build with mmx/sse disabled
...
These functions are defined conditionally so any uses need to have
preprocessor guards.
Signed-off-by: Mans Rullgard <mans@mansr.com>
13 years ago
Mans Rullgard
a87b17f328
vf_yadif: move x86 init code to x86/yadif.c
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
13 years ago
Mans Rullgard
2f0accf103
vf_gradfun: move x86 init code to x86/gradfun.c
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
13 years ago
Janne Grunau
456d3e4fb5
yadif: specify array size outside DECLARE_ALIGNED
13 years ago
Diego Biurrun
0bba26466f
cosmetics: Delete empty lines at end of file.
13 years ago
Loren Merritt
082768f0b1
vf_gradfun: relicense x86 asm to LGPL
...
Actually I gave permission for LGPL long ago, but the original import
failed to update the license header.
14 years ago
Michael Niedermayer
233ed6b314
Change yadif to not use out of picture lines.
...
Fixes issue2272.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
14 years ago