;* This algorithm (though not any of the implementation details) is
;* based on libdjbfft by D. J. Bernstein.
;*
-;* This file is part of Libav.
+;* This file is part of FFmpeg.
;*
-;* Libav is free software; you can redistribute it and/or
+;* FFmpeg is free software; you can redistribute it and/or
;* modify it under the terms of the GNU Lesser General Public
;* License as published by the Free Software Foundation; either
;* version 2.1 of the License, or (at your option) any later version.
;*
-;* Libav is distributed in the hope that it will be useful,
+;* FFmpeg is distributed in the hope that it will be useful,
;* but WITHOUT ANY WARRANTY; without even the implied warranty of
;* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
;* Lesser General Public License for more details.
;*
;* You should have received a copy of the GNU Lesser General Public
-;* License along with Libav; if not, write to the Free Software
+;* License along with FFmpeg; if not, write to the Free Software
;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
;******************************************************************************
; in blocks as conventient to the vector size.
; i.e. {4x real, 4x imaginary, 4x real, ...} (or 2x respectively)
-%include "x86inc.asm"
+%include "libavutil/x86/x86inc.asm"
-%ifdef ARCH_X86_64
+%if ARCH_X86_64
%define pointer resq
%else
%define pointer resd
%assign i i<<1
%endrep
-%ifdef ARCH_X86_64
+%if ARCH_X86_64
%define pointer dq
%else
%define pointer dd
INIT_YMM
-%ifdef HAVE_AVX
+%if HAVE_AVX
align 16
fft8_avx:
mova m0, Z(0)
sub r2d, mmsize/4
jg .deint_loop
ret
+
%endif
INIT_XMM
INIT_YMM
-%ifdef HAVE_AVX
+%if HAVE_AVX
%macro INTERL_AVX 5
vunpckhps %3, %2, %1
vunpcklps %2, %2, %1
RET
%endmacro ; DECL_FFT
-%ifdef HAVE_AVX
+%if HAVE_AVX
INIT_YMM
DECL_FFT 6, _avx
DECL_FFT 6, _avx, _interleave
%macro DECL_IMDCT 2
cglobal imdct_half%1, 3,7,8; FFTContext *s, FFTSample *output, const FFTSample *input
-%ifdef ARCH_X86_64
+%if ARCH_X86_64
%define rrevtab r10
%define rtcos r11
%define rtsin r12
mov rtsin, [r0+FFTContext.tsin]
add rtcos, r3
add rtsin, r3
-%ifndef ARCH_X86_64
+%if ARCH_X86_64 == 0
push rtcos
push rtsin
%endif
shr r3, 1
mov rrevtab, [r0+FFTContext.revtab]
add rrevtab, r3
-%ifndef ARCH_X86_64
+%if ARCH_X86_64 == 0
push rrevtab
%endif
sub r3, 4
-%ifdef ARCH_X86_64
+%if ARCH_X86_64
xor r4, r4
sub r4, r3
%endif
.pre:
-%ifndef ARCH_X86_64
+%if ARCH_X86_64 == 0
;unspill
xor r4, r4
sub r4, r3
%endif
PREROTATER r4, r3, r2, rtcos, rtsin
-%ifdef ARCH_X86_64
+%if ARCH_X86_64
movzx r5, word [rrevtab+r4-4]
movzx r6, word [rrevtab+r4-2]
movzx r13, word [rrevtab+r3]
mov r0d, [r5+FFTContext.mdctsize]
add r6, r0
shr r0, 1
-%ifndef ARCH_X86_64
+%if ARCH_X86_64 == 0
%define rtcos r2
%define rtsin r3
mov rtcos, [esp+8]
mov r1, -mmsize
sub r1, r0
%2 r0, r1, r6, rtcos, rtsin
-%ifdef ARCH_X86_64
+%if ARCH_X86_64
pop r14
pop r13
pop r12
INIT_YMM
-%ifdef HAVE_AVX
+%if HAVE_AVX
DECL_IMDCT _avx, POSROTATESHUF_AVX
%endif