annotate sparc/simple_idct_vis.c @ 11798:46a7546ad744 libavcodec

Remove unused variables.
author maxim
date Sun, 30 May 2010 17:12:50 +0000
parents 766ca433df3b
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
1 /*
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
2 * SPARC VIS optimized inverse DCT
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
3 * Copyright (c) 2007 Denes Balatoni < dbalatoni XatX interware XdotX hu >
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
4 *
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
5 * I did consult the following fine web page about dct
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
6 * http://www.geocities.com/ssavekar/dct.htm
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
7 *
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
8 * This file is part of FFmpeg.
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
9 *
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
10 * FFmpeg is free software; you can redistribute it and/or
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
11 * modify it under the terms of the GNU Lesser General Public
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
12 * License as published by the Free Software Foundation; either
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
13 * version 2.1 of the License, or (at your option) any later version.
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
14 *
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
15 * FFmpeg is distributed in the hope that it will be useful,
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
18 * Lesser General Public License for more details.
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
19 *
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
20 * You should have received a copy of the GNU Lesser General Public
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
21 * License along with FFmpeg; if not, write to the Free Software
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
22 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
23 */
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
24
6763
f7cbb7733146 Use full path for #includes from another directory.
diego
parents: 5618
diff changeset
25 #include "libavcodec/dsputil.h"
11457
766ca433df3b sparc: fix dsputil prototypes
mru
parents: 11369
diff changeset
26 #include "dsputil_vis.h"
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
27
11369
98970e51365a Remove DECLARE_ALIGNED_{8,16} macros
mru
parents: 10961
diff changeset
28 static const DECLARE_ALIGNED(8, int16_t, coeffs)[28] = {
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
29 - 1259,- 1259,- 1259,- 1259,
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
30 - 4989,- 4989,- 4989,- 4989,
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
31 -11045,-11045,-11045,-11045,
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
32 -19195,-19195,-19195,-19195,
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
33 -29126,-29126,-29126,-29126,
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
34 25080, 25080, 25080, 25080,
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
35 12785, 12785, 12785, 12785
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
36 };
11369
98970e51365a Remove DECLARE_ALIGNED_{8,16} macros
mru
parents: 10961
diff changeset
37 static const DECLARE_ALIGNED(8, uint16_t, scale)[4] = {
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
38 65536>>6, 65536>>6, 65536>>6, 65536>>6
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
39 };
11369
98970e51365a Remove DECLARE_ALIGNED_{8,16} macros
mru
parents: 10961
diff changeset
40 static const DECLARE_ALIGNED(8, uint16_t, rounder)[4] = {
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
41 1<<5, 1<<5, 1<<5, 1<<5
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
42 };
11369
98970e51365a Remove DECLARE_ALIGNED_{8,16} macros
mru
parents: 10961
diff changeset
43 static const DECLARE_ALIGNED(8, uint16_t, expand)[4] = {
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
44 1<<14, 1<<14, 1<<14, 1<<14
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
45 };
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
46
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
47 #define INIT_IDCT \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
48 "ldd [%1], %%f32 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
49 "ldd [%1+8], %%f34 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
50 "ldd [%1+16], %%f36 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
51 "ldd [%1+24], %%f38 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
52 "ldd [%1+32], %%f40 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
53 "ldd [%1+40], %%f42 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
54 "ldd [%1+48], %%f44 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
55 "ldd [%0], %%f46 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
56 "fzero %%f62 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
57
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
58 #define LOADSCALE(in) \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
59 "ldd [" in "], %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
60 "ldd [" in "+16], %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
61 "ldd [" in "+32], %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
62 "ldd [" in "+48], %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
63 "ldd [" in "+64], %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
64 "ldd [" in "+80], %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
65 "ldd [" in "+96], %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
66 "ldd [" in "+112], %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
67 "fpadd16 %%f0, %%f0, %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
68 "fpadd16 %%f2, %%f2, %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
69 "fpadd16 %%f4, %%f4, %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
70 "fpadd16 %%f6, %%f6, %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
71 "fpadd16 %%f8, %%f8, %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
72 "fpadd16 %%f10, %%f10, %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
73 "fpadd16 %%f12, %%f12, %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
74 "fpadd16 %%f14, %%f14, %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
75 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
76 "fpadd16 %%f0, %%f0, %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
77 "fpadd16 %%f2, %%f2, %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
78 "fpadd16 %%f4, %%f4, %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
79 "fpadd16 %%f6, %%f6, %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
80 "fpadd16 %%f8, %%f8, %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
81 "fpadd16 %%f10, %%f10, %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
82 "fpadd16 %%f12, %%f12, %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
83 "fpadd16 %%f14, %%f14, %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
84 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
85 "fpadd16 %%f0, %%f0, %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
86 "fpadd16 %%f2, %%f2, %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
87 "fpadd16 %%f4, %%f4, %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
88 "fpadd16 %%f6, %%f6, %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
89 "fpadd16 %%f8, %%f8, %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
90 "fpadd16 %%f10, %%f10, %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
91 "fpadd16 %%f12, %%f12, %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
92 "fpadd16 %%f14, %%f14, %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
93 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
94 "fpadd16 %%f0, %%f0, %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
95 "fpadd16 %%f2, %%f2, %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
96 "fpadd16 %%f4, %%f4, %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
97 "fpadd16 %%f6, %%f6, %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
98 "fpadd16 %%f8, %%f8, %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
99 "fpadd16 %%f10, %%f10, %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
100 "fpadd16 %%f12, %%f12, %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
101 "fpadd16 %%f14, %%f14, %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
102
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
103 #define LOAD(in) \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
104 "ldd [" in "], %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
105 "ldd [" in "+8], %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
106 "ldd [" in "+16], %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
107 "ldd [" in "+24], %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
108 "ldd [" in "+32], %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
109 "ldd [" in "+40], %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
110 "ldd [" in "+48], %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
111 "ldd [" in "+56], %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
112
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
113 #define TRANSPOSE \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
114 "fpmerge %%f16, %%f24, %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
115 "fpmerge %%f20, %%f28, %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
116 "fpmerge %%f17, %%f25, %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
117 "fpmerge %%f21, %%f29, %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
118 "fpmerge %%f18, %%f26, %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
119 "fpmerge %%f22, %%f30, %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
120 "fpmerge %%f19, %%f27, %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
121 "fpmerge %%f23, %%f31, %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
122 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
123 "fpmerge %%f0, %%f2, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
124 "fpmerge %%f1, %%f3, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
125 "fpmerge %%f4, %%f6, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
126 "fpmerge %%f5, %%f7, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
127 "fpmerge %%f8, %%f10, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
128 "fpmerge %%f9, %%f11, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
129 "fpmerge %%f12, %%f14, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
130 "fpmerge %%f13, %%f15, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
131 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
132 "fpmerge %%f16, %%f17, %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
133 "fpmerge %%f18, %%f19, %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
134 "fpmerge %%f20, %%f21, %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
135 "fpmerge %%f22, %%f23, %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
136 "fpmerge %%f24, %%f25, %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
137 "fpmerge %%f26, %%f27, %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
138 "fpmerge %%f28, %%f29, %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
139 "fpmerge %%f30, %%f31, %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
140
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
141 #define IDCT4ROWS \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
142 /* 1. column */\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
143 "fmul8ulx16 %%f0, %%f38, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
144 "for %%f4, %%f6, %%f60 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
145 "fmul8ulx16 %%f2, %%f32, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
146 "fmul8ulx16 %%f2, %%f36, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
147 "fmul8ulx16 %%f2, %%f40, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
148 "fmul8ulx16 %%f2, %%f44, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
149 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
150 ADDROUNDER\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
151 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
152 "fmul8sux16 %%f0, %%f38, %%f48 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
153 "fcmpd %%fcc0, %%f62, %%f60 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
154 "for %%f8, %%f10, %%f60 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
155 "fmul8sux16 %%f2, %%f32, %%f50 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
156 "fmul8sux16 %%f2, %%f36, %%f52 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
157 "fmul8sux16 %%f2, %%f40, %%f54 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
158 "fmul8sux16 %%f2, %%f44, %%f56 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
159 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
160 "fpadd16 %%f48, %%f28, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
161 "fcmpd %%fcc1, %%f62, %%f60 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
162 "for %%f12, %%f14, %%f60 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
163 "fpadd16 %%f50, %%f18, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
164 "fpadd16 %%f52, %%f22, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
165 "fpadd16 %%f54, %%f26, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
166 "fpadd16 %%f56, %%f30, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
167 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
168 "fpadd16 %%f28, %%f0, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
169 "fcmpd %%fcc2, %%f62, %%f60 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
170 "fpadd16 %%f28, %%f0, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
171 "fpadd16 %%f28, %%f0, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
172 "fpadd16 %%f28, %%f0, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
173 "fpadd16 %%f18, %%f2, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
174 "fpadd16 %%f22, %%f2, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
175 /* 2. column */\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
176 "fbe %%fcc0, 3f \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
177 "fpadd16 %%f26, %%f2, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
178 "fmul8ulx16 %%f4, %%f34, %%f48 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
179 "fmul8ulx16 %%f4, %%f42, %%f50 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
180 "fmul8ulx16 %%f6, %%f36, %%f52 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
181 "fmul8ulx16 %%f6, %%f44, %%f54 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
182 "fmul8ulx16 %%f6, %%f32, %%f56 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
183 "fmul8ulx16 %%f6, %%f40, %%f58 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
184 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
185 "fpadd16 %%f16, %%f48, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
186 "fpadd16 %%f20, %%f50, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
187 "fpsub16 %%f24, %%f50, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
188 "fpsub16 %%f28, %%f48, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
189 "fpadd16 %%f18, %%f52, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
190 "fpsub16 %%f22, %%f54, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
191 "fpsub16 %%f26, %%f56, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
192 "fpsub16 %%f30, %%f58, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
193 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
194 "fmul8sux16 %%f4, %%f34, %%f48 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
195 "fmul8sux16 %%f4, %%f42, %%f50 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
196 "fmul8sux16 %%f6, %%f36, %%f52 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
197 "fmul8sux16 %%f6, %%f44, %%f54 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
198 "fmul8sux16 %%f6, %%f32, %%f56 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
199 "fmul8sux16 %%f6, %%f40, %%f58 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
200 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
201 "fpadd16 %%f16, %%f48, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
202 "fpadd16 %%f20, %%f50, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
203 "fpsub16 %%f24, %%f50, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
204 "fpsub16 %%f28, %%f48, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
205 "fpadd16 %%f18, %%f52, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
206 "fpsub16 %%f22, %%f54, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
207 "fpsub16 %%f26, %%f56, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
208 "fpsub16 %%f30, %%f58, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
209 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
210 "fpadd16 %%f16, %%f4, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
211 "fpsub16 %%f28, %%f4, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
212 "fpadd16 %%f18, %%f6, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
213 "fpsub16 %%f26, %%f6, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
214 /* 3. column */\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
215 "3: \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
216 "fbe %%fcc1, 4f \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
217 "fpsub16 %%f30, %%f6, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
218 "fmul8ulx16 %%f8, %%f38, %%f48 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
219 "fmul8ulx16 %%f10, %%f40, %%f50 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
220 "fmul8ulx16 %%f10, %%f32, %%f52 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
221 "fmul8ulx16 %%f10, %%f44, %%f54 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
222 "fmul8ulx16 %%f10, %%f36, %%f56 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
223 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
224 "fpadd16 %%f16, %%f48, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
225 "fpsub16 %%f20, %%f48, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
226 "fpsub16 %%f24, %%f48, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
227 "fpadd16 %%f28, %%f48, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
228 "fpadd16 %%f18, %%f50, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
229 "fpsub16 %%f22, %%f52, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
230 "fpadd16 %%f26, %%f54, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
231 "fpadd16 %%f30, %%f56, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
232 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
233 "fmul8sux16 %%f8, %%f38, %%f48 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
234 "fmul8sux16 %%f10, %%f40, %%f50 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
235 "fmul8sux16 %%f10, %%f32, %%f52 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
236 "fmul8sux16 %%f10, %%f44, %%f54 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
237 "fmul8sux16 %%f10, %%f36, %%f56 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
238 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
239 "fpadd16 %%f16, %%f48, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
240 "fpsub16 %%f20, %%f48, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
241 "fpsub16 %%f24, %%f48, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
242 "fpadd16 %%f28, %%f48, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
243 "fpadd16 %%f18, %%f50, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
244 "fpsub16 %%f22, %%f52, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
245 "fpadd16 %%f26, %%f54, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
246 "fpadd16 %%f30, %%f56, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
247 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
248 "fpadd16 %%f16, %%f8, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
249 "fpsub16 %%f20, %%f8, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
250 "fpsub16 %%f24, %%f8, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
251 "fpadd16 %%f28, %%f8, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
252 "fpadd16 %%f18, %%f10, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
253 "fpsub16 %%f22, %%f10, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
254 /* 4. column */\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
255 "4: \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
256 "fbe %%fcc2, 5f \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
257 "fpadd16 %%f30, %%f10, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
258 "fmul8ulx16 %%f12, %%f42, %%f48 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
259 "fmul8ulx16 %%f12, %%f34, %%f50 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
260 "fmul8ulx16 %%f14, %%f44, %%f52 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
261 "fmul8ulx16 %%f14, %%f40, %%f54 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
262 "fmul8ulx16 %%f14, %%f36, %%f56 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
263 "fmul8ulx16 %%f14, %%f32, %%f58 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
264 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
265 "fpadd16 %%f16, %%f48, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
266 "fpsub16 %%f20, %%f50, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
267 "fpadd16 %%f24, %%f50, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
268 "fpsub16 %%f28, %%f48, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
269 "fpadd16 %%f18, %%f52, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
270 "fpsub16 %%f22, %%f54, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
271 "fpadd16 %%f26, %%f56, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
272 "fpsub16 %%f30, %%f58, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
273 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
274 "fmul8sux16 %%f12, %%f42, %%f48 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
275 "fmul8sux16 %%f12, %%f34, %%f50 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
276 "fmul8sux16 %%f14, %%f44, %%f52 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
277 "fmul8sux16 %%f14, %%f40, %%f54 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
278 "fmul8sux16 %%f14, %%f36, %%f56 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
279 "fmul8sux16 %%f14, %%f32, %%f58 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
280 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
281 "fpadd16 %%f16, %%f48, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
282 "fpsub16 %%f20, %%f50, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
283 "fpadd16 %%f24, %%f50, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
284 "fpsub16 %%f28, %%f48, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
285 "fpadd16 %%f18, %%f52, %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
286 "fpsub16 %%f22, %%f54, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
287 "fpadd16 %%f26, %%f56, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
288 "fpsub16 %%f30, %%f58, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
289 \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
290 "fpsub16 %%f20, %%f12, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
291 "fpadd16 %%f24, %%f12, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
292 "fpsub16 %%f22, %%f14, %%f22 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
293 "fpadd16 %%f26, %%f14, %%f26 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
294 "fpsub16 %%f30, %%f14, %%f30 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
295 /* final butterfly */\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
296 "5: \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
297 "fpsub16 %%f16, %%f18, %%f48 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
298 "fpsub16 %%f20, %%f22, %%f50 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
299 "fpsub16 %%f24, %%f26, %%f52 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
300 "fpsub16 %%f28, %%f30, %%f54 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
301 "fpadd16 %%f16, %%f18, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
302 "fpadd16 %%f20, %%f22, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
303 "fpadd16 %%f24, %%f26, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
304 "fpadd16 %%f28, %%f30, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
305
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
306 #define STOREROWS(out) \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
307 "std %%f48, [" out "+112] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
308 "std %%f50, [" out "+96] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
309 "std %%f52, [" out "+80] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
310 "std %%f54, [" out "+64] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
311 "std %%f16, [" out "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
312 "std %%f20, [" out "+16] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
313 "std %%f24, [" out "+32] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
314 "std %%f28, [" out "+48] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
315
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
316 #define SCALEROWS \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
317 "fmul8sux16 %%f46, %%f48, %%f48 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
318 "fmul8sux16 %%f46, %%f50, %%f50 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
319 "fmul8sux16 %%f46, %%f52, %%f52 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
320 "fmul8sux16 %%f46, %%f54, %%f54 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
321 "fmul8sux16 %%f46, %%f16, %%f16 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
322 "fmul8sux16 %%f46, %%f20, %%f20 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
323 "fmul8sux16 %%f46, %%f24, %%f24 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
324 "fmul8sux16 %%f46, %%f28, %%f28 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
325
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
326 #define PUTPIXELSCLAMPED(dest) \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
327 "fpack16 %%f48, %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
328 "fpack16 %%f50, %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
329 "fpack16 %%f16, %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
330 "fpack16 %%f20, %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
331 "fpack16 %%f24, %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
332 "fpack16 %%f28, %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
333 "fpack16 %%f54, %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
334 "fpack16 %%f52, %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
335 "st %%f0, [%3+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
336 "st %%f2, [%5+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
337 "st %%f4, [%6+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
338 "st %%f6, [%7+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
339 "st %%f8, [%8+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
340 "st %%f10, [%9+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
341 "st %%f12, [%10+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
342 "st %%f14, [%11+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
343
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
344 #define ADDPIXELSCLAMPED(dest) \
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
345 "ldd [%5], %%f18 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
346 "ld [%3+" dest"], %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
347 "ld [%6+" dest"], %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
348 "ld [%7+" dest"], %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
349 "ld [%8+" dest"], %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
350 "ld [%9+" dest"], %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
351 "ld [%10+" dest"], %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
352 "ld [%11+" dest"], %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
353 "ld [%12+" dest"], %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
354 "fmul8x16 %%f0, %%f18, %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
355 "fmul8x16 %%f2, %%f18, %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
356 "fmul8x16 %%f4, %%f18, %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
357 "fmul8x16 %%f6, %%f18, %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
358 "fmul8x16 %%f8, %%f18, %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
359 "fmul8x16 %%f10, %%f18, %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
360 "fmul8x16 %%f12, %%f18, %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
361 "fmul8x16 %%f14, %%f18, %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
362 "fpadd16 %%f0, %%f16, %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
363 "fpadd16 %%f2, %%f20, %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
364 "fpadd16 %%f4, %%f24, %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
365 "fpadd16 %%f6, %%f28, %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
366 "fpadd16 %%f8, %%f54, %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
367 "fpadd16 %%f10, %%f52, %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
368 "fpadd16 %%f12, %%f50, %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
369 "fpadd16 %%f14, %%f48, %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
370 "fpack16 %%f0, %%f0 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
371 "fpack16 %%f2, %%f2 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
372 "fpack16 %%f4, %%f4 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
373 "fpack16 %%f6, %%f6 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
374 "fpack16 %%f8, %%f8 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
375 "fpack16 %%f10, %%f10 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
376 "fpack16 %%f12, %%f12 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
377 "fpack16 %%f14, %%f14 \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
378 "st %%f0, [%3+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
379 "st %%f2, [%6+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
380 "st %%f4, [%7+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
381 "st %%f6, [%8+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
382 "st %%f8, [%9+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
383 "st %%f10, [%10+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
384 "st %%f12, [%11+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
385 "st %%f14, [%12+" dest "] \n\t"\
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
386
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
387
8285
197fe6f703a3 Remove useless inline qualifier, fixes linking with gcc 4.3.
diego
parents: 8031
diff changeset
388 void ff_simple_idct_vis(DCTELEM *data) {
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
389 int out1, out2, out3, out4;
11369
98970e51365a Remove DECLARE_ALIGNED_{8,16} macros
mru
parents: 10961
diff changeset
390 DECLARE_ALIGNED(8, int16_t, temp)[8*8];
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
391
8031
eebc7209c47f Convert asm keyword into __asm__.
flameeyes
parents: 6763
diff changeset
392 __asm__ volatile(
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
393 INIT_IDCT
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
394
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
395 #define ADDROUNDER
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
396
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
397 // shift right 16-4=12
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
398 LOADSCALE("%2+8")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
399 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
400 STOREROWS("%3+8")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
401 LOADSCALE("%2+0")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
402 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
403 "std %%f48, [%3+112] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
404 "std %%f50, [%3+96] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
405 "std %%f52, [%3+80] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
406 "std %%f54, [%3+64] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
407
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
408 // shift right 16+4
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
409 "ldd [%3+8], %%f18 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
410 "ldd [%3+24], %%f22 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
411 "ldd [%3+40], %%f26 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
412 "ldd [%3+56], %%f30 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
413 TRANSPOSE
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
414 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
415 SCALEROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
416 STOREROWS("%2+0")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
417 LOAD("%3+64")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
418 TRANSPOSE
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
419 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
420 SCALEROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
421 STOREROWS("%2+8")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
422
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
423 : "=r" (out1), "=r" (out2), "=r" (out3), "=r" (out4)
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
424 : "0" (scale), "1" (coeffs), "2" (data), "3" (temp)
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
425 );
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
426 }
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
427
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
428 void ff_simple_idct_put_vis(uint8_t *dest, int line_size, DCTELEM *data) {
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
429 int out1, out2, out3, out4, out5;
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
430 int r1, r2, r3, r4, r5, r6, r7;
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
431
8031
eebc7209c47f Convert asm keyword into __asm__.
flameeyes
parents: 6763
diff changeset
432 __asm__ volatile(
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
433 "wr %%g0, 0x8, %%gsr \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
434
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
435 INIT_IDCT
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
436
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
437 "add %3, %4, %5 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
438 "add %5, %4, %6 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
439 "add %6, %4, %7 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
440 "add %7, %4, %8 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
441 "add %8, %4, %9 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
442 "add %9, %4, %10 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
443 "add %10, %4, %11 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
444
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
445 // shift right 16-4=12
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
446 LOADSCALE("%2+8")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
447 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
448 STOREROWS("%2+8")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
449 LOADSCALE("%2+0")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
450 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
451 "std %%f48, [%2+112] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
452 "std %%f50, [%2+96] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
453 "std %%f52, [%2+80] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
454 "std %%f54, [%2+64] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
455
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
456 #undef ADDROUNDER
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
457 #define ADDROUNDER "fpadd16 %%f28, %%f46, %%f28 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
458
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
459 // shift right 16+4
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
460 "ldd [%2+8], %%f18 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
461 "ldd [%2+24], %%f22 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
462 "ldd [%2+40], %%f26 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
463 "ldd [%2+56], %%f30 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
464 TRANSPOSE
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
465 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
466 PUTPIXELSCLAMPED("0")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
467 LOAD("%2+64")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
468 TRANSPOSE
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
469 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
470 PUTPIXELSCLAMPED("4")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
471
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
472 : "=r" (out1), "=r" (out2), "=r" (out3), "=r" (out4), "=r" (out5),
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
473 "=r" (r1), "=r" (r2), "=r" (r3), "=r" (r4), "=r" (r5), "=r" (r6), "=r" (r7)
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
474 : "0" (rounder), "1" (coeffs), "2" (data), "3" (dest), "4" (line_size)
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
475 );
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
476 }
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
477
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
478 void ff_simple_idct_add_vis(uint8_t *dest, int line_size, DCTELEM *data) {
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
479 int out1, out2, out3, out4, out5, out6;
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
480 int r1, r2, r3, r4, r5, r6, r7;
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
481
8031
eebc7209c47f Convert asm keyword into __asm__.
flameeyes
parents: 6763
diff changeset
482 __asm__ volatile(
5618
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
483 "wr %%g0, 0x8, %%gsr \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
484
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
485 INIT_IDCT
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
486
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
487 "add %3, %4, %6 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
488 "add %6, %4, %7 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
489 "add %7, %4, %8 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
490 "add %8, %4, %9 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
491 "add %9, %4, %10 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
492 "add %10, %4, %11 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
493 "add %11, %4, %12 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
494
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
495 #undef ADDROUNDER
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
496 #define ADDROUNDER
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
497
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
498 // shift right 16-4=12
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
499 LOADSCALE("%2+8")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
500 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
501 STOREROWS("%2+8")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
502 LOADSCALE("%2+0")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
503 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
504 "std %%f48, [%2+112] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
505 "std %%f50, [%2+96] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
506 "std %%f52, [%2+80] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
507 "std %%f54, [%2+64] \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
508
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
509 #undef ADDROUNDER
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
510 #define ADDROUNDER "fpadd16 %%f28, %%f46, %%f28 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
511
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
512 // shift right 16+4
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
513 "ldd [%2+8], %%f18 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
514 "ldd [%2+24], %%f22 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
515 "ldd [%2+40], %%f26 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
516 "ldd [%2+56], %%f30 \n\t"
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
517 TRANSPOSE
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
518 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
519 ADDPIXELSCLAMPED("0")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
520 LOAD("%2+64")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
521 TRANSPOSE
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
522 IDCT4ROWS
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
523 ADDPIXELSCLAMPED("4")
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
524
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
525 : "=r" (out1), "=r" (out2), "=r" (out3), "=r" (out4), "=r" (out5), "=r" (out6),
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
526 "=r" (r1), "=r" (r2), "=r" (r3), "=r" (r4), "=r" (r5), "=r" (r6), "=r" (r7)
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
527 : "0" (rounder), "1" (coeffs), "2" (data), "3" (dest), "4" (line_size), "5" (expand)
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
528 );
ad0ab0eebd69 add simple_idct implemented in Sparc VIS
gpoirier
parents:
diff changeset
529 }