OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [libgcc/] [config/] [libbid/] [bid_conf.h] - Blame information for rev 280

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 272 jeremybenn
/* Copyright (C) 2007, 2009  Free Software Foundation, Inc.
2
 
3
This file is part of GCC.
4
 
5
GCC is free software; you can redistribute it and/or modify it under
6
the terms of the GNU General Public License as published by the Free
7
Software Foundation; either version 3, or (at your option) any later
8
version.
9
 
10
GCC is distributed in the hope that it will be useful, but WITHOUT ANY
11
WARRANTY; without even the implied warranty of MERCHANTABILITY or
12
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
13
for more details.
14
 
15
Under Section 7 of GPL version 3, you are granted additional
16
permissions described in the GCC Runtime Library Exception, version
17
3.1, as published by the Free Software Foundation.
18
 
19
You should have received a copy of the GNU General Public License and
20
a copy of the GCC Runtime Library Exception along with this program;
21
see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
22
<http://www.gnu.org/licenses/>.  */
23
 
24
#ifndef _BID_CONF_H
25
#define _BID_CONF_H
26
 
27
// Name Changes
28
 
29
#define _IDEC_glbflags __bid_IDEC_glbflags
30
#define _IDEC_glbround __bid_IDEC_glbround
31
#define _IDEC_glbexcepthandling __bid_IDEC_glbexcepthandling
32
#define _IDEC_glbexceptionmasks __bid_IDEC_glbexceptionmasks
33
#define bid64_add __bid64_add
34
#define bid64_sub __bid64_sub
35
#define bid64_mul __bid64_mul
36
#define bid64_div __bid64_div
37
#define bid64dq_div __bid64dq_div
38
#define bid64qd_div __bid64qd_div
39
#define bid64qq_div __bid64qq_div
40
#define bid64q_sqrt __bid64q_sqrt
41
#define bid64_sqrt __bid64_sqrt
42
#define bid64_rem __bid64_rem
43
#define bid64_fma __bid64_fma
44
#define bid64_scalb __bid64_scalb
45
#define round128_19_38 __bid_round128_19_38
46
#define round192_39_57 __bid_round192_39_57
47
#define round256_58_76 __bid_round256_58_76
48
#define round64_2_18 __bid_round64_2_18
49
#define bid64_nextafter __bid64_nextafter
50
#define bid64_nextdown __bid64_nextdown
51
#define bid64_nextup __bid64_nextup
52
#define b2d __bid_b2d
53
#define b2d2 __bid_b2d2
54
#define b2d3 __bid_b2d3
55
#define b2d4 __bid_b2d4
56
#define b2d5 __bid_b2d5
57
#define bid128_canonize __bid128_canonize
58
#define bid32_canonize __bid32_canonize
59
#define bid64_canonize __bid64_canonize
60
#define bid_to_bid128 __bid_to_bid128
61
#define bid_to_bid32 __bid_to_bid32
62
#define bid_to_bid64 __bid_to_bid64
63
#define bid_to_dpd128 __bid_to_dpd128
64
#define bid_to_dpd32 __bid_to_dpd32
65
#define bid_to_dpd64 __bid_to_dpd64
66
#define d2b __bid_d2b
67
#define d2b2 __bid_d2b2
68
#define d2b3 __bid_d2b3
69
#define d2b4 __bid_d2b4
70
#define d2b5 __bid_d2b5
71
#define d2b6 __bid_d2b6
72
#define dpd_to_bid128 __bid_dpd_to_bid128
73
#define dpd_to_bid32 __bid_dpd_to_bid32
74
#define dpd_to_bid64 __bid_dpd_to_bid64
75
#define bid128_nextafter __bid128_nextafter
76
#define bid128_nextdown __bid128_nextdown
77
#define bid128_nextup __bid128_nextup
78
#define bid64_logb __bid64_logb
79
#define bid64_quantize __bid64_quantize
80
#define estimate_bin_expon __bid_estimate_bin_expon
81
#define estimate_decimal_digits __bid_estimate_decimal_digits
82
#define power10_index_binexp __bid_power10_index_binexp
83
#define power10_index_binexp_128 __bid_power10_index_binexp_128
84
#define power10_table_128 __bid_power10_table_128
85
#define reciprocals10_128 __bid_reciprocals10_128
86
#define reciprocals10_64 __bid_reciprocals10_64
87
#define recip_scale __bid_recip_scale
88
#define round_const_table __bid_round_const_table
89
#define round_const_table_128 __bid_round_const_table_128
90
#define short_recip_scale __bid_short_recip_scale
91
#define bid64_from_string __bid64_from_string
92
#define bid64_to_string __bid64_to_string
93
#define Inv_Tento9 __bid_Inv_Tento9
94
#define midi_tbl __bid_midi_tbl
95
#define Tento3 __bid_Tento3
96
#define Tento6 __bid_Tento6
97
#define Tento9 __bid_Tento9
98
#define Twoto30_m_10to9 __bid_Twoto30_m_10to9
99
#define Twoto60 __bid_Twoto60
100
#define Twoto60_m_10to18 __bid_Twoto60_m_10to18
101
#define convert_table __bid_convert_table
102
#define factors __bid_factors
103
#define packed_10000_zeros __bid_packed_10000_zeros
104
#define char_table2 __bid_char_table2
105
#define char_table3 __bid_char_table3
106
#define Ex128m128 __bid_Ex128m128
107
#define Ex192m192 __bid_Ex192m192
108
#define Ex256m256 __bid_Ex256m256
109
#define Ex64m64 __bid_Ex64m64
110
#define half128 __bid_half128
111
#define half192 __bid_half192
112
#define half256 __bid_half256
113
#define half64 __bid_half64
114
#define Kx128 __bid_Kx128
115
#define Kx192 __bid_Kx192
116
#define Kx256 __bid_Kx256
117
#define Kx64 __bid_Kx64
118
#define mask128 __bid_mask128
119
#define mask192 __bid_mask192
120
#define mask256 __bid_mask256
121
#define mask64 __bid_mask64
122
#define maskhigh128 __bid_maskhigh128
123
#define maskhigh128M __bid_maskhigh128M
124
#define maskhigh192M __bid_maskhigh192M
125
#define maskhigh256M __bid_maskhigh256M
126
#define midpoint128 __bid_midpoint128
127
#define midpoint192 __bid_midpoint192
128
#define midpoint256 __bid_midpoint256
129
#define midpoint64 __bid_midpoint64
130
#define nr_digits __bid_nr_digits
131
#define onehalf128 __bid_onehalf128
132
#define onehalf128M __bid_onehalf128M
133
#define onehalf192M __bid_onehalf192M
134
#define onehalf256M __bid_onehalf256M
135
#define shiftright128 __bid_shiftright128
136
#define shiftright128M __bid_shiftright128M
137
#define shiftright192M __bid_shiftright192M
138
#define shiftright256M __bid_shiftright256M
139
#define shift_ten2m3k128 __bid_shift_ten2m3k128
140
#define shift_ten2m3k64 __bid_shift_ten2m3k64
141
#define ten2k128 __bid_ten2k128
142
#define ten2k256 __bid_ten2k256
143
#define ten2k64 __bid_ten2k64
144
#define ten2m3k128 __bid_ten2m3k128
145
#define ten2m3k64 __bid_ten2m3k64
146
#define ten2mk128 __bid_ten2mk128
147
#define ten2mk128M __bid_ten2mk128M
148
#define ten2mk128trunc __bid_ten2mk128trunc
149
#define ten2mk128truncM __bid_ten2mk128truncM
150
#define ten2mk192M __bid_ten2mk192M
151
#define ten2mk192truncM __bid_ten2mk192truncM
152
#define ten2mk256M __bid_ten2mk256M
153
#define ten2mk256truncM __bid_ten2mk256truncM
154
#define ten2mk64 __bid_ten2mk64
155
#define ten2mxtrunc128 __bid_ten2mxtrunc128
156
#define ten2mxtrunc192 __bid_ten2mxtrunc192
157
#define ten2mxtrunc256 __bid_ten2mxtrunc256
158
#define ten2mxtrunc64 __bid_ten2mxtrunc64
159
#define bid128_add __bid128_add
160
#define bid128dd_add __bid128dd_add
161
#define bid128dd_sub __bid128dd_sub
162
#define bid128dq_add __bid128dq_add
163
#define bid128dq_sub __bid128dq_sub
164
#define bid128qd_add __bid128qd_add
165
#define bid128qd_sub __bid128qd_sub
166
#define bid128_sub __bid128_sub
167
#define bid64dq_add __bid64dq_add
168
#define bid64dq_sub __bid64dq_sub
169
#define bid64qd_add __bid64qd_add
170
#define bid64qd_sub __bid64qd_sub
171
#define bid64qq_add __bid64qq_add
172
#define bid64qq_sub __bid64qq_sub
173
#define bid128dd_mul __bid128dd_mul
174
#define bid128dq_mul __bid128dq_mul
175
#define bid128_mul __bid128_mul
176
#define bid128qd_mul __bid128qd_mul
177
#define bid64dq_mul __bid64dq_mul
178
#define bid64qd_mul __bid64qd_mul
179
#define bid64qq_mul __bid64qq_mul
180
#define bid128dd_div __bid128dd_div
181
#define bid128_div __bid128_div
182
#define bid128dq_div __bid128dq_div
183
#define bid128qd_div __bid128qd_div
184
#define bid128d_sqrt __bid128d_sqrt
185
#define bid128_sqrt __bid128_sqrt
186
#define bid128ddd_fma __bid128ddd_fma
187
#define bid128ddq_fma __bid128ddq_fma
188
#define bid128dqd_fma __bid128dqd_fma
189
#define bid128dqq_fma __bid128dqq_fma
190
#define bid128_fma __bid128_fma
191
#define bid128qdd_fma __bid128qdd_fma
192
#define bid128qdq_fma __bid128qdq_fma
193
#define bid128qqd_fma __bid128qqd_fma
194
#define bid64ddq_fma __bid64ddq_fma
195
#define bid64dqd_fma __bid64dqd_fma
196
#define bid64dqq_fma __bid64dqq_fma
197
#define bid64qdd_fma __bid64qdd_fma
198
#define bid64qdq_fma __bid64qdq_fma
199
#define bid64qqd_fma __bid64qqd_fma
200
#define bid64qqq_fma __bid64qqq_fma
201
#define bid128_round_integral_exact __bid128_round_integral_exact
202
#define bid128_round_integral_nearest_away __bid128_round_integral_nearest_away
203
#define bid128_round_integral_nearest_even __bid128_round_integral_nearest_even
204
#define bid128_round_integral_negative __bid128_round_integral_negative
205
#define bid128_round_integral_positive __bid128_round_integral_positive
206
#define bid128_round_integral_zero __bid128_round_integral_zero
207
#define bid64_round_integral_exact __bid64_round_integral_exact
208
#define bid64_round_integral_nearest_away __bid64_round_integral_nearest_away
209
#define bid64_round_integral_nearest_even __bid64_round_integral_nearest_even
210
#define bid64_round_integral_negative __bid64_round_integral_negative
211
#define bid64_round_integral_positive __bid64_round_integral_positive
212
#define bid64_round_integral_zero __bid64_round_integral_zero
213
#define bid128_quantize __bid128_quantize
214
#define bid128_scalb __bid128_scalb
215
#define bid64_maxnum __bid64_maxnum
216
#define bid64_maxnum_mag __bid64_maxnum_mag
217
#define bid64_minnum __bid64_minnum
218
#define bid64_minnum_mag __bid64_minnum_mag
219
#define bid128_maxnum __bid128_maxnum
220
#define bid128_maxnum_mag __bid128_maxnum_mag
221
#define bid128_minnum __bid128_minnum
222
#define bid128_minnum_mag __bid128_minnum_mag
223
#define bid128_rem __bid128_rem
224
#define bid128_logb __bid128_logb
225
#define getDecimalRoundingDirection __bid_getDecimalRoundingDirection
226
#define is754 __bid_is754
227
#define is754R __bid_is754R
228
#define signalException __bid_signalException
229
#define lowerFlags __bid_lowerFlags
230
#define restoreFlags __bid_restoreFlags
231
#define saveFlags __bid_saveFlags
232
#define setDecimalRoundingDirection __bid_setDecimalRoundingDirection
233
#define testFlags __bid_testFlags
234
#define testSavedFlags __bid_testSavedFlags
235
#define bid32_to_bid64 __bid32_to_bid64
236
#define bid64_to_bid32 __bid64_to_bid32
237
#define bid128_to_string __bid128_to_string
238
#define mod10_18_tbl __bid_mod10_18_tbl
239
#define bid128_to_bid32 __bid128_to_bid32
240
#define bid32_to_bid128 __bid32_to_bid128
241
#define bid128_to_bid64 __bid128_to_bid64
242
#define bid64_to_bid128 __bid64_to_bid128
243
#define bid128_from_string __bid128_from_string
244
#define bid128_from_int32 __bid128_from_int32
245
#define bid128_from_int64 __bid128_from_int64
246
#define bid128_from_uint32 __bid128_from_uint32
247
#define bid128_from_uint64 __bid128_from_uint64
248
#define bid64_from_int32 __bid64_from_int32
249
#define bid64_from_int64 __bid64_from_int64
250
#define bid64_from_uint32 __bid64_from_uint32
251
#define bid64_from_uint64 __bid64_from_uint64
252
#define bid64_abs __bid64_abs
253
#define bid64_class __bid64_class
254
#define bid64_copy __bid64_copy
255
#define bid64_copySign __bid64_copySign
256
#define bid64_isCanonical __bid64_isCanonical
257
#define bid64_isFinite __bid64_isFinite
258
#define bid64_isInf __bid64_isInf
259
#define bid64_isNaN __bid64_isNaN
260
#define bid64_isNormal __bid64_isNormal
261
#define bid64_isSignaling __bid64_isSignaling
262
#define bid64_isSigned __bid64_isSigned
263
#define bid64_isSubnormal __bid64_isSubnormal
264
#define bid64_isZero __bid64_isZero
265
#define bid64_negate __bid64_negate
266
#define bid64_radix __bid64_radix
267
#define bid64_sameQuantum __bid64_sameQuantum
268
#define bid64_totalOrder __bid64_totalOrder
269
#define bid64_totalOrderMag __bid64_totalOrderMag
270
#define bid128_abs __bid128_abs
271
#define bid128_class __bid128_class
272
#define bid128_copy __bid128_copy
273
#define bid128_copySign __bid128_copySign
274
#define bid128_isCanonical __bid128_isCanonical
275
#define bid128_isFinite __bid128_isFinite
276
#define bid128_isInf __bid128_isInf
277
#define bid128_isNaN __bid128_isNaN
278
#define bid128_isNormal __bid128_isNormal
279
#define bid128_isSignaling __bid128_isSignaling
280
#define bid128_isSigned __bid128_isSigned
281
#define bid128_isSubnormal __bid128_isSubnormal
282
#define bid128_isZero __bid128_isZero
283
#define bid128_negate __bid128_negate
284
#define bid128_radix __bid128_radix
285
#define bid128_sameQuantum __bid128_sameQuantum
286
#define bid128_totalOrder __bid128_totalOrder
287
#define bid128_totalOrderMag __bid128_totalOrderMag
288
#define bid64_quiet_equal __bid64_quiet_equal
289
#define bid64_quiet_greater __bid64_quiet_greater
290
#define bid64_quiet_greater_equal __bid64_quiet_greater_equal
291
#define bid64_quiet_greater_unordered __bid64_quiet_greater_unordered
292
#define bid64_quiet_less __bid64_quiet_less
293
#define bid64_quiet_less_equal __bid64_quiet_less_equal
294
#define bid64_quiet_less_unordered __bid64_quiet_less_unordered
295
#define bid64_quiet_not_equal __bid64_quiet_not_equal
296
#define bid64_quiet_not_greater __bid64_quiet_not_greater
297
#define bid64_quiet_not_less __bid64_quiet_not_less
298
#define bid64_quiet_ordered __bid64_quiet_ordered
299
#define bid64_quiet_unordered __bid64_quiet_unordered
300
#define bid64_signaling_greater __bid64_signaling_greater
301
#define bid64_signaling_greater_equal __bid64_signaling_greater_equal
302
#define bid64_signaling_greater_unordered __bid64_signaling_greater_unordered
303
#define bid64_signaling_less __bid64_signaling_less
304
#define bid64_signaling_less_equal __bid64_signaling_less_equal
305
#define bid64_signaling_less_unordered __bid64_signaling_less_unordered
306
#define bid64_signaling_not_greater __bid64_signaling_not_greater
307
#define bid64_signaling_not_less __bid64_signaling_not_less
308
#define bid128_quiet_equal __bid128_quiet_equal
309
#define bid128_quiet_greater __bid128_quiet_greater
310
#define bid128_quiet_greater_equal __bid128_quiet_greater_equal
311
#define bid128_quiet_greater_unordered __bid128_quiet_greater_unordered
312
#define bid128_quiet_less __bid128_quiet_less
313
#define bid128_quiet_less_equal __bid128_quiet_less_equal
314
#define bid128_quiet_less_unordered __bid128_quiet_less_unordered
315
#define bid128_quiet_not_equal __bid128_quiet_not_equal
316
#define bid128_quiet_not_greater __bid128_quiet_not_greater
317
#define bid128_quiet_not_less __bid128_quiet_not_less
318
#define bid128_quiet_ordered __bid128_quiet_ordered
319
#define bid128_quiet_unordered __bid128_quiet_unordered
320
#define bid128_signaling_greater __bid128_signaling_greater
321
#define bid128_signaling_greater_equal __bid128_signaling_greater_equal
322
#define bid128_signaling_greater_unordered __bid128_signaling_greater_unordered
323
#define bid128_signaling_less __bid128_signaling_less
324
#define bid128_signaling_less_equal __bid128_signaling_less_equal
325
#define bid128_signaling_less_unordered __bid128_signaling_less_unordered
326
#define bid128_signaling_not_greater __bid128_signaling_not_greater
327
#define bid128_signaling_not_less __bid128_signaling_not_less
328
#define bid64_to_int32_ceil __bid64_to_int32_ceil
329
#define bid64_to_int32_floor __bid64_to_int32_floor
330
#define bid64_to_int32_int __bid64_to_int32_int
331
#define bid64_to_int32_rnint __bid64_to_int32_rnint
332
#define bid64_to_int32_rninta __bid64_to_int32_rninta
333
#define bid64_to_int32_xceil __bid64_to_int32_xceil
334
#define bid64_to_int32_xfloor __bid64_to_int32_xfloor
335
#define bid64_to_int32_xint __bid64_to_int32_xint
336
#define bid64_to_int32_xrnint __bid64_to_int32_xrnint
337
#define bid64_to_int32_xrninta __bid64_to_int32_xrninta
338
#define bid64_to_uint32_ceil __bid64_to_uint32_ceil
339
#define bid64_to_uint32_floor __bid64_to_uint32_floor
340
#define bid64_to_uint32_int __bid64_to_uint32_int
341
#define bid64_to_uint32_rnint __bid64_to_uint32_rnint
342
#define bid64_to_uint32_rninta __bid64_to_uint32_rninta
343
#define bid64_to_uint32_xceil __bid64_to_uint32_xceil
344
#define bid64_to_uint32_xfloor __bid64_to_uint32_xfloor
345
#define bid64_to_uint32_xint __bid64_to_uint32_xint
346
#define bid64_to_uint32_xrnint __bid64_to_uint32_xrnint
347
#define bid64_to_uint32_xrninta __bid64_to_uint32_xrninta
348
#define bid64_to_int64_ceil __bid64_to_int64_ceil
349
#define bid64_to_int64_floor __bid64_to_int64_floor
350
#define bid64_to_int64_int __bid64_to_int64_int
351
#define bid64_to_int64_rnint __bid64_to_int64_rnint
352
#define bid64_to_int64_rninta __bid64_to_int64_rninta
353
#define bid64_to_int64_xceil __bid64_to_int64_xceil
354
#define bid64_to_int64_xfloor __bid64_to_int64_xfloor
355
#define bid64_to_int64_xint __bid64_to_int64_xint
356
#define bid64_to_int64_xrnint __bid64_to_int64_xrnint
357
#define bid64_to_int64_xrninta __bid64_to_int64_xrninta
358
#define bid64_to_uint64_ceil __bid64_to_uint64_ceil
359
#define bid64_to_uint64_floor __bid64_to_uint64_floor
360
#define bid64_to_uint64_int __bid64_to_uint64_int
361
#define bid64_to_uint64_rnint __bid64_to_uint64_rnint
362
#define bid64_to_uint64_rninta __bid64_to_uint64_rninta
363
#define bid64_to_uint64_xceil __bid64_to_uint64_xceil
364
#define bid64_to_uint64_xfloor __bid64_to_uint64_xfloor
365
#define bid64_to_uint64_xint __bid64_to_uint64_xint
366
#define bid64_to_uint64_xrnint __bid64_to_uint64_xrnint
367
#define bid64_to_uint64_xrninta __bid64_to_uint64_xrninta
368
#define bid128_to_int32_ceil __bid128_to_int32_ceil
369
#define bid128_to_int32_floor __bid128_to_int32_floor
370
#define bid128_to_int32_int __bid128_to_int32_int
371
#define bid128_to_int32_rnint __bid128_to_int32_rnint
372
#define bid128_to_int32_rninta __bid128_to_int32_rninta
373
#define bid128_to_int32_xceil __bid128_to_int32_xceil
374
#define bid128_to_int32_xfloor __bid128_to_int32_xfloor
375
#define bid128_to_int32_xint __bid128_to_int32_xint
376
#define bid128_to_int32_xrnint __bid128_to_int32_xrnint
377
#define bid128_to_int32_xrninta __bid128_to_int32_xrninta
378
#define bid128_to_uint32_ceil __bid128_to_uint32_ceil
379
#define bid128_to_uint32_floor __bid128_to_uint32_floor
380
#define bid128_to_uint32_int __bid128_to_uint32_int
381
#define bid128_to_uint32_rnint __bid128_to_uint32_rnint
382
#define bid128_to_uint32_rninta __bid128_to_uint32_rninta
383
#define bid128_to_uint32_xceil __bid128_to_uint32_xceil
384
#define bid128_to_uint32_xfloor __bid128_to_uint32_xfloor
385
#define bid128_to_uint32_xint __bid128_to_uint32_xint
386
#define bid128_to_uint32_xrnint __bid128_to_uint32_xrnint
387
#define bid128_to_uint32_xrninta __bid128_to_uint32_xrninta
388
#define bid128_to_int64_ceil __bid128_to_int64_ceil
389
#define bid128_to_int64_floor __bid128_to_int64_floor
390
#define bid128_to_int64_int __bid128_to_int64_int
391
#define bid128_to_int64_rnint __bid128_to_int64_rnint
392
#define bid128_to_int64_rninta __bid128_to_int64_rninta
393
#define bid128_to_int64_xceil __bid128_to_int64_xceil
394
#define bid128_to_int64_xfloor __bid128_to_int64_xfloor
395
#define bid128_to_int64_xint __bid128_to_int64_xint
396
#define bid128_to_int64_xrnint __bid128_to_int64_xrnint
397
#define bid128_to_int64_xrninta __bid128_to_int64_xrninta
398
#define bid128_to_uint64_ceil __bid128_to_uint64_ceil
399
#define bid128_to_uint64_floor __bid128_to_uint64_floor
400
#define bid128_to_uint64_int __bid128_to_uint64_int
401
#define bid128_to_uint64_rnint __bid128_to_uint64_rnint
402
#define bid128_to_uint64_rninta __bid128_to_uint64_rninta
403
#define bid128_to_uint64_xceil __bid128_to_uint64_xceil
404
#define bid128_to_uint64_xfloor __bid128_to_uint64_xfloor
405
#define bid128_to_uint64_xint __bid128_to_uint64_xint
406
#define bid128_to_uint64_xrnint __bid128_to_uint64_xrnint
407
#define bid128_to_uint64_xrninta __bid128_to_uint64_xrninta
408
#define bid128_to_binary128 __bid128_to_binary128
409
#define bid128_to_binary32 __bid128_to_binary32
410
#define bid128_to_binary64 __bid128_to_binary64
411
#define bid128_to_binary80 __bid128_to_binary80
412
#define bid32_to_binary128 __bid32_to_binary128
413
#define bid32_to_binary32 __bid32_to_binary32
414
#define bid32_to_binary64 __bid32_to_binary64
415
#define bid32_to_binary80 __bid32_to_binary80
416
#define bid64_to_binary128 __bid64_to_binary128
417
#define bid64_to_binary32 __bid64_to_binary32
418
#define bid64_to_binary64 __bid64_to_binary64
419
#define bid64_to_binary80 __bid64_to_binary80
420
#define binary128_to_bid128 __binary128_to_bid128
421
#define binary128_to_bid32 __binary128_to_bid32
422
#define binary128_to_bid64 __binary128_to_bid64
423
#define binary32_to_bid128 __binary32_to_bid128
424
#define binary32_to_bid32 __binary32_to_bid32
425
#define binary32_to_bid64 __binary32_to_bid64
426
#define binary64_to_bid128 __binary64_to_bid128
427
#define binary64_to_bid32 __binary64_to_bid32
428
#define binary64_to_bid64 __binary64_to_bid64
429
#define binary80_to_bid128 __binary80_to_bid128
430
#define binary80_to_bid32 __binary80_to_bid32
431
#define binary80_to_bid64 __binary80_to_bid64
432
#define bid64_to_uint16_ceil __bid64_to_uint16_ceil
433
#define bid64_to_uint16_floor __bid64_to_uint16_floor
434
#define bid64_to_uint16_int __bid64_to_uint16_int
435
#define bid64_to_uint16_rnint __bid64_to_uint16_rnint
436
#define bid64_to_uint16_rninta __bid64_to_uint16_rninta
437
#define bid64_to_uint16_xceil __bid64_to_uint16_xceil
438
#define bid64_to_uint16_xfloor __bid64_to_uint16_xfloor
439
#define bid64_to_uint16_xint __bid64_to_uint16_xint
440
#define bid64_to_uint16_xrnint __bid64_to_uint16_xrnint
441
#define bid64_to_uint16_xrninta __bid64_to_uint16_xrninta
442
#define bid64_to_int16_ceil __bid64_to_int16_ceil
443
#define bid64_to_int16_floor __bid64_to_int16_floor
444
#define bid64_to_int16_int __bid64_to_int16_int
445
#define bid64_to_int16_rnint __bid64_to_int16_rnint
446
#define bid64_to_int16_rninta __bid64_to_int16_rninta
447
#define bid64_to_int16_xceil __bid64_to_int16_xceil
448
#define bid64_to_int16_xfloor __bid64_to_int16_xfloor
449
#define bid64_to_int16_xint __bid64_to_int16_xint
450
#define bid64_to_int16_xrnint __bid64_to_int16_xrnint
451
#define bid64_to_int16_xrninta __bid64_to_int16_xrninta
452
#define bid128_to_uint16_ceil __bid128_to_uint16_ceil
453
#define bid128_to_uint16_floor __bid128_to_uint16_floor
454
#define bid128_to_uint16_int __bid128_to_uint16_int
455
#define bid128_to_uint16_rnint __bid128_to_uint16_rnint
456
#define bid128_to_uint16_rninta __bid128_to_uint16_rninta
457
#define bid128_to_uint16_xceil __bid128_to_uint16_xceil
458
#define bid128_to_uint16_xfloor __bid128_to_uint16_xfloor
459
#define bid128_to_uint16_xint __bid128_to_uint16_xint
460
#define bid128_to_uint16_xrnint __bid128_to_uint16_xrnint
461
#define bid128_to_uint16_xrninta __bid128_to_uint16_xrninta
462
#define bid128_to_int16_ceil __bid128_to_int16_ceil
463
#define bid128_to_int16_floor __bid128_to_int16_floor
464
#define bid128_to_int16_int __bid128_to_int16_int
465
#define bid128_to_int16_rnint __bid128_to_int16_rnint
466
#define bid128_to_int16_rninta __bid128_to_int16_rninta
467
#define bid128_to_int16_xceil __bid128_to_int16_xceil
468
#define bid128_to_int16_xfloor __bid128_to_int16_xfloor
469
#define bid128_to_int16_xint __bid128_to_int16_xint
470
#define bid128_to_int16_xrnint __bid128_to_int16_xrnint
471
#define bid128_to_int16_xrninta __bid128_to_int16_xrninta
472
#define bid64_to_uint8_ceil __bid64_to_uint8_ceil
473
#define bid64_to_uint8_floor __bid64_to_uint8_floor
474
#define bid64_to_uint8_int __bid64_to_uint8_int
475
#define bid64_to_uint8_rnint __bid64_to_uint8_rnint
476
#define bid64_to_uint8_rninta __bid64_to_uint8_rninta
477
#define bid64_to_uint8_xceil __bid64_to_uint8_xceil
478
#define bid64_to_uint8_xfloor __bid64_to_uint8_xfloor
479
#define bid64_to_uint8_xint __bid64_to_uint8_xint
480
#define bid64_to_uint8_xrnint __bid64_to_uint8_xrnint
481
#define bid64_to_uint8_xrninta __bid64_to_uint8_xrninta
482
#define bid64_to_int8_ceil __bid64_to_int8_ceil
483
#define bid64_to_int8_floor __bid64_to_int8_floor
484
#define bid64_to_int8_int __bid64_to_int8_int
485
#define bid64_to_int8_rnint __bid64_to_int8_rnint
486
#define bid64_to_int8_rninta __bid64_to_int8_rninta
487
#define bid64_to_int8_xceil __bid64_to_int8_xceil
488
#define bid64_to_int8_xfloor __bid64_to_int8_xfloor
489
#define bid64_to_int8_xint __bid64_to_int8_xint
490
#define bid64_to_int8_xrnint __bid64_to_int8_xrnint
491
#define bid64_to_int8_xrninta __bid64_to_int8_xrninta
492
#define bid128_to_uint8_ceil __bid128_to_uint8_ceil
493
#define bid128_to_uint8_floor __bid128_to_uint8_floor
494
#define bid128_to_uint8_int __bid128_to_uint8_int
495
#define bid128_to_uint8_rnint __bid128_to_uint8_rnint
496
#define bid128_to_uint8_rninta __bid128_to_uint8_rninta
497
#define bid128_to_uint8_xceil __bid128_to_uint8_xceil
498
#define bid128_to_uint8_xfloor __bid128_to_uint8_xfloor
499
#define bid128_to_uint8_xint __bid128_to_uint8_xint
500
#define bid128_to_uint8_xrnint __bid128_to_uint8_xrnint
501
#define bid128_to_uint8_xrninta __bid128_to_uint8_xrninta
502
#define bid128_to_int8_ceil __bid128_to_int8_ceil
503
#define bid128_to_int8_floor __bid128_to_int8_floor
504
#define bid128_to_int8_int __bid128_to_int8_int
505
#define bid128_to_int8_rnint __bid128_to_int8_rnint
506
#define bid128_to_int8_rninta __bid128_to_int8_rninta
507
#define bid128_to_int8_xceil __bid128_to_int8_xceil
508
#define bid128_to_int8_xfloor __bid128_to_int8_xfloor
509
#define bid128_to_int8_xint __bid128_to_int8_xint
510
#define bid128_to_int8_xrnint __bid128_to_int8_xrnint
511
#define bid128_to_int8_xrninta __bid128_to_int8_xrninta
512
 
513
#ifdef IN_LIBGCC2
514
#if !defined ENABLE_DECIMAL_BID_FORMAT || !ENABLE_DECIMAL_BID_FORMAT
515
#error BID not enabled in libbid
516
#endif
517
 
518
#ifndef BID_BIG_ENDIAN
519
#define BID_BIG_ENDIAN LIBGCC2_FLOAT_WORDS_BIG_ENDIAN
520
#endif
521
 
522
#ifndef BID_THREAD
523
#if defined (HAVE_CC_TLS) && defined (USE_TLS)
524
#define BID_THREAD __thread
525
#endif
526
#endif
527
 
528
#define _intptr_t_defined
529
#define DECIMAL_CALL_BY_REFERENCE 0
530
#define DECIMAL_GLOBAL_ROUNDING 1
531
#define DECIMAL_GLOBAL_ROUNDING_ACCESS_FUNCTIONS 1
532
#define DECIMAL_GLOBAL_EXCEPTION_FLAGS 1
533
#define DECIMAL_GLOBAL_EXCEPTION_FLAGS_ACCESS_FUNCTIONS 1
534
#define BID_HAS_GCC_DECIMAL_INTRINSICS 1
535
#endif /* IN_LIBGCC2 */
536
 
537
// Configuration Options
538
 
539
#define SET_STATUS_FLAGS
540
 
541
#ifndef BID_THREAD
542
#define BID_THREAD
543
#endif
544
 
545
#ifndef BID_HAS_GCC_DECIMAL_INTRINSICS
546
#define BID_HAS_GCC_DECIMAL_INTRINSICS 0
547
#endif
548
 
549
#if !defined(WINDOWS) || defined(__INTEL_COMPILER)
550
// #define UNCHANGED_BINARY_STATUS_FLAGS
551
#endif
552
// #define HPUX_OS
553
 
554
// If DECIMAL_CALL_BY_REFERENCE is defined then numerical arguments and results
555
// are passed by reference otherwise they are passed by value (except that
556
// a pointer is always passed to the status flags)
557
 
558
#ifndef DECIMAL_CALL_BY_REFERENCE
559
#define DECIMAL_CALL_BY_REFERENCE 0
560
#endif
561
 
562
// If DECIMAL_GLOBAL_ROUNDING is defined then the rounding mode is a global 
563
// variable _IDEC_glbround, otherwise it is passed as a parameter when needed
564
 
565
#ifndef DECIMAL_GLOBAL_ROUNDING
566
#define DECIMAL_GLOBAL_ROUNDING 0
567
#endif
568
 
569
#ifndef DECIMAL_GLOBAL_ROUNDING_ACCESS_FUNCTIONS
570
#define DECIMAL_GLOBAL_ROUNDING_ACCESS_FUNCTIONS 0
571
#endif
572
 
573
// If DECIMAL_GLOBAL_EXCEPTION_FLAGS is defined then the exception status flags
574
// are represented by a global variable _IDEC_glbflags, otherwise they are 
575
// passed as a parameter when needed
576
 
577
#ifndef DECIMAL_GLOBAL_EXCEPTION_FLAGS
578
#define DECIMAL_GLOBAL_EXCEPTION_FLAGS 0
579
#endif
580
 
581
#ifndef DECIMAL_GLOBAL_EXCEPTION_FLAGS_ACCESS_FUNCTIONS
582
#define DECIMAL_GLOBAL_EXCEPTION_FLAGS_ACCESS_FUNCTIONS 0
583
#endif
584
 
585
// If DECIMAL_ALTERNATE_EXCEPTION_HANDLING is defined then the exception masks
586
// are examined and exception handling information is provided to the caller 
587
// if alternate exception handling is necessary
588
 
589
#ifndef DECIMAL_ALTERNATE_EXCEPTION_HANDLING
590
#define DECIMAL_ALTERNATE_EXCEPTION_HANDLING 0
591
#endif
592
 
593
typedef unsigned int _IDEC_round;
594
typedef unsigned int _IDEC_flags;       // could be a struct with diagnostic info
595
 
596
#if DECIMAL_ALTERNATE_EXCEPTION_HANDLING
597
  // If DECIMAL_GLOBAL_EXCEPTION_MASKS is defined then the exception mask bits
598
  // are represented by a global variable _IDEC_exceptionmasks, otherwise they
599
  // are passed as a parameter when needed; DECIMAL_GLOBAL_EXCEPTION_MASKS is 
600
  // ignored
601
  // if DECIMAL_ALTERNATE_EXCEPTION_HANDLING is not defined
602
  // **************************************************************************
603
#define DECIMAL_GLOBAL_EXCEPTION_MASKS 0
604
  // **************************************************************************
605
 
606
  // If DECIMAL_GLOBAL_EXCEPTION_INFO is defined then the alternate exception  
607
  // handling information is represented by a global data structure 
608
  // _IDEC_glbexcepthandling, otherwise it is passed by reference as a
609
  // parameter when needed; DECIMAL_GLOBAL_EXCEPTION_INFO is ignored
610
  // if DECIMAL_ALTERNATE_EXCEPTION_HANDLING is not defined
611
  // **************************************************************************
612
#define DECIMAL_GLOBAL_EXCEPTION_INFO 0
613
  // **************************************************************************
614
#endif
615
 
616
// Notes: 1) rnd_mode from _RND_MODE_ARG is used by the caller of a function
617
//           from this library, and can be any name
618
//        2) rnd_mode and prnd_mode from _RND_MODE_PARAM are fixed names 
619
//           and *must* be used in the library functions
620
//        3) _IDEC_glbround is the fixed name for the global variable holding 
621
//           the rounding mode
622
 
623
#if !DECIMAL_GLOBAL_ROUNDING
624
#if DECIMAL_CALL_BY_REFERENCE
625
#define _RND_MODE_ARG , &rnd_mode
626
#define _RND_MODE_PARAM , _IDEC_round *prnd_mode
627
#define _RND_MODE_ARG_ALONE &rnd_mode
628
#define _RND_MODE_PARAM_ALONE _IDEC_round *prnd_mode
629
#else
630
#define _RND_MODE_ARG , rnd_mode
631
#define _RND_MODE_PARAM , _IDEC_round rnd_mode
632
#define _RND_MODE_ARG_ALONE rnd_mode
633
#define _RND_MODE_PARAM_ALONE _IDEC_round rnd_mode
634
#endif
635
#else
636
#define _RND_MODE_ARG
637
#define _RND_MODE_PARAM
638
#define _RND_MODE_ARG_ALONE
639
#define _RND_MODE_PARAM_ALONE
640
#define rnd_mode _IDEC_glbround
641
#endif
642
 
643
// Notes: 1) pfpsf from _EXC_FLAGS_ARG is used by the caller of a function
644
//           from this library, and can be any name 
645
//        2) pfpsf from _EXC_FLAGS_PARAM is a fixed name and *must* be used  
646
//           in the library functions
647
//        3) _IDEC_glbflags is the fixed name for the global variable holding 
648
//           the floating-point status flags
649
#if !DECIMAL_GLOBAL_EXCEPTION_FLAGS
650
#define _EXC_FLAGS_ARG , pfpsf
651
#define _EXC_FLAGS_PARAM , _IDEC_flags *pfpsf
652
#else
653
#define _EXC_FLAGS_ARG
654
#define _EXC_FLAGS_PARAM
655
#define pfpsf &_IDEC_glbflags
656
#endif
657
 
658
#if DECIMAL_GLOBAL_ROUNDING
659
extern BID_THREAD _IDEC_round _IDEC_glbround;
660
#endif
661
 
662
#if DECIMAL_GLOBAL_EXCEPTION_FLAGS
663
extern BID_THREAD _IDEC_flags _IDEC_glbflags;
664
#endif
665
 
666
#if DECIMAL_ALTERNATE_EXCEPTION_HANDLING
667
#if DECIMAL_GLOBAL_EXCEPTION_MASKS
668
extern BID_THREAD _IDEC_exceptionmasks _IDEC_glbexceptionmasks;
669
#endif
670
#if DECIMAL_GLOBAL_EXCEPTION_INFO
671
extern BID_THREAD _IDEC_excepthandling _IDEC_glbexcepthandling;
672
#endif
673
#endif
674
 
675
#if DECIMAL_ALTERNATE_EXCEPTION_HANDLING
676
 
677
  // Notes: 1) exc_mask from _EXC_MASKS_ARG is used by the caller of a function
678
  //           from this library, and can be any name
679
  //        2) exc_mask and pexc_mask from _EXC_MASKS_PARAM are fixed names
680
  //           and *must* be used in the library functions
681
  //        3) _IDEC_glbexceptionmasks is the fixed name for the global 
682
  //           variable holding the floating-point exception masks
683
#if !DECIMAL_GLOBAL_EXCEPTION_MASKS
684
#if DECIMAL_CALL_BY_REFERENCE
685
#define _EXC_MASKS_ARG , &exc_mask
686
#define _EXC_MASKS_PARAM , _IDEC_exceptionmasks *pexc_mask
687
#else
688
#define _EXC_MASKS_ARG , exc_mask
689
#define _EXC_MASKS_PARAM , _IDEC_exceptionmasks exc_mask
690
#endif
691
#else
692
#define _EXC_MASKS_ARG
693
#define _EXC_MASKS_PARAM
694
#define exc_mask _IDEC_glbexceptionmasks
695
#endif
696
 
697
  // Notes: 1) pexc_info from _EXC_INFO_ARG is used by the caller of a function
698
  //           from this library, and can be any name
699
  //        2) pexc_info from _EXC_INFO_PARAM is a fixed name and *must* be  
700
  //           used in the library functions
701
  //        3) _IDEC_glbexcepthandling is the fixed name for the global  
702
  //           variable holding the floating-point exception information
703
#if !DECIMAL_GLOBAL_EXCEPTION_INFO
704
#define _EXC_INFO_ARG , pexc_info
705
#define _EXC_INFO_PARAM , _IDEC_excepthandling *pexc_info
706
#else
707
#define _EXC_INFO_ARG
708
#define _EXC_INFO_PARAM
709
#define pexc_info &_IDEC_glbexcepthandling
710
#endif
711
#else
712
#define _EXC_MASKS_ARG
713
#define _EXC_MASKS_PARAM
714
#define _EXC_INFO_ARG
715
#define _EXC_INFO_PARAM
716
#endif
717
 
718
 
719
#ifndef BID_BIG_ENDIAN
720
#define BID_BIG_ENDIAN 0
721
#endif
722
 
723
#if BID_BIG_ENDIAN
724
#define BID_SWAP128(x) {  \
725
  UINT64 sw;              \
726
  sw = (x).w[1];          \
727
  (x).w[1] = (x).w[0];    \
728
  (x).w[0] = sw;          \
729
  }
730
#else
731
#define BID_SWAP128(x)
732
#endif
733
 
734
#if DECIMAL_CALL_BY_REFERENCE
735
#define BID_RETURN_VAL(x) { *pres = (x); return; }
736
#if BID_BIG_ENDIAN && defined BID_128RES
737
#define BID_RETURN(x) { BID_SWAP128(x); *pres = (x); return; }
738
#else
739
#define BID_RETURN(x) { *pres = (x); return; }
740
#endif
741
#else
742
#define BID_RETURN_VAL(x) return(x);
743
#if BID_BIG_ENDIAN && defined BID_128RES
744
#define BID_RETURN(x) { BID_SWAP128(x); return(x); }
745
#else
746
#define BID_RETURN(x) return(x);
747
#endif
748
#endif
749
 
750
#if DECIMAL_CALL_BY_REFERENCE
751
#define BIDECIMAL_CALL1(_FUNC, _RES, _OP1) \
752
    _FUNC(&(_RES), &(_OP1) _RND_MODE_ARG _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
753
#define BIDECIMAL_CALL1_NORND(_FUNC, _RES, _OP1) \
754
    _FUNC(&(_RES), &(_OP1) _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
755
#define BIDECIMAL_CALL2(_FUNC, _RES, _OP1, _OP2) \
756
    _FUNC(&(_RES), &(_OP1), &(_OP2) _RND_MODE_ARG _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
757
#define BIDECIMAL_CALL2_NORND(_FUNC, _RES, _OP1, _OP2) \
758
    _FUNC(&(_RES), &(_OP1), &(_OP2) _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
759
#define BIDECIMAL_CALL1_NORND_RESREF(_FUNC, _RES, _OP1) \
760
    _FUNC((_RES), &(_OP1) _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
761
#define BIDECIMAL_CALL1_RESARG(_FUNC, _RES, _OP1) \
762
    _FUNC(&(_RES), (_OP1) _RND_MODE_ARG _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
763
#define BIDECIMAL_CALL1_RESREF(_FUNC, _RES, _OP1) \
764
    _FUNC((_RES), &(_OP1) _RND_MODE_ARG _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
765
#define BIDECIMAL_CALL1_NORND_NOSTAT(_FUNC, _RES, _OP1) \
766
    _FUNC(&(_RES), &(_OP1) _EXC_MASKS_ARG _EXC_INFO_ARG)
767
#define BIDECIMAL_CALL2_NORND_NOSTAT(_FUNC, _RES, _OP1, _OP2) \
768
    _FUNC(&(_RES), &(_OP1), &(_OP2) _EXC_MASKS_ARG _EXC_INFO_ARG)
769
#define BIDECIMAL_CALL3(_FUNC, _RES, _OP1, _OP2, _OP3) \
770
    _FUNC(&(_RES), &(_OP1), &(_OP2), &(_OP3) _RND_MODE_ARG _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
771
#define BIDECIMAL_CALL1_NORND_NOMASK_NOINFO(_FUNC, _RES, _OP1) \
772
    _FUNC(&(_RES), &(_OP1) _EXC_FLAGS_ARG )
773
#define BIDECIMAL_CALL1_NORND_NOFLAGS_NOMASK_NOINFO(_FUNC, _RES, _OP1) \
774
    _FUNC(&(_RES), &(_OP1) )
775
#define BIDECIMAL_CALL2_NORND_NOFLAGS_NOMASK_NOINFO(_FUNC, _RES, _OP1, _OP2) \
776
    _FUNC(&(_RES), &(_OP1), &(_OP2) )
777
#define BIDECIMAL_CALL1_NORND_NOMASK_NOINFO_RESVOID(_FUNC, _OP1) \
778
    _FUNC(&(_OP1) _EXC_FLAGS_ARG )
779
#define BIDECIMAL_CALL2_NORND_NOMASK_NOINFO_RESVOID(_FUNC, _OP1, _OP2) \
780
    _FUNC(&(_OP1), &(_OP2) _EXC_FLAGS_ARG )
781
#define BIDECIMAL_CALLV_NOFLAGS_NOMASK_NOINFO(_FUNC, _RES) \
782
    _FUNC(&(_RES) _RND_MODE_ARG)
783
#define BIDECIMAL_CALL1_NOFLAGS_NOMASK_NOINFO(_FUNC, _RES, _OP1) \
784
    _FUNC(&(_OP1) _RND_MODE_ARG)
785
#else
786
#define BIDECIMAL_CALL1(_FUNC, _RES, _OP1) \
787
    _RES = _FUNC((_OP1) _RND_MODE_ARG _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
788
#define BIDECIMAL_CALL1_NORND(_FUNC, _RES, _OP1) \
789
    _RES = _FUNC((_OP1) _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
790
#define BIDECIMAL_CALL2(_FUNC, _RES, _OP1, _OP2) \
791
    _RES = _FUNC((_OP1), (_OP2) _RND_MODE_ARG _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
792
#define BIDECIMAL_CALL2_NORND(_FUNC, _RES, _OP1, _OP2) \
793
    _RES = _FUNC((_OP1), (_OP2) _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
794
#define BIDECIMAL_CALL1_NORND_RESREF(_FUNC, _RES, _OP1) \
795
    _FUNC((_RES), _OP1 _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
796
#define BIDECIMAL_CALL1_RESARG(_FUNC, _RES, _OP1) \
797
    _RES = _FUNC((_OP1) _RND_MODE_ARG _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
798
#define BIDECIMAL_CALL1_RESREF(_FUNC, _RES, _OP1) \
799
    _FUNC((_RES), _OP1 _RND_MODE_ARG _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
800
#define BIDECIMAL_CALL1_NORND_NOSTAT(_FUNC, _RES, _OP1) \
801
    _RES = _FUNC((_OP1) _EXC_MASKS_ARG _EXC_INFO_ARG)
802
#define BIDECIMAL_CALL2_NORND_NOSTAT(_FUNC, _RES, _OP1, _OP2) \
803
    _RES = _FUNC((_OP1), (_OP2) _EXC_MASKS_ARG _EXC_INFO_ARG)
804
#define BIDECIMAL_CALL3(_FUNC, _RES, _OP1, _OP2, _OP3) \
805
    _RES = _FUNC((_OP1), (_OP2), (_OP3) _RND_MODE_ARG _EXC_FLAGS_ARG _EXC_MASKS_ARG _EXC_INFO_ARG)
806
#define BIDECIMAL_CALL1_NORND_NOMASK_NOINFO(_FUNC, _RES, _OP1) \
807
    _RES = _FUNC((_OP1) _EXC_FLAGS_ARG)
808
#define BIDECIMAL_CALL1_NORND_NOFLAGS_NOMASK_NOINFO(_FUNC, _RES, _OP1) \
809
    _RES = _FUNC((_OP1) )
810
#define BIDECIMAL_CALL2_NORND_NOFLAGS_NOMASK_NOINFO(_FUNC, _RES, _OP1, _OP2) \
811
    _RES = _FUNC((_OP1), (_OP2) )
812
#define BIDECIMAL_CALL1_NORND_NOMASK_NOINFO_RESVOID(_FUNC, _OP1) \
813
    _FUNC((_OP1) _EXC_FLAGS_ARG)
814
#define BIDECIMAL_CALL2_NORND_NOMASK_NOINFO_RESVOID(_FUNC, _OP1, _OP2) \
815
    _FUNC((_OP1), (_OP2) _EXC_FLAGS_ARG)
816
#define BIDECIMAL_CALLV_NOFLAGS_NOMASK_NOINFO(_FUNC, _RES) \
817
    _RES = _FUNC(_RND_MODE_ARG_ALONE)
818
#if !DECIMAL_GLOBAL_ROUNDING
819
#define BIDECIMAL_CALL1_NOFLAGS_NOMASK_NOINFO(_FUNC, _RES, _OP1) \
820
    _RES = _FUNC((_OP1) _RND_MODE_ARG)
821
#else
822
#define BIDECIMAL_CALL1_NOFLAGS_NOMASK_NOINFO(_FUNC, _RES, _OP1) \
823
    _FUNC((_OP1) _RND_MODE_ARG)
824
#endif
825
#endif
826
 
827
#if BID_BIG_ENDIAN
828
#define HIGH_128W 0
829
#define LOW_128W  1
830
#else
831
#define HIGH_128W 1
832
#define LOW_128W  0
833
#endif
834
 
835
#if BID_BIG_ENDIAN
836
#define COPY_ARG_REF(arg_name) \
837
       UINT128 arg_name={ pbid_##arg_name->w[1], pbid_##arg_name->w[0]};
838
#define COPY_ARG_VAL(arg_name) \
839
       UINT128 arg_name={ bid_##arg_name.w[1], bid_##arg_name.w[0]};
840
#else
841
#define COPY_ARG_REF(arg_name) \
842
       UINT128 arg_name=*pbid_##arg_name;
843
#define COPY_ARG_VAL(arg_name) \
844
       UINT128 arg_name= bid_##arg_name;
845
#endif
846
 
847
#define COPY_ARG_TYPE_REF(type, arg_name) \
848
       type arg_name=*pbid_##arg_name;
849
#define COPY_ARG_TYPE_VAL(type, arg_name) \
850
       type arg_name= bid_##arg_name;
851
 
852
#if !DECIMAL_GLOBAL_ROUNDING
853
#define SET_RND_MODE() \
854
  _IDEC_round rnd_mode = *prnd_mode;
855
#else
856
#define SET_RND_MODE()
857
#endif
858
 
859
#define PROLOG_REF(arg_name) \
860
       COPY_ARG_REF(arg_name)
861
 
862
#define PROLOG_VAL(arg_name) \
863
       COPY_ARG_VAL(arg_name)
864
 
865
#define PROLOG_TYPE_REF(type, arg_name) \
866
       COPY_ARG_TYPE_REF(type, arg_name)
867
 
868
#define PROLOG_TYPE_VAL(type, arg_name) \
869
      COPY_ARG_TYPE_VAL(type, arg_name)
870
 
871
#define OTHER_PROLOG_REF()
872
#define OTHER_PROLOG_VAL()
873
 
874
#if DECIMAL_CALL_BY_REFERENCE
875
#define       BID128_FUNCTION_ARG1(fn_name, arg_name)\
876
      void fn_name (UINT128 * pres, \
877
           UINT128 *  \
878
           pbid_##arg_name _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
879
           _EXC_INFO_PARAM) {\
880
     PROLOG_REF(arg_name)   \
881
     SET_RND_MODE()         \
882
     OTHER_PROLOG_REF()
883
 
884
#define       BID128_FUNCTION_ARG1_NORND(fn_name, arg_name)\
885
      void fn_name (UINT128 * pres, \
886
           UINT128 *  \
887
           pbid_##arg_name _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
888
           _EXC_INFO_PARAM) {\
889
     PROLOG_REF(arg_name)   \
890
     OTHER_PROLOG_REF()
891
 
892
#define       BID128_FUNCTION_ARG1_NORND_CUSTOMRESTYPE(restype, fn_name, arg_name)\
893
      void fn_name (restype * pres, \
894
           UINT128 *  \
895
           pbid_##arg_name _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
896
           _EXC_INFO_PARAM) {\
897
     PROLOG_REF(arg_name)   \
898
     OTHER_PROLOG_REF()
899
 
900
#define       BID128_FUNCTION_ARG2(fn_name, arg_name1, arg_name2)\
901
      void fn_name (UINT128 * pres, \
902
           UINT128 *pbid_##arg_name1,  UINT128 *pbid_##arg_name2  \
903
           _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
904
           _EXC_INFO_PARAM) {\
905
     PROLOG_REF(arg_name1)   \
906
     PROLOG_REF(arg_name2)   \
907
     SET_RND_MODE()         \
908
     OTHER_PROLOG_REF()
909
 
910
#define       BID128_FUNCTION_ARG2_NORND_CUSTOMRESTYPE(restype, fn_name, arg_name1, arg_name2)\
911
      void fn_name (restype * pres, \
912
           UINT128 *pbid_##arg_name1,  UINT128 *pbid_##arg_name2  \
913
           _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
914
           _EXC_INFO_PARAM) {\
915
     PROLOG_REF(arg_name1)   \
916
     PROLOG_REF(arg_name2)   \
917
     OTHER_PROLOG_REF()
918
 
919
#define       BID128_FUNCTION_ARG128_ARGTYPE2(fn_name, arg_name1, type2, arg_name2)\
920
      void fn_name (UINT128 * pres, \
921
           UINT128 *pbid_##arg_name1,  type2 *pbid_##arg_name2  \
922
           _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
923
           _EXC_INFO_PARAM) {\
924
     PROLOG_REF(arg_name1)   \
925
     PROLOG_TYPE_REF(type2, arg_name2)   \
926
     SET_RND_MODE()         \
927
     OTHER_PROLOG_REF()
928
 
929
#define       TYPE0_FUNCTION_ARGTYPE1_ARGTYPE2(type0, fn_name, type1, arg_name1, type2, arg_name2)\
930
      void fn_name (type0 *pres, \
931
           type1 *pbid_##arg_name1,  type2 *pbid_##arg_name2  \
932
           _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
933
           _EXC_INFO_PARAM) {\
934
     PROLOG_TYPE_REF(type1, arg_name1)   \
935
     PROLOG_TYPE_REF(type2, arg_name2)   \
936
     SET_RND_MODE()         \
937
     OTHER_PROLOG_REF()
938
 
939
#define       BID128_FUNCTION_ARGTYPE1_ARG128(fn_name, type1, arg_name1, arg_name2)\
940
      void fn_name (UINT128 * pres, \
941
           type1 *pbid_##arg_name1,  UINT128 *pbid_##arg_name2  \
942
           _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
943
           _EXC_INFO_PARAM) {\
944
     PROLOG_TYPE_REF(type1, arg_name1)   \
945
     PROLOG_REF(arg_name2)   \
946
     SET_RND_MODE()         \
947
     OTHER_PROLOG_REF()
948
 
949
#define       TYPE0_FUNCTION_ARG128_ARGTYPE2(type0, fn_name, arg_name1, type2, arg_name2)\
950
      void fn_name (type0 *pres, \
951
           UINT128 *pbid_##arg_name1,  type2 *pbid_##arg_name2  \
952
           _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
953
           _EXC_INFO_PARAM) {\
954
     PROLOG_REF(arg_name1)   \
955
     PROLOG_TYPE_REF(type2, arg_name2)   \
956
     SET_RND_MODE()         \
957
     OTHER_PROLOG_REF()
958
 
959
#define       TYPE0_FUNCTION_ARGTYPE1_ARG128(type0, fn_name, type1, arg_name1, arg_name2)\
960
      void fn_name (type0 *pres, \
961
           type1 *pbid_##arg_name1,  UINT128 *pbid_##arg_name2  \
962
           _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
963
           _EXC_INFO_PARAM) {\
964
     PROLOG_TYPE_REF(type1, arg_name1)   \
965
     PROLOG_REF(arg_name2)   \
966
     SET_RND_MODE()         \
967
     OTHER_PROLOG_REF()
968
 
969
#define       TYPE0_FUNCTION_ARG128_ARG128(type0, fn_name, arg_name1, arg_name2)\
970
      void fn_name (type0 * pres, \
971
           UINT128 *pbid_##arg_name1,  UINT128 *pbid_##arg_name2  \
972
           _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
973
           _EXC_INFO_PARAM) {\
974
     PROLOG_REF(arg_name1)   \
975
     PROLOG_REF(arg_name2)   \
976
     SET_RND_MODE()         \
977
     OTHER_PROLOG_REF()
978
 
979
#define       TYPE0_FUNCTION_ARG1(type0, fn_name, arg_name)\
980
      void fn_name (type0 * pres, \
981
           UINT128 *  \
982
           pbid_##arg_name _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
983
           _EXC_INFO_PARAM) {\
984
     PROLOG_REF(arg_name)   \
985
     SET_RND_MODE()         \
986
     OTHER_PROLOG_REF()
987
 
988
#define       BID128_FUNCTION_ARGTYPE1(fn_name, type1, arg_name)\
989
      void fn_name (UINT128 * pres, \
990
           type1 *  \
991
           pbid_##arg_name _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
992
           _EXC_INFO_PARAM) {\
993
     PROLOG_TYPE_REF(type1, arg_name)   \
994
     SET_RND_MODE()         \
995
     OTHER_PROLOG_REF()
996
 
997
#define       TYPE0_FUNCTION_ARGTYPE1(type0, fn_name, type1, arg_name)\
998
      void fn_name (type0 * pres, \
999
           type1 *  \
1000
           pbid_##arg_name _RND_MODE_PARAM _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
1001
           _EXC_INFO_PARAM) {\
1002
     PROLOG_TYPE_REF(type1, arg_name)   \
1003
     SET_RND_MODE()         \
1004
     OTHER_PROLOG_REF()
1005
 
1006
#define       TYPE0_FUNCTION_ARGTYPE1_NORND(type0, fn_name, type1, arg_name)\
1007
      void fn_name (type0 * pres, \
1008
           type1 *  \
1009
           pbid_##arg_name _EXC_FLAGS_PARAM _EXC_MASKS_PARAM \
1010
           _EXC_INFO_PARAM) {\
1011
     PROLOG_TYPE_REF(type1, arg_name)   \
1012
     OTHER_PROLOG_REF()
1013
 
1014
//////////////////////////////////////////
1015
/////////////////////////////////////////
1016
////////////////////////////////////////
1017
 
1018
#else
1019
 
1020
//////////////////////////////////////////
1021
/////////////////////////////////////////
1022
////////////////////////////////////////
1023
 
1024
#define       BID128_FUNCTION_ARG1(fn_name, arg_name)\
1025
     UINT128                                     \
1026
     fn_name (UINT128 bid_##arg_name _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1027
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) { \
1028
     PROLOG_VAL(arg_name)                      \
1029
     OTHER_PROLOG_VAL()
1030
 
1031
#define       BID128_FUNCTION_ARG1_NORND(fn_name, arg_name)\
1032
     UINT128                                     \
1033
     fn_name (UINT128 bid_##arg_name _EXC_FLAGS_PARAM  \
1034
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) { \
1035
     PROLOG_VAL(arg_name)                      \
1036
     OTHER_PROLOG_VAL()
1037
 
1038
#define       BID128_FUNCTION_ARG1_NORND_CUSTOMRESTYPE(restype, fn_name, arg_name)\
1039
     restype                                     \
1040
     fn_name (UINT128 bid_##arg_name _EXC_FLAGS_PARAM  \
1041
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) { \
1042
     PROLOG_VAL(arg_name)                      \
1043
     OTHER_PROLOG_VAL()
1044
 
1045
#define       BID128_FUNCTION_ARG2(fn_name, arg_name1, arg_name2)\
1046
     UINT128                                     \
1047
     fn_name (UINT128 bid_##arg_name1,      \
1048
            UINT128 bid_##arg_name2 _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1049
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) {  \
1050
     PROLOG_VAL(arg_name1)                      \
1051
     PROLOG_VAL(arg_name2)                      \
1052
     OTHER_PROLOG_VAL()
1053
 
1054
#define       BID128_FUNCTION_ARG2_NORND_CUSTOMRESTYPE(restype, fn_name, arg_name1, arg_name2)\
1055
     restype                                    \
1056
     fn_name (UINT128 bid_##arg_name1,      \
1057
            UINT128 bid_##arg_name2 _EXC_FLAGS_PARAM  \
1058
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) {  \
1059
     PROLOG_VAL(arg_name1)                      \
1060
     PROLOG_VAL(arg_name2)                      \
1061
     OTHER_PROLOG_VAL()
1062
 
1063
#define       BID128_FUNCTION_ARG128_ARGTYPE2(fn_name, arg_name1, type2, arg_name2)\
1064
     UINT128                                     \
1065
     fn_name (UINT128 bid_##arg_name1,      \
1066
            type2 bid_##arg_name2 _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1067
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) {  \
1068
     PROLOG_VAL(arg_name1)                      \
1069
     PROLOG_TYPE_VAL(type2, arg_name2)          \
1070
     OTHER_PROLOG_VAL()
1071
 
1072
#define       TYPE0_FUNCTION_ARGTYPE1_ARGTYPE2(type0, fn_name, type1, arg_name1, type2, arg_name2)\
1073
     type0                                     \
1074
     fn_name (type1 bid_##arg_name1,      \
1075
            type2 bid_##arg_name2 _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1076
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) {  \
1077
     PROLOG_TYPE_VAL(type1, arg_name1)                      \
1078
     PROLOG_TYPE_VAL(type2, arg_name2)          \
1079
     OTHER_PROLOG_VAL()
1080
 
1081
#define       BID128_FUNCTION_ARGTYPE1_ARG128(fn_name, type1, arg_name1, arg_name2)\
1082
     UINT128                                     \
1083
     fn_name (type1 bid_##arg_name1,      \
1084
            UINT128 bid_##arg_name2 _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1085
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) {  \
1086
     PROLOG_TYPE_VAL(type1, arg_name1)          \
1087
     PROLOG_VAL(arg_name2)                      \
1088
     OTHER_PROLOG_VAL()
1089
 
1090
#define       TYPE0_FUNCTION_ARG128_ARGTYPE2(type0, fn_name, arg_name1, type2, arg_name2)\
1091
     type0                                     \
1092
     fn_name (UINT128 bid_##arg_name1,      \
1093
            type2 bid_##arg_name2 _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1094
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) {  \
1095
     PROLOG_VAL(arg_name1)                      \
1096
     PROLOG_TYPE_VAL(type2, arg_name2)          \
1097
     OTHER_PROLOG_VAL()
1098
 
1099
#define       TYPE0_FUNCTION_ARGTYPE1_ARG128(type0, fn_name, type1, arg_name1, arg_name2)\
1100
     type0                                     \
1101
     fn_name (type1 bid_##arg_name1,      \
1102
            UINT128 bid_##arg_name2 _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1103
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) {  \
1104
     PROLOG_TYPE_VAL(type1, arg_name1)                      \
1105
     PROLOG_VAL(arg_name2)          \
1106
     OTHER_PROLOG_VAL()
1107
 
1108
#define       TYPE0_FUNCTION_ARG128_ARG128(type0, fn_name, arg_name1, arg_name2)\
1109
     type0                                     \
1110
     fn_name (UINT128 bid_##arg_name1,      \
1111
            UINT128 bid_##arg_name2 _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1112
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) {  \
1113
     PROLOG_VAL(arg_name1)                      \
1114
     PROLOG_VAL(arg_name2)                      \
1115
     OTHER_PROLOG_VAL()
1116
 
1117
#define       TYPE0_FUNCTION_ARG1(type0, fn_name, arg_name)\
1118
     type0                                     \
1119
     fn_name (UINT128 bid_##arg_name _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1120
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) { \
1121
     PROLOG_VAL(arg_name)                      \
1122
     OTHER_PROLOG_VAL()
1123
 
1124
#define       BID128_FUNCTION_ARGTYPE1(fn_name, type1, arg_name)\
1125
     UINT128                                     \
1126
     fn_name (type1 bid_##arg_name _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1127
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) { \
1128
     PROLOG_TYPE_VAL(type1, arg_name)                      \
1129
     OTHER_PROLOG_VAL()
1130
 
1131
#define       TYPE0_FUNCTION_ARGTYPE1(type0, fn_name, type1, arg_name)\
1132
     type0                                     \
1133
     fn_name (type1 bid_##arg_name _RND_MODE_PARAM _EXC_FLAGS_PARAM  \
1134
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) { \
1135
     PROLOG_TYPE_VAL(type1, arg_name)                      \
1136
     OTHER_PROLOG_VAL()
1137
 
1138
#define       TYPE0_FUNCTION_ARGTYPE1_NORND(type0, fn_name, type1, arg_name)\
1139
     type0                                     \
1140
     fn_name (type1 bid_##arg_name _EXC_FLAGS_PARAM  \
1141
           _EXC_MASKS_PARAM _EXC_INFO_PARAM) { \
1142
     PROLOG_TYPE_VAL(type1, arg_name)                      \
1143
     OTHER_PROLOG_VAL()
1144
 
1145
#endif
1146
 
1147
 
1148
 
1149
#define   BID_TO_SMALL_UINT_CVT_FUNCTION(type0, fn_name, type1, arg_name, cvt_fn_name, type2, size_mask, invalid_res)\
1150
    TYPE0_FUNCTION_ARGTYPE1_NORND(type0, fn_name, type1, arg_name)\
1151
        type2 res;                                                    \
1152
        _IDEC_flags saved_fpsc=*pfpsf;                                \
1153
    BIDECIMAL_CALL1_NORND(cvt_fn_name, res, arg_name);            \
1154
        if(res & size_mask) {                                         \
1155
      *pfpsf = saved_fpsc | INVALID_EXCEPTION;                    \
1156
          res = invalid_res; }                                        \
1157
    BID_RETURN_VAL((type0)res);                                   \
1158
                   }
1159
 
1160
#define   BID_TO_SMALL_INT_CVT_FUNCTION(type0, fn_name, type1, arg_name, cvt_fn_name, type2, size_mask, invalid_res)\
1161
    TYPE0_FUNCTION_ARGTYPE1_NORND(type0, fn_name, type1, arg_name)\
1162
        type2 res, sgn_mask;                                          \
1163
        _IDEC_flags saved_fpsc=*pfpsf;                                \
1164
    BIDECIMAL_CALL1_NORND(cvt_fn_name, res, arg_name);            \
1165
        sgn_mask = res & size_mask;                                   \
1166
        if(sgn_mask && (sgn_mask != (type2)size_mask)) {                     \
1167
      *pfpsf = saved_fpsc | INVALID_EXCEPTION;                    \
1168
          res = invalid_res; }                                        \
1169
    BID_RETURN_VAL((type0)res);                                   \
1170
                   }
1171
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.