| 1 | /* float.h (emx+gcc)
|
|---|
| 2 | * (bird: this file must be used over the one from GCC!)
|
|---|
| 3 | */
|
|---|
| 4 |
|
|---|
| 5 | #ifndef _FLOAT_H
|
|---|
| 6 | #define _FLOAT_H
|
|---|
| 7 |
|
|---|
| 8 | #if defined (__cplusplus)
|
|---|
| 9 | extern "C" {
|
|---|
| 10 | #endif
|
|---|
| 11 |
|
|---|
| 12 | #define FLT_RADIX 2 /* b */
|
|---|
| 13 | #define FLT_ROUNDS 1 /* FP addition rounds to nearest */
|
|---|
| 14 | #define FLT_EVAL_METHOD (-1) /* i387 semantics are...interesting */
|
|---|
| 15 | #define DECIMAL_DIG 21 /* max precision in decimal digits */
|
|---|
| 16 |
|
|---|
| 17 | #define FLT_MANT_DIG 24
|
|---|
| 18 | #define FLT_MIN_EXP (-125)
|
|---|
| 19 | #define FLT_MAX_EXP 128
|
|---|
| 20 | #define FLT_DIG 6
|
|---|
| 21 | #define FLT_MIN_10_EXP (-37)
|
|---|
| 22 | #define FLT_MAX_10_EXP 38
|
|---|
| 23 | #define FLT_MIN 1.17549435e-38F
|
|---|
| 24 | #define FLT_MAX 3.40282347e+38F
|
|---|
| 25 | #define FLT_EPSILON 1.19209290e-07F
|
|---|
| 26 |
|
|---|
| 27 | #define DBL_MANT_DIG 53
|
|---|
| 28 | #define DBL_MIN_EXP (-1021)
|
|---|
| 29 | #define DBL_MAX_EXP 1024
|
|---|
| 30 | #define DBL_DIG 15
|
|---|
| 31 | #define DBL_MIN_10_EXP (-307)
|
|---|
| 32 | #define DBL_MAX_10_EXP 308
|
|---|
| 33 | #define DBL_MIN 2.2250738585072014e-308
|
|---|
| 34 | #define DBL_MAX 1.7976931348623157e+308
|
|---|
| 35 | #define DBL_EPSILON 2.2204460492503131e-016
|
|---|
| 36 |
|
|---|
| 37 | /* bird: There is some divergence in the values for this section.
|
|---|
| 38 | * We'll go for the GCC values. */
|
|---|
| 39 | #define LDBL_MANT_DIG 64
|
|---|
| 40 | #define LDBL_MIN_EXP (-16381)
|
|---|
| 41 | #define LDBL_MAX_EXP 16384
|
|---|
| 42 | #define LDBL_DIG 18
|
|---|
| 43 | #define LDBL_MIN_10_EXP (-4931)
|
|---|
| 44 | #define LDBL_MAX_10_EXP 4932
|
|---|
| 45 | #if 0
|
|---|
| 46 | /* emx: */
|
|---|
| 47 | #define LDBL_MIN 3.3621031431120935063e-4932L
|
|---|
| 48 | #define LDBL_MAX 1.1897314953572317650e+4932L
|
|---|
| 49 | #define LDBL_EPSILON 1.08420217248550443400745280086994171142578125e-0019L
|
|---|
| 50 | #else
|
|---|
|
|---|