Install msysDVLPR-1.0.0-alpha-1
[msysgit.git] / include / machine / ieeefp.h
blobcc5ced4f03053e20a6e434e0a79222b6d466fc1b
1 #ifndef __IEEE_BIG_ENDIAN
2 #ifndef __IEEE_LITTLE_ENDIAN
4 /* This file can define macros to choose variations of the IEEE float
5 format:
7 _FLT_LARGEST_EXPONENT_IS_NORMAL
9 Defined if the float format uses the largest exponent for finite
10 numbers rather than NaN and infinity representations. Such a
11 format cannot represent NaNs or infinities at all, but it's FLT_MAX
12 is twice the IEEE value.
14 _FLT_NO_DENORMALS
16 Defined if the float format does not support IEEE denormals. Every
17 float with a zero exponent is taken to be a zero representation.
19 ??? At the moment, there are no equivalent macros for doubles and
20 the macros are not fully supported by --enable-newlib-hw-fp. */
22 #if defined(__arm__) || defined(__thumb__)
23 /* ARM always has big-endian words. Within those words the byte ordering
24 will be big or little endian depending upon the target. */
25 #define __IEEE_BIG_ENDIAN
26 #ifdef __ARMEL__
27 #define __IEEE_BYTES_LITTLE_ENDIAN
28 #endif
29 #endif
31 #ifdef __hppa__
32 #define __IEEE_BIG_ENDIAN
33 #endif
35 #ifdef __sparc__
36 #ifdef __LITTLE_ENDIAN_DATA__
37 #define __IEEE_LITTLE_ENDIAN
38 #else
39 #define __IEEE_BIG_ENDIAN
40 #endif
41 #endif
43 #if defined(__m68k__) || defined(__mc68000__)
44 #define __IEEE_BIG_ENDIAN
45 #endif
47 #if defined (__H8300__) || defined (__H8300H__) || defined (__H8300S__)
48 #define __IEEE_BIG_ENDIAN
49 #define __SMALL_BITFIELDS
50 #define _DOUBLE_IS_32BITS
51 #endif
53 #ifdef __H8500__
54 #define __IEEE_BIG_ENDIAN
55 #define __SMALL_BITFIELDS
56 #define _DOUBLE_IS_32BITS
57 #endif
59 #ifdef __sh__
60 #ifdef __LITTLE_ENDIAN__
61 #define __IEEE_LITTLE_ENDIAN
62 #else
63 #define __IEEE_BIG_ENDIAN
64 #endif
65 #if defined(__SH3E__) || defined(__SH4_SINGLE_ONLY__)
66 #define _DOUBLE_IS_32BITS
67 #endif
68 #endif
70 #ifdef _AM29K
71 #define __IEEE_BIG_ENDIAN
72 #endif
74 #ifdef _WIN32
75 #define __IEEE_LITTLE_ENDIAN
76 #endif
78 #ifdef __i386__
79 #define __IEEE_LITTLE_ENDIAN
80 #endif
82 #ifdef __i960__
83 #define __IEEE_LITTLE_ENDIAN
84 #endif
86 #ifdef __M32R__
87 #define __IEEE_BIG_ENDIAN
88 #endif
90 #ifdef __TIC80__
91 #define __IEEE_LITTLE_ENDIAN
92 #endif
94 #ifdef __MIPSEL__
95 #define __IEEE_LITTLE_ENDIAN
96 #endif
97 #ifdef __MIPSEB__
98 #define __IEEE_BIG_ENDIAN
99 #endif
101 /* necv70 was __IEEE_LITTLE_ENDIAN. */
103 #ifdef __W65__
104 #define __IEEE_LITTLE_ENDIAN
105 #define __SMALL_BITFIELDS
106 #define _DOUBLE_IS_32BITS
107 #endif
109 #if defined(__Z8001__) || defined(__Z8002__)
110 #define __IEEE_BIG_ENDIAN
111 #endif
113 #ifdef __m88k__
114 #define __IEEE_BIG_ENDIAN
115 #endif
117 #ifdef __mn10300__
118 #define __IEEE_LITTLE_ENDIAN
119 #endif
121 #ifdef __mn10200__
122 #define __IEEE_LITTLE_ENDIAN
123 #define __SMALL_BITFIELDS
124 #define _DOUBLE_IS_32BITS
125 #endif
127 #ifdef __v800
128 #define __IEEE_LITTLE_ENDIAN
129 #endif
131 #ifdef __v850
132 #define __IEEE_LITTLE_ENDIAN
133 #endif
135 #ifdef __D10V__
136 #define __IEEE_BIG_ENDIAN
137 #define _DOUBLE_IS_32BITS
138 #define __SMALL_BITFIELDS
139 #endif
141 #ifdef __PPC__
142 #if (defined(_BIG_ENDIAN) && _BIG_ENDIAN) || (defined(_AIX) && _AIX)
143 #define __IEEE_BIG_ENDIAN
144 #else
145 #if (defined(_LITTLE_ENDIAN) && _LITTLE_ENDIAN) || (defined(__sun__) && __sun__) || (defined(_WIN32) && _WIN32)
146 #define __IEEE_LITTLE_ENDIAN
147 #endif
148 #endif
149 #endif
151 #ifdef __arc__
152 #ifdef __big_endian__
153 #define __IEEE_BIG_ENDIAN
154 #else
155 #define __IEEE_LITTLE_ENDIAN
156 #endif
157 #endif
159 #ifdef __fr30__
160 #define __IEEE_BIG_ENDIAN
161 #endif
163 #ifdef __mcore__
164 #define __IEEE_BIG_ENDIAN
165 #endif
167 #ifdef __ia64__
168 #ifdef __BIG_ENDIAN__
169 #define __IEEE_BIG_ENDIAN
170 #else
171 #define __IEEE_LITTLE_ENDIAN
172 #endif
173 #endif
175 #ifdef __AVR__
176 #define __IEEE_LITTLE_ENDIAN
177 #define __SMALL_BITFIELDS
178 #define _DOUBLE_IS_32BITS
179 #endif
181 #if defined(__or32__) || defined(__or1k__) || defined(__or16__)
182 #define __IEEE_BIG_ENDIAN
183 #endif
186 #ifndef __IEEE_BIG_ENDIAN
187 #ifndef __IEEE_LITTLE_ENDIAN
188 #error Endianess not declared!!
189 #endif /* not __IEEE_LITTLE_ENDIAN */
190 #endif /* not __IEEE_BIG_ENDIAN */
192 #endif /* not __IEEE_LITTLE_ENDIAN */
193 #endif /* not __IEEE_BIG_ENDIAN */