• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1//******************************************************************************
2//*
3//* Copyright (C) 2015 The Android Open Source Project
4//*
5//* Licensed under the Apache License, Version 2.0 (the "License");
6//* you may not use this file except in compliance with the License.
7//* You may obtain a copy of the License at:
8//*
9//* http://www.apache.org/licenses/LICENSE-2.0
10//*
11//* Unless required by applicable law or agreed to in writing, software
12//* distributed under the License is distributed on an "AS IS" BASIS,
13//* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14//* See the License for the specific language governing permissions and
15//* limitations under the License.
16//*
17//*****************************************************************************
18//* Originally developed and contributed by Ittiam Systems Pvt. Ltd, Bangalore
19//*/
20
21///*
22////----------------------------------------------------------------------------
23//// File Name            : mot_comp_neon.s
24////
25//// Description          : This file has motion compensation related
26////                        interpolation functions on Neon + CortexA-8 platform
27////
28//// Reference Document   :
29////
30//// Revision History     :
31////      Date            Author                  Detail Description
32////   ------------    ----------------    ----------------------------------
33////   18 jun 2010      S Hamsalekha              Created
34////
35////-------------------------------------------------------------------------
36//*/
37
38///*
39//// ----------------------------------------------------------------------------
40//// Include Files
41//// ----------------------------------------------------------------------------
42//*/
43//              PRESERVE8
44.text
45.include "impeg2_neon_macros.s"
46///*
47//// ----------------------------------------------------------------------------
48//// Struct/Union Types and Define
49//// ----------------------------------------------------------------------------
50//*/
51
52
53///*
54//// ----------------------------------------------------------------------------
55//// Static Global Data section variables
56//// ----------------------------------------------------------------------------
57//*/
58//// -------------------------- NONE --------------------------------------------
59
60
61///*
62//// ----------------------------------------------------------------------------
63//// Static Prototype Functions
64//// ----------------------------------------------------------------------------
65//*/
66//// -------------------------- NONE --------------------------------------------
67
68///*
69//// ----------------------------------------------------------------------------
70//// Exported functions
71//// ----------------------------------------------------------------------------
72//*/
73
74///*
75////---------------------------------------------------------------------------
76//// Function Name      : impeg2_memset_8bit_8x8_block_av8()
77////
78//// Detail Description : This routine intialises the Block matrix buffer contents to a
79////                      particular Value. This function also assumes the buffer size
80////                         to be set is 64 Bytes fixed. It also assumes that blk matrix
81////                         used is 64 bit aligned.
82////
83//// Inputs             : pi2_blk_mat : Block Pointer
84////                         u2_val      : Value with which the block is initialized
85////
86//// Registers Used     : v0
87////
88//// Stack Usage        : 64 bytes
89////
90//// Outputs            : Block Matrix Iniliazed to given value
91////
92//// Return Data        : None
93////
94//// Programming Note   : This implementation assumes that blk matrix buffer
95////                         is 128 bit aligned
96////-----------------------------------------------------------------------------
97//*/
98.global impeg2_memset_8bit_8x8_block_av8
99impeg2_memset_8bit_8x8_block_av8:
100    push_v_regs
101
102//        ADD            x3,x0,#WIDTH_X_SIZE            @//x3 is another copy address offsetted
103
104    dup             v0.8b, w1           ////x1 is the 8-bit value to be set into
105
106    st1             {v0.8b}, [x0], x2   ////Store the row 1
107    st1             {v0.8b}, [x0], x2   ////Store the row 2
108    st1             {v0.8b}, [x0], x2   ////Store the row 3
109    st1             {v0.8b}, [x0], x2   ////Store the row 4
110    st1             {v0.8b}, [x0], x2   ////Store the row 5
111    st1             {v0.8b}, [x0], x2   ////Store the row 6
112    st1             {v0.8b}, [x0], x2   ////Store the row 7
113    st1             {v0.8b}, [x0], x2   ////Store the row 8
114
115    pop_v_regs
116    ret
117
118
119
120
121
122
123///*
124////---------------------------------------------------------------------------
125//// Function Name      :   impeg2_memset0_16bit_8x8_linear_block_av8()
126////
127//// Detail Description : memsets resudual buf to 0
128////
129//// Inputs             : x0 - pointer to y
130////                      x1 - pointer to u
131////                      x2 - pointer to v
132//// Registers Used     : v0
133
134////
135//// Stack Usage        : 64 bytes
136////
137//// Outputs            : The Motion Compensated Block
138////
139//// Return Data        : None
140////
141//// Programming Note   : <program limitation>
142////-----------------------------------------------------------------------------
143//*/
144
145
146
147.global impeg2_memset0_16bit_8x8_linear_block_av8
148
149
150impeg2_memset0_16bit_8x8_linear_block_av8:
151
152    push_v_regs
153
154    movi            v0.8h, #0
155
156    //Y data
157
158    st1             {v0.8h} , [x0], #16 //row1
159
160    st1             {v0.8h} , [x0], #16 //row2
161
162    st1             {v0.8h} , [x0], #16 //row3
163
164    st1             {v0.8h} , [x0], #16 //row4
165
166    st1             {v0.8h} , [x0], #16 //row5
167
168    st1             {v0.8h} , [x0], #16 //row6
169
170    st1             {v0.8h} , [x0], #16 //row7
171
172    st1             {v0.8h} , [x0], #16 //row8
173
174
175
176    pop_v_regs
177    ret
178
179
180
181
182