2 * This file is part of FFmpeg.
4 * FFmpeg is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * FFmpeg is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with FFmpeg; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19 #include "libavutil/aarch64/asm.S"
21 // 0.85..^1 0.85..^2 0.85..^3 0.85..^4
23 .word 0x3f599a00, 0x3f38f671, 0x3f1d382a, 0x3f05a32f
26 .word 0x0, 0x3f599a00, 0x3f38f671, 0x3f1d382a
29 .word 0x0, 0x0, 0x3f599a00, 0x3f38f671
32 .word 0x0, 0x0, 0x0, 0x3f599a00
35 function ff_opus_deemphasis_neon, export=1
45 fmul v0.4s, v4.4s, v0.s[0]
47 1: ld1 {v1.4s, v2.4s}, [x1], #32
49 fmla v0.4s, v5.4s, v1.s[0]
50 fmul v3.4s, v7.4s, v2.s[2]
52 fmla v0.4s, v6.4s, v1.s[1]
53 fmla v3.4s, v6.4s, v2.s[1]
55 fmla v0.4s, v7.4s, v1.s[2]
56 fmla v3.4s, v5.4s, v2.s[0]
58 fadd v1.4s, v1.4s, v0.4s
59 fadd v2.4s, v2.4s, v3.4s
61 fmla v2.4s, v4.4s, v1.s[3]
63 st1 {v1.4s, v2.4s}, [x0], #32
64 fmul v0.4s, v4.4s, v2.s[3]
74 function ff_opus_postfilter_neon, export=1
81 sub x1, x0, x1, lsl #2
84 fmul v3.4s, v3.4s, v2.4s
95 fmla v3.4s, v7.4s, v2.4s
96 fadd v6.4s, v6.4s, v4.4s
99 fmla v8.4s, v5.4s, v0.4s
101 fmul v6.4s, v6.4s, v1.4s
102 fadd v6.4s, v6.4s, v3.4s
104 fadd v8.4s, v8.4s, v6.4s
105 fmul v3.4s, v7.4s, v2.4s
107 st1 {v8.4s}, [x0], #16