2 ; Copyright (c) 2010 The WebM project authors. All Rights Reserved.
4 ; Use of this source code is governed by a BSD-style license
5 ; that can be found in the LICENSE file in the root of the source
6 ; tree. An additional intellectual property rights grant can be found
7 ; in the file PATENTS. All contributing project authors may
8 ; be found in the AUTHORS file in the root of the source tree.
10 EXPORT |vp8_short_inv_walsh4x4_neon|
16 AREA |.text|, CODE, READONLY ; name this block of code
18 ;short vp8_short_inv_walsh4x4_neon(short *input, short *mb_dqcoeff)
19 |vp8_short_inv_walsh4x4_neon| PROC
21 ; read in all four lines of values: d0->d3
22 vld1.i16 {q0-q1}, [r0@128]
25 vadd.s16 d4, d0, d3 ;a = [0] + [12]
26 vadd.s16 d6, d1, d2 ;b = [4] + [8]
27 vsub.s16 d5, d0, d3 ;d = [0] - [12]
28 vsub.s16 d7, d1, d2 ;c = [4] - [8]
30 vadd.s16 q0, q2, q3 ; a+b d+c
31 vsub.s16 q1, q2, q3 ; a-b d-c
33 vtrn.32 d0, d2 ;d0: 0 1 8 9
35 vtrn.32 d1, d3 ;d1: 4 5 12 13
38 vtrn.16 d0, d1 ;d0: 0 4 8 12
40 vtrn.16 d2, d3 ;d2: 2 6 10 14
45 vadd.s16 d4, d0, d3 ;a = [0] + [3]
46 vadd.s16 d6, d1, d2 ;b = [1] + [2]
47 vsub.s16 d5, d0, d3 ;d = [0] - [3]
48 vsub.s16 d7, d1, d2 ;c = [1] - [2]
52 vadd.s16 q0, q2, q3 ; a+b d+c
53 vsub.s16 q1, q2, q3 ; a-b d-c
55 vadd.i16 q0, q0, q8 ;e/f += 3
56 vadd.i16 q1, q1, q8 ;g/h += 3
58 vshr.s16 q0, q0, #3 ;e/f >> 3
59 vshr.s16 q1, q1, #3 ;g/h >> 3
64 vst1.i16 d0[0], [r1],r2
65 vst1.i16 d1[0], [r3],r2
66 vst1.i16 d2[0], [r1],r2
67 vst1.i16 d3[0], [r3],r2
69 vst1.i16 d0[1], [r1],r2
70 vst1.i16 d1[1], [r3],r2
71 vst1.i16 d2[1], [r1],r2
72 vst1.i16 d3[1], [r3],r2
74 vst1.i16 d0[2], [r1],r2
75 vst1.i16 d1[2], [r3],r2
76 vst1.i16 d2[2], [r1],r2
77 vst1.i16 d3[2], [r3],r2
79 vst1.i16 d0[3], [r1],r2
80 vst1.i16 d1[3], [r3],r2
85 ENDP ; |vp8_short_inv_walsh4x4_neon|