annotate arm/dsputil_arm.S @ 11209:8173c059f769 libavcodec

Do sequential bit reading outside of []-operators.
author thilo.borgmann
date Fri, 19 Feb 2010 08:07:02 +0000
parents a6ff6fb10ff5
children 361a5fcb4393
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
1 @
8359
9281a8a9387a ARM: replace "armv4l" with "arm"
mru
parents: 8072
diff changeset
2 @ ARMv4 optimized DSP utils
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
3 @ Copyright (c) 2004 AGAWA Koji <i (AT) atty (DOT) jp>
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
4 @
3947
c8c591fe26f8 Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents: 3036
diff changeset
5 @ This file is part of FFmpeg.
c8c591fe26f8 Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents: 3036
diff changeset
6 @
c8c591fe26f8 Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents: 3036
diff changeset
7 @ FFmpeg is free software; you can redistribute it and/or
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
8 @ modify it under the terms of the GNU Lesser General Public
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
9 @ License as published by the Free Software Foundation; either
3947
c8c591fe26f8 Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents: 3036
diff changeset
10 @ version 2.1 of the License, or (at your option) any later version.
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
11 @
3947
c8c591fe26f8 Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents: 3036
diff changeset
12 @ FFmpeg is distributed in the hope that it will be useful,
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
13 @ but WITHOUT ANY WARRANTY; without even the implied warranty of
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
14 @ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
15 @ Lesser General Public License for more details.
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
16 @
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
17 @ You should have received a copy of the GNU Lesser General Public
3947
c8c591fe26f8 Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents: 3036
diff changeset
18 @ License along with FFmpeg; if not, write to the Free Software
3036
0b546eab515d Update licensing information: The FSF changed postal address.
diego
parents: 2967
diff changeset
19 @ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
20 @
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
21
6528
28d0e7dac45d pld instruction are used in libavcodec/armv4l/dsputil_arm_s.S which can be used
diego
parents: 5641
diff changeset
22 #include "config.h"
8069
316762ae96a7 ARM: use new macros for assembler function labels
mru
parents: 6528
diff changeset
23 #include "asm.S"
6528
28d0e7dac45d pld instruction are used in libavcodec/armv4l/dsputil_arm_s.S which can be used
diego
parents: 5641
diff changeset
24
8070
59be7e4941e8 ARM: move prefetch_arm to dsputil_arm_s.S
mru
parents: 8069
diff changeset
25 preserve8
59be7e4941e8 ARM: move prefetch_arm to dsputil_arm_s.S
mru
parents: 8069
diff changeset
26
8590
7a463923ecd1 Change semantic of CONFIG_*, HAVE_* and ARCH_*.
aurel
parents: 8359
diff changeset
27 #if !HAVE_PLD
6528
28d0e7dac45d pld instruction are used in libavcodec/armv4l/dsputil_arm_s.S which can be used
diego
parents: 5641
diff changeset
28 .macro pld reg
28d0e7dac45d pld instruction are used in libavcodec/armv4l/dsputil_arm_s.S which can be used
diego
parents: 5641
diff changeset
29 .endm
28d0e7dac45d pld instruction are used in libavcodec/armv4l/dsputil_arm_s.S which can be used
diego
parents: 5641
diff changeset
30 #endif
28d0e7dac45d pld instruction are used in libavcodec/armv4l/dsputil_arm_s.S which can be used
diego
parents: 5641
diff changeset
31
8590
7a463923ecd1 Change semantic of CONFIG_*, HAVE_* and ARCH_*.
aurel
parents: 8359
diff changeset
32 #if HAVE_ARMV5TE
8070
59be7e4941e8 ARM: move prefetch_arm to dsputil_arm_s.S
mru
parents: 8069
diff changeset
33 function ff_prefetch_arm, export=1
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
34 subs r2, r2, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
35 pld [r0]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
36 add r0, r0, r1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
37 bne ff_prefetch_arm
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
38 bx lr
8070
59be7e4941e8 ARM: move prefetch_arm to dsputil_arm_s.S
mru
parents: 8069
diff changeset
39 .endfunc
59be7e4941e8 ARM: move prefetch_arm to dsputil_arm_s.S
mru
parents: 8069
diff changeset
40 #endif
59be7e4941e8 ARM: move prefetch_arm to dsputil_arm_s.S
mru
parents: 8069
diff changeset
41
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
42 .macro ALIGN_QWORD_D shift, Rd0, Rd1, Rd2, Rd3, Rn0, Rn1, Rn2, Rn3, Rn4
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
43 mov \Rd0, \Rn0, lsr #(\shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
44 mov \Rd1, \Rn1, lsr #(\shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
45 mov \Rd2, \Rn2, lsr #(\shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
46 mov \Rd3, \Rn3, lsr #(\shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
47 orr \Rd0, \Rd0, \Rn1, lsl #(32 - \shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
48 orr \Rd1, \Rd1, \Rn2, lsl #(32 - \shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
49 orr \Rd2, \Rd2, \Rn3, lsl #(32 - \shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
50 orr \Rd3, \Rd3, \Rn4, lsl #(32 - \shift * 8)
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
51 .endm
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
52 .macro ALIGN_DWORD shift, R0, R1, R2
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
53 mov \R0, \R0, lsr #(\shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
54 orr \R0, \R0, \R1, lsl #(32 - \shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
55 mov \R1, \R1, lsr #(\shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
56 orr \R1, \R1, \R2, lsl #(32 - \shift * 8)
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
57 .endm
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
58 .macro ALIGN_DWORD_D shift, Rdst0, Rdst1, Rsrc0, Rsrc1, Rsrc2
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
59 mov \Rdst0, \Rsrc0, lsr #(\shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
60 mov \Rdst1, \Rsrc1, lsr #(\shift * 8)
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
61 orr \Rdst0, \Rdst0, \Rsrc1, lsl #(32 - (\shift * 8))
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
62 orr \Rdst1, \Rdst1, \Rsrc2, lsl #(32 - (\shift * 8))
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
63 .endm
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
64
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
65 .macro RND_AVG32 Rd0, Rd1, Rn0, Rn1, Rm0, Rm1, Rmask
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
66 @ Rd = (Rn | Rm) - (((Rn ^ Rm) & ~0x01010101) >> 1)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
67 @ Rmask = 0xFEFEFEFE
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
68 @ Rn = destroy
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
69 eor \Rd0, \Rn0, \Rm0
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
70 eor \Rd1, \Rn1, \Rm1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
71 orr \Rn0, \Rn0, \Rm0
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
72 orr \Rn1, \Rn1, \Rm1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
73 and \Rd0, \Rd0, \Rmask
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
74 and \Rd1, \Rd1, \Rmask
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
75 sub \Rd0, \Rn0, \Rd0, lsr #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
76 sub \Rd1, \Rn1, \Rd1, lsr #1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
77 .endm
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
78
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
79 .macro NO_RND_AVG32 Rd0, Rd1, Rn0, Rn1, Rm0, Rm1, Rmask
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
80 @ Rd = (Rn & Rm) - (((Rn ^ Rm) & ~0x01010101) >> 1)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
81 @ Rmask = 0xFEFEFEFE
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
82 @ Rn = destroy
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
83 eor \Rd0, \Rn0, \Rm0
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
84 eor \Rd1, \Rn1, \Rm1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
85 and \Rn0, \Rn0, \Rm0
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
86 and \Rn1, \Rn1, \Rm1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
87 and \Rd0, \Rd0, \Rmask
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
88 and \Rd1, \Rd1, \Rmask
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
89 add \Rd0, \Rn0, \Rd0, lsr #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
90 add \Rd1, \Rn1, \Rd1, lsr #1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
91 .endm
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
92
8682
5698999894ec ARM: remove some unused macro arguments
mru
parents: 8681
diff changeset
93 .macro JMP_ALIGN tmp, reg
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
94 ands \tmp, \reg, #3
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
95 bic \reg, \reg, #3
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
96 beq 1f
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
97 subs \tmp, \tmp, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
98 beq 2f
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
99 subs \tmp, \tmp, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
100 beq 3f
8680
83453ea78558 ARM: replace jump tables with conditional branches
mru
parents: 8679
diff changeset
101 b 4f
83453ea78558 ARM: replace jump tables with conditional branches
mru
parents: 8679
diff changeset
102 .endm
83453ea78558 ARM: replace jump tables with conditional branches
mru
parents: 8679
diff changeset
103
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
104 @ ----------------------------------------------------------------
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
105 .align 5
10363
08573f5f587d ARM: add ff_ prefix to lots of functions
mru
parents: 10360
diff changeset
106 function ff_put_pixels16_arm, export=1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
107 @ void func(uint8_t *block, const uint8_t *pixels, int line_size, int h)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
108 @ block = word aligned, pixles = unaligned
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
109 pld [r1]
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
110 push {r4-r11, lr}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
111 JMP_ALIGN r5, r1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
112 1:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
113 ldm r1, {r4-r7}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
114 add r1, r1, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
115 stm r0, {r4-r7}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
116 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
117 subs r3, r3, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
118 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
119 bne 1b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
120 pop {r4-r11, pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
121 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
122 2:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
123 ldm r1, {r4-r8}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
124 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
125 ALIGN_QWORD_D 1, r9, r10, r11, r12, r4, r5, r6, r7, r8
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
126 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
127 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
128 stm r0, {r9-r12}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
129 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
130 bne 2b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
131 pop {r4-r11, pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
132 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
133 3:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
134 ldm r1, {r4-r8}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
135 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
136 ALIGN_QWORD_D 2, r9, r10, r11, r12, r4, r5, r6, r7, r8
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
137 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
138 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
139 stm r0, {r9-r12}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
140 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
141 bne 3b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
142 pop {r4-r11, pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
143 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
144 4:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
145 ldm r1, {r4-r8}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
146 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
147 ALIGN_QWORD_D 3, r9, r10, r11, r12, r4, r5, r6, r7, r8
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
148 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
149 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
150 stm r0, {r9-r12}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
151 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
152 bne 4b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
153 pop {r4-r11,pc}
8069
316762ae96a7 ARM: use new macros for assembler function labels
mru
parents: 6528
diff changeset
154 .endfunc
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
155
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
156 @ ----------------------------------------------------------------
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
157 .align 5
10363
08573f5f587d ARM: add ff_ prefix to lots of functions
mru
parents: 10360
diff changeset
158 function ff_put_pixels8_arm, export=1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
159 @ void func(uint8_t *block, const uint8_t *pixels, int line_size, int h)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
160 @ block = word aligned, pixles = unaligned
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
161 pld [r1]
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
162 push {r4-r5,lr}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
163 JMP_ALIGN r5, r1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
164 1:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
165 ldm r1, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
166 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
167 subs r3, r3, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
168 pld [r1]
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
169 stm r0, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
170 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
171 bne 1b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
172 pop {r4-r5,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
173 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
174 2:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
175 ldm r1, {r4-r5, r12}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
176 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
177 ALIGN_DWORD 1, r4, r5, r12
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
178 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
179 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
180 stm r0, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
181 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
182 bne 2b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
183 pop {r4-r5,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
184 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
185 3:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
186 ldm r1, {r4-r5, r12}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
187 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
188 ALIGN_DWORD 2, r4, r5, r12
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
189 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
190 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
191 stm r0, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
192 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
193 bne 3b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
194 pop {r4-r5,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
195 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
196 4:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
197 ldm r1, {r4-r5, r12}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
198 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
199 ALIGN_DWORD 3, r4, r5, r12
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
200 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
201 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
202 stm r0, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
203 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
204 bne 4b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
205 pop {r4-r5,pc}
8069
316762ae96a7 ARM: use new macros for assembler function labels
mru
parents: 6528
diff changeset
206 .endfunc
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
207
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
208 @ ----------------------------------------------------------------
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
209 .align 5
10363
08573f5f587d ARM: add ff_ prefix to lots of functions
mru
parents: 10360
diff changeset
210 function ff_put_pixels8_x2_arm, export=1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
211 @ void func(uint8_t *block, const uint8_t *pixels, int line_size, int h)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
212 @ block = word aligned, pixles = unaligned
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
213 pld [r1]
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
214 push {r4-r10,lr}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
215 ldr r12, =0xfefefefe
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
216 JMP_ALIGN r5, r1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
217 1:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
218 ldm r1, {r4-r5, r10}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
219 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
220 ALIGN_DWORD_D 1, r6, r7, r4, r5, r10
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
221 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
222 RND_AVG32 r8, r9, r4, r5, r6, r7, r12
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
223 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
224 stm r0, {r8-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
225 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
226 bne 1b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
227 pop {r4-r10,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
228 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
229 2:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
230 ldm r1, {r4-r5, r10}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
231 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
232 ALIGN_DWORD_D 1, r6, r7, r4, r5, r10
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
233 ALIGN_DWORD_D 2, r8, r9, r4, r5, r10
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
234 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
235 RND_AVG32 r4, r5, r6, r7, r8, r9, r12
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
236 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
237 stm r0, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
238 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
239 bne 2b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
240 pop {r4-r10,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
241 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
242 3:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
243 ldm r1, {r4-r5, r10}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
244 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
245 ALIGN_DWORD_D 2, r6, r7, r4, r5, r10
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
246 ALIGN_DWORD_D 3, r8, r9, r4, r5, r10
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
247 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
248 RND_AVG32 r4, r5, r6, r7, r8, r9, r12
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
249 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
250 stm r0, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
251 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
252 bne 3b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
253 pop {r4-r10,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
254 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
255 4:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
256 ldm r1, {r4-r5, r10}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
257 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
258 ALIGN_DWORD_D 3, r6, r7, r4, r5, r10
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
259 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
260 RND_AVG32 r8, r9, r6, r7, r5, r10, r12
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
261 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
262 stm r0, {r8-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
263 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
264 bne 4b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
265 pop {r4-r10,pc}
8069
316762ae96a7 ARM: use new macros for assembler function labels
mru
parents: 6528
diff changeset
266 .endfunc
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
267
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
268 .align 5
10363
08573f5f587d ARM: add ff_ prefix to lots of functions
mru
parents: 10360
diff changeset
269 function ff_put_no_rnd_pixels8_x2_arm, export=1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
270 @ void func(uint8_t *block, const uint8_t *pixels, int line_size, int h)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
271 @ block = word aligned, pixles = unaligned
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
272 pld [r1]
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
273 push {r4-r10,lr}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
274 ldr r12, =0xfefefefe
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
275 JMP_ALIGN r5, r1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
276 1:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
277 ldm r1, {r4-r5, r10}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
278 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
279 ALIGN_DWORD_D 1, r6, r7, r4, r5, r10
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
280 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
281 NO_RND_AVG32 r8, r9, r4, r5, r6, r7, r12
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
282 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
283 stm r0, {r8-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
284 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
285 bne 1b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
286 pop {r4-r10,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
287 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
288 2:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
289 ldm r1, {r4-r5, r10}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
290 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
291 ALIGN_DWORD_D 1, r6, r7, r4, r5, r10
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
292 ALIGN_DWORD_D 2, r8, r9, r4, r5, r10
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
293 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
294 NO_RND_AVG32 r4, r5, r6, r7, r8, r9, r12
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
295 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
296 stm r0, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
297 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
298 bne 2b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
299 pop {r4-r10,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
300 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
301 3:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
302 ldm r1, {r4-r5, r10}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
303 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
304 ALIGN_DWORD_D 2, r6, r7, r4, r5, r10
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
305 ALIGN_DWORD_D 3, r8, r9, r4, r5, r10
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
306 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
307 NO_RND_AVG32 r4, r5, r6, r7, r8, r9, r12
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
308 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
309 stm r0, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
310 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
311 bne 3b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
312 pop {r4-r10,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
313 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
314 4:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
315 ldm r1, {r4-r5, r10}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
316 add r1, r1, r2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
317 ALIGN_DWORD_D 3, r6, r7, r4, r5, r10
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
318 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
319 NO_RND_AVG32 r8, r9, r6, r7, r5, r10, r12
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
320 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
321 stm r0, {r8-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
322 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
323 bne 4b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
324 pop {r4-r10,pc}
8069
316762ae96a7 ARM: use new macros for assembler function labels
mru
parents: 6528
diff changeset
325 .endfunc
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
326
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
327
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
328 @ ----------------------------------------------------------------
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
329 .align 5
10363
08573f5f587d ARM: add ff_ prefix to lots of functions
mru
parents: 10360
diff changeset
330 function ff_put_pixels8_y2_arm, export=1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
331 @ void func(uint8_t *block, const uint8_t *pixels, int line_size, int h)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
332 @ block = word aligned, pixles = unaligned
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
333 pld [r1]
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
334 push {r4-r11,lr}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
335 mov r3, r3, lsr #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
336 ldr r12, =0xfefefefe
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
337 JMP_ALIGN r5, r1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
338 1:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
339 ldm r1, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
340 add r1, r1, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
341 6: ldm r1, {r6-r7}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
342 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
343 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
344 RND_AVG32 r8, r9, r4, r5, r6, r7, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
345 ldm r1, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
346 add r1, r1, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
347 stm r0, {r8-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
348 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
349 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
350 RND_AVG32 r8, r9, r6, r7, r4, r5, r12
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
351 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
352 stm r0, {r8-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
353 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
354 bne 6b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
355 pop {r4-r11,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
356 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
357 2:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
358 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
359 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
360 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
361 ALIGN_DWORD 1, r4, r5, r6
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
362 6: ldm r1, {r7-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
363 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
364 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
365 ALIGN_DWORD 1, r7, r8, r9
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
366 RND_AVG32 r10, r11, r4, r5, r7, r8, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
367 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
368 add r0, r0, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
369 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
370 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
371 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
372 ALIGN_DWORD 1, r4, r5, r6
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
373 subs r3, r3, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
374 RND_AVG32 r10, r11, r7, r8, r4, r5, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
375 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
376 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
377 bne 6b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
378 pop {r4-r11,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
379 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
380 3:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
381 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
382 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
383 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
384 ALIGN_DWORD 2, r4, r5, r6
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
385 6: ldm r1, {r7-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
386 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
387 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
388 ALIGN_DWORD 2, r7, r8, r9
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
389 RND_AVG32 r10, r11, r4, r5, r7, r8, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
390 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
391 add r0, r0, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
392 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
393 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
394 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
395 ALIGN_DWORD 2, r4, r5, r6
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
396 subs r3, r3, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
397 RND_AVG32 r10, r11, r7, r8, r4, r5, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
398 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
399 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
400 bne 6b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
401 pop {r4-r11,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
402 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
403 4:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
404 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
405 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
406 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
407 ALIGN_DWORD 3, r4, r5, r6
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
408 6: ldm r1, {r7-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
409 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
410 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
411 ALIGN_DWORD 3, r7, r8, r9
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
412 RND_AVG32 r10, r11, r4, r5, r7, r8, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
413 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
414 add r0, r0, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
415 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
416 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
417 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
418 ALIGN_DWORD 3, r4, r5, r6
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
419 subs r3, r3, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
420 RND_AVG32 r10, r11, r7, r8, r4, r5, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
421 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
422 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
423 bne 6b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
424 pop {r4-r11,pc}
8069
316762ae96a7 ARM: use new macros for assembler function labels
mru
parents: 6528
diff changeset
425 .endfunc
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
426
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
427 .align 5
10363
08573f5f587d ARM: add ff_ prefix to lots of functions
mru
parents: 10360
diff changeset
428 function ff_put_no_rnd_pixels8_y2_arm, export=1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
429 @ void func(uint8_t *block, const uint8_t *pixels, int line_size, int h)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
430 @ block = word aligned, pixles = unaligned
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
431 pld [r1]
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
432 push {r4-r11,lr}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
433 mov r3, r3, lsr #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
434 ldr r12, =0xfefefefe
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
435 JMP_ALIGN r5, r1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
436 1:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
437 ldm r1, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
438 add r1, r1, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
439 6: ldm r1, {r6-r7}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
440 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
441 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
442 NO_RND_AVG32 r8, r9, r4, r5, r6, r7, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
443 ldm r1, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
444 add r1, r1, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
445 stm r0, {r8-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
446 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
447 pld [r1]
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
448 NO_RND_AVG32 r8, r9, r6, r7, r4, r5, r12
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
449 subs r3, r3, #1
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
450 stm r0, {r8-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
451 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
452 bne 6b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
453 pop {r4-r11,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
454 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
455 2:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
456 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
457 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
458 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
459 ALIGN_DWORD 1, r4, r5, r6
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
460 6: ldm r1, {r7-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
461 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
462 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
463 ALIGN_DWORD 1, r7, r8, r9
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
464 NO_RND_AVG32 r10, r11, r4, r5, r7, r8, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
465 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
466 add r0, r0, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
467 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
468 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
469 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
470 ALIGN_DWORD 1, r4, r5, r6
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
471 subs r3, r3, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
472 NO_RND_AVG32 r10, r11, r7, r8, r4, r5, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
473 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
474 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
475 bne 6b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
476 pop {r4-r11,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
477 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
478 3:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
479 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
480 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
481 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
482 ALIGN_DWORD 2, r4, r5, r6
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
483 6: ldm r1, {r7-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
484 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
485 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
486 ALIGN_DWORD 2, r7, r8, r9
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
487 NO_RND_AVG32 r10, r11, r4, r5, r7, r8, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
488 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
489 add r0, r0, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
490 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
491 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
492 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
493 ALIGN_DWORD 2, r4, r5, r6
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
494 subs r3, r3, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
495 NO_RND_AVG32 r10, r11, r7, r8, r4, r5, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
496 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
497 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
498 bne 6b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
499 pop {r4-r11,pc}
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
500 .align 5
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
501 4:
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
502 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
503 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
504 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
505 ALIGN_DWORD 3, r4, r5, r6
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
506 6: ldm r1, {r7-r9}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
507 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
508 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
509 ALIGN_DWORD 3, r7, r8, r9
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
510 NO_RND_AVG32 r10, r11, r4, r5, r7, r8, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
511 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
512 add r0, r0, r2
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
513 ldm r1, {r4-r6}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
514 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
515 pld [r1]
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
516 ALIGN_DWORD 3, r4, r5, r6
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
517 subs r3, r3, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
518 NO_RND_AVG32 r10, r11, r7, r8, r4, r5, r12
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
519 stm r0, {r10-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
520 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
521 bne 6b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
522 pop {r4-r11,pc}
8069
316762ae96a7 ARM: use new macros for assembler function labels
mru
parents: 6528
diff changeset
523 .endfunc
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
524
8679
9c1ea156d893 ARM: replace explicit literal loads with ldr Rd, =lit
mru
parents: 8678
diff changeset
525 .ltorg
9c1ea156d893 ARM: replace explicit literal loads with ldr Rd, =lit
mru
parents: 8678
diff changeset
526
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
527 @ ----------------------------------------------------------------
8679
9c1ea156d893 ARM: replace explicit literal loads with ldr Rd, =lit
mru
parents: 8678
diff changeset
528 .macro RND_XY2_IT align, rnd
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
529 @ l1= (a & 0x03030303) + (b & 0x03030303) ?(+ 0x02020202)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
530 @ h1= ((a & 0xFCFCFCFCUL) >> 2) + ((b & 0xFCFCFCFCUL) >> 2)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
531 .if \align == 0
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
532 ldm r1, {r6-r8}
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
533 .elseif \align == 3
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
534 ldm r1, {r5-r7}
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
535 .else
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
536 ldm r1, {r8-r10}
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
537 .endif
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
538 add r1, r1, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
539 pld [r1]
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
540 .if \align == 0
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
541 ALIGN_DWORD_D 1, r4, r5, r6, r7, r8
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
542 .elseif \align == 1
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
543 ALIGN_DWORD_D 1, r4, r5, r8, r9, r10
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
544 ALIGN_DWORD_D 2, r6, r7, r8, r9, r10
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
545 .elseif \align == 2
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
546 ALIGN_DWORD_D 2, r4, r5, r8, r9, r10
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
547 ALIGN_DWORD_D 3, r6, r7, r8, r9, r10
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
548 .elseif \align == 3
10357
ada571517e88 ARM: shorten some long macro names
mru
parents: 10356
diff changeset
549 ALIGN_DWORD_D 3, r4, r5, r5, r6, r7
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
550 .endif
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
551 ldr r14, =0x03030303
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
552 tst r3, #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
553 and r8, r4, r14
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
554 and r9, r5, r14
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
555 and r10, r6, r14
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
556 and r11, r7, r14
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
557 andeq r14, r14, r14, \rnd #1
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
558 add r8, r8, r10
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
559 add r9, r9, r11
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
560 ldr r12, =0xfcfcfcfc >> 2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
561 addeq r8, r8, r14
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
562 addeq r9, r9, r14
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
563 and r4, r12, r4, lsr #2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
564 and r5, r12, r5, lsr #2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
565 and r6, r12, r6, lsr #2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
566 and r7, r12, r7, lsr #2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
567 add r10, r4, r6
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
568 add r11, r5, r7
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
569 subs r3, r3, #1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
570 .endm
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
571
8679
9c1ea156d893 ARM: replace explicit literal loads with ldr Rd, =lit
mru
parents: 8678
diff changeset
572 .macro RND_XY2_EXPAND align, rnd
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
573 RND_XY2_IT \align, \rnd
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
574 6: push {r8-r11}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
575 RND_XY2_IT \align, \rnd
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
576 pop {r4-r7}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
577 add r4, r4, r8
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
578 add r5, r5, r9
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
579 ldr r14, =0x0f0f0f0f
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
580 add r6, r6, r10
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
581 add r7, r7, r11
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
582 and r4, r14, r4, lsr #2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
583 and r5, r14, r5, lsr #2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
584 add r4, r4, r6
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
585 add r5, r5, r7
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
586 stm r0, {r4-r5}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
587 add r0, r0, r2
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
588 bge 6b
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
589 pop {r4-r11,pc}
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
590 .endm
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
591
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
592 .align 5
10363
08573f5f587d ARM: add ff_ prefix to lots of functions
mru
parents: 10360
diff changeset
593 function ff_put_pixels8_xy2_arm, export=1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
594 @ void func(uint8_t *block, const uint8_t *pixels, int line_size, int h)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
595 @ block = word aligned, pixles = unaligned
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
596 pld [r1]
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
597 push {r4-r11,lr} @ R14 is also called LR
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
598 JMP_ALIGN r5, r1
10371
e1cddc20418c ARM: whitespace cosmetics
mru
parents: 10363
diff changeset
599 1: RND_XY2_EXPAND 0, lsl
e1cddc20418c ARM: whitespace cosmetics
mru
parents: 10363
diff changeset
600 .align 5
e1cddc20418c ARM: whitespace cosmetics
mru
parents: 10363
diff changeset
601 2: RND_XY2_EXPAND 1, lsl
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
602 .align 5
10371
e1cddc20418c ARM: whitespace cosmetics
mru
parents: 10363
diff changeset
603 3: RND_XY2_EXPAND 2, lsl
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
604 .align 5
10371
e1cddc20418c ARM: whitespace cosmetics
mru
parents: 10363
diff changeset
605 4: RND_XY2_EXPAND 3, lsl
8069
316762ae96a7 ARM: use new macros for assembler function labels
mru
parents: 6528
diff changeset
606 .endfunc
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
607
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
608 .align 5
10363
08573f5f587d ARM: add ff_ prefix to lots of functions
mru
parents: 10360
diff changeset
609 function ff_put_no_rnd_pixels8_xy2_arm, export=1
2734
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
610 @ void func(uint8_t *block, const uint8_t *pixels, int line_size, int h)
aeea63c97878 Better ARM support for mplayer/ffmpeg, ported from atty fork
michael
parents:
diff changeset
611 @ block = word aligned, pixles = unaligned
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
612 pld [r1]
10356
f8d0701ff445 ARM: update ldm/stm instructions to modern syntax
mru
parents: 10355
diff changeset
613 push {r4-r11,lr}
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
614 JMP_ALIGN r5, r1
10371
e1cddc20418c ARM: whitespace cosmetics
mru
parents: 10363
diff changeset
615 1: RND_XY2_EXPAND 0, lsr
e1cddc20418c ARM: whitespace cosmetics
mru
parents: 10363
diff changeset
616 .align 5
e1cddc20418c ARM: whitespace cosmetics
mru
parents: 10363
diff changeset
617 2: RND_XY2_EXPAND 1, lsr
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
618 .align 5
10371
e1cddc20418c ARM: whitespace cosmetics
mru
parents: 10363
diff changeset
619 3: RND_XY2_EXPAND 2, lsr
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
620 .align 5
10371
e1cddc20418c ARM: whitespace cosmetics
mru
parents: 10363
diff changeset
621 4: RND_XY2_EXPAND 3, lsr
8069
316762ae96a7 ARM: use new macros for assembler function labels
mru
parents: 6528
diff changeset
622 .endfunc
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
623
8678
6c256fc075e3 ARM: change alignment of loops in put_pixels*_arm to 32
mru
parents: 8590
diff changeset
624 .align 5
10374
a6ff6fb10ff5 ARM: make function names all-lowercase
mru
parents: 10371
diff changeset
625 @ void ff_add_pixels_clamped_arm(int16_t *block, uint8_t *dest, int stride)
a6ff6fb10ff5 ARM: make function names all-lowercase
mru
parents: 10371
diff changeset
626 function ff_add_pixels_clamped_arm, export=1
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
627 push {r4-r10}
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
628 mov r10, #8
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
629 1:
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
630 ldr r4, [r1] /* load dest */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
631 /* block[0] and block[1]*/
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
632 ldrsh r5, [r0]
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
633 ldrsh r7, [r0, #2]
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
634 and r6, r4, #0xFF
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
635 and r8, r4, #0xFF00
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
636 add r6, r5, r6
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
637 add r8, r7, r8, lsr #8
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
638 mvn r5, r5
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
639 mvn r7, r7
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
640 tst r6, #0x100
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
641 movne r6, r5, lsr #24
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
642 tst r8, #0x100
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
643 movne r8, r7, lsr #24
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
644 mov r9, r6
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
645 ldrsh r5, [r0, #4] /* moved form [A] */
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
646 orr r9, r9, r8, lsl #8
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
647 /* block[2] and block[3] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
648 /* [A] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
649 ldrsh r7, [r0, #6]
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
650 and r6, r4, #0xFF0000
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
651 and r8, r4, #0xFF000000
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
652 add r6, r5, r6, lsr #16
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
653 add r8, r7, r8, lsr #24
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
654 mvn r5, r5
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
655 mvn r7, r7
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
656 tst r6, #0x100
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
657 movne r6, r5, lsr #24
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
658 tst r8, #0x100
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
659 movne r8, r7, lsr #24
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
660 orr r9, r9, r6, lsl #16
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
661 ldr r4, [r1, #4] /* moved form [B] */
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
662 orr r9, r9, r8, lsl #24
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
663 /* store dest */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
664 ldrsh r5, [r0, #8] /* moved form [C] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
665 str r9, [r1]
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
666
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
667 /* load dest */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
668 /* [B] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
669 /* block[4] and block[5] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
670 /* [C] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
671 ldrsh r7, [r0, #10]
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
672 and r6, r4, #0xFF
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
673 and r8, r4, #0xFF00
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
674 add r6, r5, r6
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
675 add r8, r7, r8, lsr #8
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
676 mvn r5, r5
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
677 mvn r7, r7
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
678 tst r6, #0x100
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
679 movne r6, r5, lsr #24
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
680 tst r8, #0x100
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
681 movne r8, r7, lsr #24
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
682 mov r9, r6
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
683 ldrsh r5, [r0, #12] /* moved from [D] */
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
684 orr r9, r9, r8, lsl #8
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
685 /* block[6] and block[7] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
686 /* [D] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
687 ldrsh r7, [r0, #14]
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
688 and r6, r4, #0xFF0000
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
689 and r8, r4, #0xFF000000
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
690 add r6, r5, r6, lsr #16
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
691 add r8, r7, r8, lsr #24
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
692 mvn r5, r5
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
693 mvn r7, r7
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
694 tst r6, #0x100
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
695 movne r6, r5, lsr #24
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
696 tst r8, #0x100
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
697 movne r8, r7, lsr #24
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
698 orr r9, r9, r6, lsl #16
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
699 add r0, r0, #16 /* moved from [E] */
10355
47245bb9e85f ARM: whitespace cosmetics
mru
parents: 8682
diff changeset
700 orr r9, r9, r8, lsl #24
8072
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
701 subs r10, r10, #1 /* moved from [F] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
702 /* store dest */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
703 str r9, [r1, #4]
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
704
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
705 /* [E] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
706 /* [F] */
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
707 add r1, r1, r2
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
708 bne 1b
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
709
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
710 pop {r4-r10}
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
711 bx lr
4b32e8762864 ARM: move add_pixels_clamped_ARM() to dsputil_arm_s.S
mru
parents: 8070
diff changeset
712 .endfunc