Rev 107 | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
2 | pj | 1 | /* |
2 | * Copyright (c) 1997-1999 Massachusetts Institute of Technology |
||
3 | * |
||
4 | * This program is free software; you can redistribute it and/or modify |
||
5 | * it under the terms of the GNU General Public License as published by |
||
6 | * the Free Software Foundation; either version 2 of the License, or |
||
7 | * (at your option) any later version. |
||
8 | * |
||
9 | * This program is distributed in the hope that it will be useful, |
||
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
||
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||
12 | * GNU General Public License for more details. |
||
13 | * |
||
14 | * You should have received a copy of the GNU General Public License |
||
15 | * along with this program; if not, write to the Free Software |
||
16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
||
17 | * |
||
18 | */ |
||
19 | |||
20 | /* This file was automatically generated --- DO NOT EDIT */ |
||
21 | /* Generated on Tue May 18 13:56:00 EDT 1999 */ |
||
22 | |||
107 | pj | 23 | #include <fftw-int.h> |
24 | #include <fftw.h> |
||
2 | pj | 25 | |
26 | /* Generated by: ./genfft -magic-alignment-check -magic-twiddle-load-all -magic-variables 4 -magic-loopi -hc2hc-backward 6 */ |
||
27 | |||
28 | /* |
||
29 | * This function contains 72 FP additions, 38 FP multiplications, |
||
30 | * (or, 54 additions, 20 multiplications, 18 fused multiply/add), |
||
31 | * 25 stack variables, and 48 memory accesses |
||
32 | */ |
||
33 | static const fftw_real K500000000 = FFTW_KONST(+0.500000000000000000000000000000000000000000000); |
||
34 | static const fftw_real K866025403 = FFTW_KONST(+0.866025403784438646763723170752936183471402627); |
||
35 | static const fftw_real K2_000000000 = FFTW_KONST(+2.000000000000000000000000000000000000000000000); |
||
36 | static const fftw_real K1_732050807 = FFTW_KONST(+1.732050807568877293527446341505872366942805254); |
||
37 | |||
38 | /* |
||
39 | * Generator Id's : |
||
107 | pj | 40 | * $Id: fhb_6.c,v 1.2 2003-03-24 11:14:57 pj Exp $ |
41 | * $Id: fhb_6.c,v 1.2 2003-03-24 11:14:57 pj Exp $ |
||
42 | * $Id: fhb_6.c,v 1.2 2003-03-24 11:14:57 pj Exp $ |
||
2 | pj | 43 | */ |
44 | |||
45 | void fftw_hc2hc_backward_6(fftw_real *A, const fftw_complex *W, int iostride, int m, int dist) |
||
46 | { |
||
47 | int i; |
||
48 | fftw_real *X; |
||
49 | fftw_real *Y; |
||
50 | X = A; |
||
51 | Y = A + (6 * iostride); |
||
52 | { |
||
53 | fftw_real tmp71; |
||
54 | fftw_real tmp75; |
||
55 | fftw_real tmp80; |
||
56 | fftw_real tmp82; |
||
57 | fftw_real tmp74; |
||
58 | fftw_real tmp76; |
||
59 | fftw_real tmp69; |
||
60 | fftw_real tmp70; |
||
61 | fftw_real tmp77; |
||
62 | fftw_real tmp81; |
||
63 | ASSERT_ALIGNED_DOUBLE(); |
||
64 | tmp69 = X[0]; |
||
65 | tmp70 = X[3 * iostride]; |
||
66 | tmp71 = tmp69 - tmp70; |
||
67 | tmp75 = tmp69 + tmp70; |
||
68 | { |
||
69 | fftw_real tmp78; |
||
70 | fftw_real tmp79; |
||
71 | fftw_real tmp72; |
||
72 | fftw_real tmp73; |
||
73 | ASSERT_ALIGNED_DOUBLE(); |
||
74 | tmp78 = Y[-2 * iostride]; |
||
75 | tmp79 = Y[-iostride]; |
||
76 | tmp80 = K1_732050807 * (tmp78 + tmp79); |
||
77 | tmp82 = K1_732050807 * (tmp78 - tmp79); |
||
78 | tmp72 = X[2 * iostride]; |
||
79 | tmp73 = X[iostride]; |
||
80 | tmp74 = tmp72 - tmp73; |
||
81 | tmp76 = tmp72 + tmp73; |
||
82 | } |
||
83 | X[3 * iostride] = tmp71 + (K2_000000000 * tmp74); |
||
84 | tmp77 = tmp71 - tmp74; |
||
85 | X[iostride] = tmp77 - tmp80; |
||
86 | X[5 * iostride] = tmp77 + tmp80; |
||
87 | X[0] = tmp75 + (K2_000000000 * tmp76); |
||
88 | tmp81 = tmp75 - tmp76; |
||
89 | X[2 * iostride] = tmp81 + tmp82; |
||
90 | X[4 * iostride] = tmp81 - tmp82; |
||
91 | } |
||
92 | X = X + dist; |
||
93 | Y = Y - dist; |
||
94 | for (i = 2; i < m; i = i + 2, X = X + dist, Y = Y - dist, W = W + 5) { |
||
95 | fftw_real tmp15; |
||
96 | fftw_real tmp46; |
||
97 | fftw_real tmp25; |
||
98 | fftw_real tmp52; |
||
99 | fftw_real tmp22; |
||
100 | fftw_real tmp35; |
||
101 | fftw_real tmp49; |
||
102 | fftw_real tmp62; |
||
103 | fftw_real tmp32; |
||
104 | fftw_real tmp39; |
||
105 | fftw_real tmp55; |
||
106 | fftw_real tmp59; |
||
107 | ASSERT_ALIGNED_DOUBLE(); |
||
108 | { |
||
109 | fftw_real tmp13; |
||
110 | fftw_real tmp14; |
||
111 | fftw_real tmp23; |
||
112 | fftw_real tmp24; |
||
113 | ASSERT_ALIGNED_DOUBLE(); |
||
114 | tmp13 = X[0]; |
||
115 | tmp14 = Y[-3 * iostride]; |
||
116 | tmp15 = tmp13 + tmp14; |
||
117 | tmp46 = tmp13 - tmp14; |
||
118 | tmp23 = Y[0]; |
||
119 | tmp24 = X[3 * iostride]; |
||
120 | tmp25 = tmp23 - tmp24; |
||
121 | tmp52 = tmp23 + tmp24; |
||
122 | } |
||
123 | { |
||
124 | fftw_real tmp18; |
||
125 | fftw_real tmp47; |
||
126 | fftw_real tmp21; |
||
127 | fftw_real tmp48; |
||
128 | ASSERT_ALIGNED_DOUBLE(); |
||
129 | { |
||
130 | fftw_real tmp16; |
||
131 | fftw_real tmp17; |
||
132 | fftw_real tmp19; |
||
133 | fftw_real tmp20; |
||
134 | ASSERT_ALIGNED_DOUBLE(); |
||
135 | tmp16 = X[2 * iostride]; |
||
136 | tmp17 = Y[-5 * iostride]; |
||
137 | tmp18 = tmp16 + tmp17; |
||
138 | tmp47 = tmp16 - tmp17; |
||
139 | tmp19 = Y[-4 * iostride]; |
||
140 | tmp20 = X[iostride]; |
||
141 | tmp21 = tmp19 + tmp20; |
||
142 | tmp48 = tmp19 - tmp20; |
||
143 | } |
||
144 | tmp22 = tmp18 + tmp21; |
||
145 | tmp35 = K866025403 * (tmp18 - tmp21); |
||
146 | tmp49 = tmp47 + tmp48; |
||
147 | tmp62 = K866025403 * (tmp47 - tmp48); |
||
148 | } |
||
149 | { |
||
150 | fftw_real tmp28; |
||
151 | fftw_real tmp54; |
||
152 | fftw_real tmp31; |
||
153 | fftw_real tmp53; |
||
154 | ASSERT_ALIGNED_DOUBLE(); |
||
155 | { |
||
156 | fftw_real tmp26; |
||
157 | fftw_real tmp27; |
||
158 | fftw_real tmp29; |
||
159 | fftw_real tmp30; |
||
160 | ASSERT_ALIGNED_DOUBLE(); |
||
161 | tmp26 = Y[-2 * iostride]; |
||
162 | tmp27 = X[5 * iostride]; |
||
163 | tmp28 = tmp26 - tmp27; |
||
164 | tmp54 = tmp26 + tmp27; |
||
165 | tmp29 = Y[-iostride]; |
||
166 | tmp30 = X[4 * iostride]; |
||
167 | tmp31 = tmp29 - tmp30; |
||
168 | tmp53 = tmp29 + tmp30; |
||
169 | } |
||
170 | tmp32 = tmp28 + tmp31; |
||
171 | tmp39 = K866025403 * (tmp31 - tmp28); |
||
172 | tmp55 = tmp53 - tmp54; |
||
173 | tmp59 = K866025403 * (tmp54 + tmp53); |
||
174 | } |
||
175 | X[0] = tmp15 + tmp22; |
||
176 | { |
||
177 | fftw_real tmp36; |
||
178 | fftw_real tmp42; |
||
179 | fftw_real tmp40; |
||
180 | fftw_real tmp44; |
||
181 | fftw_real tmp34; |
||
182 | fftw_real tmp38; |
||
183 | ASSERT_ALIGNED_DOUBLE(); |
||
184 | tmp34 = tmp25 - (K500000000 * tmp32); |
||
185 | tmp36 = tmp34 - tmp35; |
||
186 | tmp42 = tmp35 + tmp34; |
||
187 | tmp38 = tmp15 - (K500000000 * tmp22); |
||
188 | tmp40 = tmp38 - tmp39; |
||
189 | tmp44 = tmp38 + tmp39; |
||
190 | { |
||
191 | fftw_real tmp33; |
||
192 | fftw_real tmp37; |
||
193 | fftw_real tmp41; |
||
194 | fftw_real tmp43; |
||
195 | ASSERT_ALIGNED_DOUBLE(); |
||
196 | tmp33 = c_re(W[1]); |
||
197 | tmp37 = c_im(W[1]); |
||
198 | Y[-3 * iostride] = (tmp33 * tmp36) - (tmp37 * tmp40); |
||
199 | X[2 * iostride] = (tmp37 * tmp36) + (tmp33 * tmp40); |
||
200 | tmp41 = c_re(W[3]); |
||
201 | tmp43 = c_im(W[3]); |
||
202 | Y[-iostride] = (tmp41 * tmp42) - (tmp43 * tmp44); |
||
203 | X[4 * iostride] = (tmp43 * tmp42) + (tmp41 * tmp44); |
||
204 | } |
||
205 | } |
||
206 | Y[-5 * iostride] = tmp25 + tmp32; |
||
207 | { |
||
208 | fftw_real tmp50; |
||
209 | fftw_real tmp56; |
||
210 | fftw_real tmp45; |
||
211 | fftw_real tmp51; |
||
212 | ASSERT_ALIGNED_DOUBLE(); |
||
213 | tmp50 = tmp46 + tmp49; |
||
214 | tmp56 = tmp52 - tmp55; |
||
215 | tmp45 = c_re(W[2]); |
||
216 | tmp51 = c_im(W[2]); |
||
217 | X[3 * iostride] = (tmp45 * tmp50) + (tmp51 * tmp56); |
||
218 | Y[-2 * iostride] = (tmp45 * tmp56) - (tmp51 * tmp50); |
||
219 | } |
||
220 | { |
||
221 | fftw_real tmp60; |
||
222 | fftw_real tmp66; |
||
223 | fftw_real tmp64; |
||
224 | fftw_real tmp68; |
||
225 | fftw_real tmp58; |
||
226 | fftw_real tmp63; |
||
227 | ASSERT_ALIGNED_DOUBLE(); |
||
228 | tmp58 = tmp46 - (K500000000 * tmp49); |
||
229 | tmp60 = tmp58 - tmp59; |
||
230 | tmp66 = tmp58 + tmp59; |
||
231 | tmp63 = tmp52 + (K500000000 * tmp55); |
||
232 | tmp64 = tmp62 + tmp63; |
||
233 | tmp68 = tmp63 - tmp62; |
||
234 | { |
||
235 | fftw_real tmp57; |
||
236 | fftw_real tmp61; |
||
237 | fftw_real tmp65; |
||
238 | fftw_real tmp67; |
||
239 | ASSERT_ALIGNED_DOUBLE(); |
||
240 | tmp57 = c_re(W[0]); |
||
241 | tmp61 = c_im(W[0]); |
||
242 | X[iostride] = (tmp57 * tmp60) + (tmp61 * tmp64); |
||
243 | Y[-4 * iostride] = (tmp57 * tmp64) - (tmp61 * tmp60); |
||
244 | tmp65 = c_re(W[4]); |
||
245 | tmp67 = c_im(W[4]); |
||
246 | X[5 * iostride] = (tmp65 * tmp66) + (tmp67 * tmp68); |
||
247 | Y[0] = (tmp65 * tmp68) - (tmp67 * tmp66); |
||
248 | } |
||
249 | } |
||
250 | } |
||
251 | if (i == m) { |
||
252 | fftw_real tmp1; |
||
253 | fftw_real tmp6; |
||
254 | fftw_real tmp4; |
||
255 | fftw_real tmp5; |
||
256 | fftw_real tmp9; |
||
257 | fftw_real tmp11; |
||
258 | fftw_real tmp12; |
||
259 | fftw_real tmp10; |
||
260 | ASSERT_ALIGNED_DOUBLE(); |
||
261 | tmp1 = X[iostride]; |
||
262 | tmp6 = Y[-iostride]; |
||
263 | { |
||
264 | fftw_real tmp2; |
||
265 | fftw_real tmp3; |
||
266 | fftw_real tmp7; |
||
267 | fftw_real tmp8; |
||
268 | ASSERT_ALIGNED_DOUBLE(); |
||
269 | tmp2 = X[2 * iostride]; |
||
270 | tmp3 = X[0]; |
||
271 | tmp4 = tmp2 + tmp3; |
||
272 | tmp5 = K1_732050807 * (tmp2 - tmp3); |
||
273 | tmp7 = Y[-2 * iostride]; |
||
274 | tmp8 = Y[0]; |
||
275 | tmp9 = tmp7 + tmp8; |
||
276 | tmp11 = K1_732050807 * (tmp7 - tmp8); |
||
277 | } |
||
278 | X[0] = K2_000000000 * (tmp1 + tmp4); |
||
279 | tmp12 = (K2_000000000 * tmp1) - tmp4; |
||
280 | X[2 * iostride] = tmp11 - tmp12; |
||
281 | X[4 * iostride] = tmp12 + tmp11; |
||
282 | X[3 * iostride] = K2_000000000 * (tmp6 - tmp9); |
||
283 | tmp10 = (K2_000000000 * tmp6) + tmp9; |
||
284 | X[iostride] = -(tmp5 + tmp10); |
||
285 | X[5 * iostride] = tmp5 - tmp10; |
||
286 | } |
||
287 | } |
||
288 | |||
289 | static const int twiddle_order[] = |
||
290 | {1, 2, 3, 4, 5}; |
||
291 | fftw_codelet_desc fftw_hc2hc_backward_6_desc = |
||
292 | { |
||
293 | "fftw_hc2hc_backward_6", |
||
294 | (void (*)()) fftw_hc2hc_backward_6, |
||
295 | 6, |
||
296 | FFTW_BACKWARD, |
||
297 | FFTW_HC2HC, |
||
298 | 146, |
||
299 | 5, |
||
300 | twiddle_order, |
||
301 | }; |