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|
11 EXPORT |vp8_short_inv_walsh4x4_1_neon|
17 AREA |.text|
, CODE
, READONLY
; name this block of code
19 ;short vp8_short_inv_walsh4x4_neon(short *input, short *output)
20 |vp8_short_inv_walsh4x4_neon|
PROC
22 ; read in all four lines of values: d0->d3
27 vadd.s16 d4
, d0
, d3
;a = [0] + [12]
28 vadd.s16 d5
, d1
, d2
;b = [4] + [8]
29 vsub.s16 d6
, d1
, d2
;c = [4] - [8]
30 vsub.s16 d7
, d0
, d3
;d = [0] - [12]
32 vadd.s16 d0
, d4
, d5
;a + b
33 vadd.s16 d1
, d6
, d7
;c + d
34 vsub.s16 d2
, d4
, d5
;a - b
35 vsub.s16 d3
, d7
, d6
;d - c
37 vtrn
.32 d0
, d2
;d0: 0 1 8 9
39 vtrn
.32 d1
, d3
;d1: 4 5 12 13
42 vtrn
.16 d0
, d1
;d0: 0 4 8 12
44 vtrn
.16 d2
, d3
;d2: 2 6 10 14
49 vadd.s16 d4
, d0
, d3
;a = [0] + [3]
50 vadd.s16 d5
, d1
, d2
;b = [1] + [2]
51 vsub.s16 d6
, d1
, d2
;c = [1] - [2]
52 vsub.s16 d7
, d0
, d3
;d = [0] - [3]
54 vadd.s16 d0
, d4
, d5
;e = a + b
55 vadd.s16 d1
, d6
, d7
;f = c + d
56 vsub.s16 d2
, d4
, d5
;g = a - b
57 vsub.s16 d3
, d7
, d6
;h = d - c
60 vadd.i16 q0
, q0
, q2
;e/f += 3
61 vadd.i16 q1
, q1
, q2
;g/h += 3
63 vshr.s16 q0
, q0
, #
3 ;e/f >> 3
64 vshr.s16 q1
, q1
, #
3 ;g/h >> 3
75 ENDP ; |vp8_short_inv_walsh4x4_neon|
78 ;short vp8_short_inv_walsh4x4_1_neon(short *input, short *output)
79 |vp8_short_inv_walsh4x4_1_neon|
PROC
80 ; load a full line into a neon register
82 ; extract first element and replicate
94 ENDP ; |vp8_short_inv_walsh4x4_1_neon|