source: Deliverables/D2.2/8051-memoryspaces-branch/tests/clight/fir_complexe.Clight.expected @ 1448

Last change on this file since 1448 was 453, checked in by ayache, 10 years ago

Import of the Paris's sources.

File size: 8.0 KB
Line 
1int t1[16];
2
3int t2[16];
4
5int t3[16];
6
7int t4[16];
8
9int t5[16];
10
11int t6[16];
12
13extern void *__builtin___memcpy_chk(void *, void *, unsigned int, unsigned int);
14
15extern void *__builtin___memmove_chk(void *, void *, unsigned int, unsigned int);
16
17extern void *__builtin___mempcpy_chk(void *, void *, unsigned int, unsigned int);
18
19extern void *__builtin___memset_chk(void *, int, unsigned int, unsigned int);
20
21extern unsigned char *__builtin___stpcpy_chk(unsigned char *, unsigned char *, unsigned int);
22
23extern unsigned char *__builtin___strcat_chk(unsigned char *, unsigned char *, unsigned int);
24
25extern unsigned char *__builtin___strcpy_chk(unsigned char *, unsigned char *, unsigned int);
26
27extern unsigned char *__builtin___strncat_chk(unsigned char *, unsigned char *, unsigned int, unsigned int);
28
29extern unsigned char *__builtin___strncpy_chk(unsigned char *, unsigned char *, unsigned int, unsigned int);
30
31extern int __builtin___vfprintf_chk(void *, int, unsigned char *, void *);
32
33extern int __builtin___vprintf_chk(int, unsigned char *, void *);
34
35extern int __builtin___vsnprintf_chk(unsigned char *, unsigned int, int, unsigned int, unsigned char *, void *);
36
37extern int __builtin___vsprintf_chk(unsigned char *, int, unsigned int, unsigned char *, void *);
38
39extern double __builtin_acos(double);
40
41extern float __builtin_acosf(float);
42
43extern double __builtin_acosl(double);
44
45extern void *__builtin_alloca(unsigned int);
46
47extern double __builtin_asin(double);
48
49extern float __builtin_asinf(float);
50
51extern double __builtin_asinl(double);
52
53extern double __builtin_atan(double);
54
55extern float __builtin_atanf(float);
56
57extern double __builtin_atanl(double);
58
59extern double __builtin_atan2(double, double);
60
61extern float __builtin_atan2f(float, float);
62
63extern double __builtin_atan2l(double, double);
64
65extern double __builtin_ceil(double);
66
67extern float __builtin_ceilf(float);
68
69extern double __builtin_ceill(double);
70
71extern double __builtin_cos(double);
72
73extern float __builtin_cosf(float);
74
75extern double __builtin_cosl(double);
76
77extern double __builtin_cosh(double);
78
79extern float __builtin_coshf(float);
80
81extern double __builtin_coshl(double);
82
83extern int __builtin_clz(unsigned int);
84
85extern int __builtin_clzl(unsigned int);
86
87extern int __builtin_clzll(unsigned int);
88
89extern int __builtin_constant_p(int);
90
91extern int __builtin_ctz(unsigned int);
92
93extern int __builtin_ctzl(unsigned int);
94
95extern int __builtin_ctzll(unsigned int);
96
97extern double __builtin_exp(double);
98
99extern float __builtin_expf(float);
100
101extern double __builtin_expl(double);
102
103extern int __builtin_expect(int, int);
104
105extern double __builtin_fabs(double);
106
107extern float __builtin_fabsf(float);
108
109extern double __builtin_fabsl(double);
110
111extern int __builtin_ffs(unsigned int);
112
113extern int __builtin_ffsl(unsigned int);
114
115extern int __builtin_ffsll(unsigned int);
116
117extern void *__builtin_frame_address(unsigned int);
118
119extern double __builtin_floor(double);
120
121extern float __builtin_floorf(float);
122
123extern double __builtin_floorl(double);
124
125extern double __builtin_huge_val(void);
126
127extern float __builtin_huge_valf(void);
128
129extern double __builtin_huge_vall(void);
130
131extern double __builtin_inf(void);
132
133extern float __builtin_inff(void);
134
135extern double __builtin_infl(void);
136
137extern void *__builtin_memcpy(void *, void *, unsigned int);
138
139extern void *__builtin_mempcpy(void *, void *, unsigned int);
140
141extern double __builtin_fmod(double);
142
143extern float __builtin_fmodf(float);
144
145extern double __builtin_fmodl(double);
146
147extern double __builtin_frexp(double, int *);
148
149extern float __builtin_frexpf(float, int *);
150
151extern double __builtin_frexpl(double, int *);
152
153extern double __builtin_ldexp(double, int);
154
155extern float __builtin_ldexpf(float, int);
156
157extern double __builtin_ldexpl(double, int);
158
159extern double __builtin_log(double);
160
161extern float __builtin_logf(float);
162
163extern double __builtin_logl(double);
164
165extern double __builtin_log10(double);
166
167extern float __builtin_log10f(float);
168
169extern double __builtin_log10l(double);
170
171extern float __builtin_modff(float, float *);
172
173extern double __builtin_modfl(double, double *);
174
175extern double __builtin_nan(unsigned char *);
176
177extern float __builtin_nanf(unsigned char *);
178
179extern double __builtin_nanl(unsigned char *);
180
181extern double __builtin_nans(unsigned char *);
182
183extern float __builtin_nansf(unsigned char *);
184
185extern double __builtin_nansl(unsigned char *);
186
187extern void *__builtin_next_arg(void);
188
189extern unsigned int __builtin_object_size(void *, int);
190
191extern int __builtin_parity(unsigned int);
192
193extern int __builtin_parityl(unsigned int);
194
195extern int __builtin_parityll(unsigned int);
196
197extern int __builtin_popcount(unsigned int);
198
199extern int __builtin_popcountl(unsigned int);
200
201extern int __builtin_popcountll(unsigned int);
202
203extern double __builtin_powi(double, int);
204
205extern float __builtin_powif(float, int);
206
207extern double __builtin_powil(double, int);
208
209extern void __builtin_return(void *);
210
211extern void *__builtin_return_address(unsigned int);
212
213extern double __builtin_sin(double);
214
215extern float __builtin_sinf(float);
216
217extern double __builtin_sinl(double);
218
219extern double __builtin_sinh(double);
220
221extern float __builtin_sinhf(float);
222
223extern double __builtin_sinhl(double);
224
225extern double __builtin_sqrt(double);
226
227extern float __builtin_sqrtf(float);
228
229extern double __builtin_sqrtl(double);
230
231extern unsigned char *__builtin_stpcpy(unsigned char *, unsigned char *);
232
233extern unsigned char *__builtin_strchr(unsigned char *, unsigned char);
234
235extern int __builtin_strcmp(unsigned char *, unsigned char *);
236
237extern unsigned char *__builtin_strcpy(unsigned char *, unsigned char *);
238
239extern unsigned int __builtin_strcspn(unsigned char *, unsigned char *);
240
241extern unsigned char *__builtin_strncat(unsigned char *, unsigned char *, unsigned int);
242
243extern int __builtin_strncmp(unsigned char *, unsigned char *, unsigned int);
244
245extern unsigned char *__builtin_strncpy(unsigned char *, unsigned char *, unsigned int);
246
247extern int __builtin_strspn(unsigned char *, unsigned char *);
248
249extern unsigned char *__builtin_strpbrk(unsigned char *, unsigned char *);
250
251extern int __builtin_types_compatible_p(unsigned int, unsigned int);
252
253extern double __builtin_tan(double);
254
255extern float __builtin_tanf(float);
256
257extern double __builtin_tanl(double);
258
259extern double __builtin_tanh(double);
260
261extern float __builtin_tanhf(float);
262
263extern double __builtin_tanhl(double);
264
265extern void __builtin_va_end(void *);
266
267extern void __builtin_varargs_start(void *);
268
269extern void __builtin_va_start(void *, void *);
270
271extern void __builtin_stdarg_start(void *);
272
273extern void __builtin_va_arg(void *, unsigned int);
274
275extern void __builtin_va_copy(void *, void *);
276
277void init(void)
278{
279  int i;
280  c9:
281  for (({ c8: i = 0; }); (/* c7 */ i < 16); ({ c6: i = i + 1; })) {
282    c5:
283    t1[i] = 2;
284    c4:
285    t2[i] = 2;
286    c3:
287    t3[i] = 2;
288    c2:
289    t4[i] = 2;
290    c1:
291    t5[i] = 2;
292    c0:
293    t6[i] = 2;
294  }
295}
296
297int comp_fir_complexe(int *in_re, int *in_im, int *c_re, int *c_im, int *out_re, int *out_im, int size)
298{
299  int i;
300  int j;
301  int res_re;
302  int res_im;
303  int tmp_im;
304  int tmp_re;
305  int tmp_x_re;
306  int tmp_x_im;
307  int x_re[16];
308  int x_im[16];
309  int ii;
310  int adx;
311  c39:
312  for (({ c38: ii = 0; }); (/* c37 */ ii < 16); ({ c36: ii = ii + 1; })) {
313    c35:
314    x_re[ii] = 0;
315    c34:
316    x_im[ii] = 0;
317  }
318  c33:
319  adx = 0;
320  c32:
321  res_re = 0;
322  c31:
323  res_im = 0;
324  c30:
325  for (({ c29: j = 0; }); (/* c28 */ j < size); ({ c27: j = j + 1; })) {
326    c26:
327    x_re[adx] = in_re[j];
328    c25:
329    x_im[adx] = in_im[j];
330    c24:
331    for (({ c23: i = 0; }); (/* c22 */ i < 16); ({ c21: i = i + 1; })) {
332      c20:
333      tmp_x_re = x_re[adx];
334      c19:
335      tmp_x_im = x_im[adx];
336      c18:
337      tmp_re = (tmp_x_re * c_re[i] - tmp_x_im * c_im[i]) >> 4;
338      c17:
339      tmp_im = (tmp_x_re * c_im[i] + tmp_x_im * c_re[i]) >> 4;
340      c16:
341      res_re = res_re + tmp_re;
342      c15:
343      res_im = res_im + tmp_im;
344      c14:
345      adx = (adx + 1) % 16;
346    }
347    c13:
348    adx = (adx + 1) % 16;
349    c12:
350    out_re[j] = res_re;
351    c11:
352    out_im[j] = res_im;
353  }
354  c10:
355  return 0;
356}
357
358int main(void)
359{
360  int t;
361  c42:
362  init();
363  c41:
364  t = comp_fir_complexe(t1, t2, t3, t4, t5, t6, 16);
365  c40:
366  return t;
367}
368
369
Note: See TracBrowser for help on using the repository browser.