Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(179)

Side by Side Diff: source/libvpx/vp8/common/arm/armv6/vp8_variance_halfpixvar16x16_v_armv6.asm

Issue 181493009: libvpx: Pull from upstream (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/deps/third_party/libvpx/
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 ; 1 ;
2 ; Copyright (c) 2011 The WebM project authors. All Rights Reserved. 2 ; Copyright (c) 2011 The WebM project authors. All Rights Reserved.
3 ; 3 ;
4 ; Use of this source code is governed by a BSD-style license 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 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 6 ; tree. An additional intellectual property rights grant can be found
7 ; in the file PATENTS. All contributing project authors may 7 ; in the file PATENTS. All contributing project authors may
8 ; be found in the AUTHORS file in the root of the source tree. 8 ; be found in the AUTHORS file in the root of the source tree.
9 ; 9 ;
10 10
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 usub8 r6, r5, r4 ; calculate difference with reversed operands 52 usub8 r6, r5, r4 ; calculate difference with reversed operands
53 pld [r2, r3, lsl #1] 53 pld [r2, r3, lsl #1]
54 sel r6, r6, lr ; select bytes with negative difference 54 sel r6, r6, lr ; select bytes with negative difference
55 55
56 ; calculate partial sums 56 ; calculate partial sums
57 usad8 r4, r7, lr ; calculate sum of positive differences 57 usad8 r4, r7, lr ; calculate sum of positive differences
58 usad8 r5, r6, lr ; calculate sum of negative differences 58 usad8 r5, r6, lr ; calculate sum of negative differences
59 orr r6, r6, r7 ; differences of all 4 pixels 59 orr r6, r6, r7 ; differences of all 4 pixels
60 ; calculate total sum 60 ; calculate total sum
61 adds r8, r8, r4 ; add positive differences to sum 61 adds r8, r8, r4 ; add positive differences to sum
62 subs r8, r8, r5 ; substract negative differences from sum 62 subs r8, r8, r5 ; subtract negative differences from sum
63 63
64 ; calculate sse 64 ; calculate sse
65 uxtb16 r5, r6 ; byte (two pixels) to halfwords 65 uxtb16 r5, r6 ; byte (two pixels) to halfwords
66 uxtb16 r7, r6, ror #8 ; another two pixels to halfwords 66 uxtb16 r7, r6, ror #8 ; another two pixels to halfwords
67 smlad r11, r5, r5, r11 ; dual signed multiply, add and accumulate (1) 67 smlad r11, r5, r5, r11 ; dual signed multiply, add and accumulate (1)
68 68
69 ; 2nd 4 pixels 69 ; 2nd 4 pixels
70 ldr r4, [r0, #4] ; load 4 src pixels 70 ldr r4, [r0, #4] ; load 4 src pixels
71 ldr r6, [r9, #4] ; load 4 src pixels from next row 71 ldr r6, [r9, #4] ; load 4 src pixels from next row
72 ldr r5, [r2, #4] ; load 4 ref pixels 72 ldr r5, [r2, #4] ; load 4 ref pixels
(...skipping 10 matching lines...) Expand all
83 usub8 r6, r5, r4 ; calculate difference with reversed operands 83 usub8 r6, r5, r4 ; calculate difference with reversed operands
84 sel r6, r6, lr ; select bytes with negative difference 84 sel r6, r6, lr ; select bytes with negative difference
85 85
86 ; calculate partial sums 86 ; calculate partial sums
87 usad8 r4, r7, lr ; calculate sum of positive differences 87 usad8 r4, r7, lr ; calculate sum of positive differences
88 usad8 r5, r6, lr ; calculate sum of negative differences 88 usad8 r5, r6, lr ; calculate sum of negative differences
89 orr r6, r6, r7 ; differences of all 4 pixels 89 orr r6, r6, r7 ; differences of all 4 pixels
90 90
91 ; calculate total sum 91 ; calculate total sum
92 add r8, r8, r4 ; add positive differences to sum 92 add r8, r8, r4 ; add positive differences to sum
93 sub r8, r8, r5 ; substract negative differences from sum 93 sub r8, r8, r5 ; subtract negative differences from sum
94 94
95 ; calculate sse 95 ; calculate sse
96 uxtb16 r5, r6 ; byte (two pixels) to halfwords 96 uxtb16 r5, r6 ; byte (two pixels) to halfwords
97 uxtb16 r7, r6, ror #8 ; another two pixels to halfwords 97 uxtb16 r7, r6, ror #8 ; another two pixels to halfwords
98 smlad r11, r5, r5, r11 ; dual signed multiply, add and accumulate (1) 98 smlad r11, r5, r5, r11 ; dual signed multiply, add and accumulate (1)
99 99
100 ; 3rd 4 pixels 100 ; 3rd 4 pixels
101 ldr r4, [r0, #8] ; load 4 src pixels 101 ldr r4, [r0, #8] ; load 4 src pixels
102 ldr r6, [r9, #8] ; load 4 src pixels from next row 102 ldr r6, [r9, #8] ; load 4 src pixels from next row
103 ldr r5, [r2, #8] ; load 4 ref pixels 103 ldr r5, [r2, #8] ; load 4 ref pixels
(...skipping 10 matching lines...) Expand all
114 usub8 r6, r5, r4 ; calculate difference with reversed operands 114 usub8 r6, r5, r4 ; calculate difference with reversed operands
115 sel r6, r6, lr ; select bytes with negative difference 115 sel r6, r6, lr ; select bytes with negative difference
116 116
117 ; calculate partial sums 117 ; calculate partial sums
118 usad8 r4, r7, lr ; calculate sum of positive differences 118 usad8 r4, r7, lr ; calculate sum of positive differences
119 usad8 r5, r6, lr ; calculate sum of negative differences 119 usad8 r5, r6, lr ; calculate sum of negative differences
120 orr r6, r6, r7 ; differences of all 4 pixels 120 orr r6, r6, r7 ; differences of all 4 pixels
121 121
122 ; calculate total sum 122 ; calculate total sum
123 add r8, r8, r4 ; add positive differences to sum 123 add r8, r8, r4 ; add positive differences to sum
124 sub r8, r8, r5 ; substract negative differences from sum 124 sub r8, r8, r5 ; subtract negative differences from sum
125 125
126 ; calculate sse 126 ; calculate sse
127 uxtb16 r5, r6 ; byte (two pixels) to halfwords 127 uxtb16 r5, r6 ; byte (two pixels) to halfwords
128 uxtb16 r7, r6, ror #8 ; another two pixels to halfwords 128 uxtb16 r7, r6, ror #8 ; another two pixels to halfwords
129 smlad r11, r5, r5, r11 ; dual signed multiply, add and accumulate (1) 129 smlad r11, r5, r5, r11 ; dual signed multiply, add and accumulate (1)
130 130
131 ; 4th 4 pixels 131 ; 4th 4 pixels
132 ldr r4, [r0, #12] ; load 4 src pixels 132 ldr r4, [r0, #12] ; load 4 src pixels
133 ldr r6, [r9, #12] ; load 4 src pixels from next row 133 ldr r6, [r9, #12] ; load 4 src pixels from next row
134 ldr r5, [r2, #12] ; load 4 ref pixels 134 ldr r5, [r2, #12] ; load 4 ref pixels
(...skipping 12 matching lines...) Expand all
147 add r2, r2, r3 ; set dst_ptr to next row 147 add r2, r2, r3 ; set dst_ptr to next row
148 sel r6, r6, lr ; select bytes with negative difference 148 sel r6, r6, lr ; select bytes with negative difference
149 149
150 ; calculate partial sums 150 ; calculate partial sums
151 usad8 r4, r7, lr ; calculate sum of positive differences 151 usad8 r4, r7, lr ; calculate sum of positive differences
152 usad8 r5, r6, lr ; calculate sum of negative differences 152 usad8 r5, r6, lr ; calculate sum of negative differences
153 orr r6, r6, r7 ; differences of all 4 pixels 153 orr r6, r6, r7 ; differences of all 4 pixels
154 154
155 ; calculate total sum 155 ; calculate total sum
156 add r8, r8, r4 ; add positive differences to sum 156 add r8, r8, r4 ; add positive differences to sum
157 sub r8, r8, r5 ; substract negative differences from sum 157 sub r8, r8, r5 ; subtract negative differences from sum
158 158
159 ; calculate sse 159 ; calculate sse
160 uxtb16 r5, r6 ; byte (two pixels) to halfwords 160 uxtb16 r5, r6 ; byte (two pixels) to halfwords
161 uxtb16 r7, r6, ror #8 ; another two pixels to halfwords 161 uxtb16 r7, r6, ror #8 ; another two pixels to halfwords
162 smlad r11, r5, r5, r11 ; dual signed multiply, add and accumulate (1) 162 smlad r11, r5, r5, r11 ; dual signed multiply, add and accumulate (1)
163 smlad r11, r7, r7, r11 ; dual signed multiply, add and accumulate (2) 163 smlad r11, r7, r7, r11 ; dual signed multiply, add and accumulate (2)
164 164
165 165
166 subs r12, r12, #1 166 subs r12, r12, #1
167 167
168 bne loop 168 bne loop
169 169
170 ; return stuff 170 ; return stuff
171 ldr r6, [sp, #40] ; get address of sse 171 ldr r6, [sp, #40] ; get address of sse
172 mul r0, r8, r8 ; sum * sum 172 mul r0, r8, r8 ; sum * sum
173 str r11, [r6] ; store sse 173 str r11, [r6] ; store sse
174 sub r0, r11, r0, lsr #8 ; return (sse - ((sum * sum) >> 8)) 174 sub r0, r11, r0, lsr #8 ; return (sse - ((sum * sum) >> 8))
175 175
176 ldmfd sp!, {r4-r12, pc} 176 ldmfd sp!, {r4-r12, pc}
177 177
178 ENDP 178 ENDP
179 179
180 c80808080 180 c80808080
181 DCD 0x80808080 181 DCD 0x80808080
182 182
183 END 183 END
184 184
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698