Contents of /trunk/glibc/patches/glibc-2.15-non-signalling-comparisons.patch
Parent Directory | Revision Log
Revision 1806 -
(show annotations)
(download)
Tue Jun 12 12:33:27 2012 UTC (12 years, 3 months ago) by niro
File size: 28550 byte(s)
Tue Jun 12 12:33:27 2012 UTC (12 years, 3 months ago) by niro
File size: 28550 byte(s)
-added patches for 2.15-r1
1 | diff --git a/math/w_acos.c b/math/w_acos.c |
2 | index 3138408..0490933 100644 |
3 | --- a/math/w_acos.c |
4 | +++ b/math/w_acos.c |
5 | @@ -1,4 +1,4 @@ |
6 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
7 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
8 | This file is part of the GNU C Library. |
9 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
10 | |
11 | @@ -25,7 +25,8 @@ |
12 | double |
13 | __acos (double x) |
14 | { |
15 | - if (__builtin_expect (fabs (x) > 1.0, 0) && _LIB_VERSION != _IEEE_) |
16 | + if (__builtin_expect (isgreater (fabs (x), 1.0), 0) |
17 | + && _LIB_VERSION != _IEEE_) |
18 | { |
19 | /* acos(|x|>1) */ |
20 | feraiseexcept (FE_INVALID); |
21 | diff --git a/math/w_acosf.c b/math/w_acosf.c |
22 | index 0e41a2c..2500a7d 100644 |
23 | --- a/math/w_acosf.c |
24 | +++ b/math/w_acosf.c |
25 | @@ -1,4 +1,4 @@ |
26 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
27 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
28 | This file is part of the GNU C Library. |
29 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
30 | |
31 | @@ -25,7 +25,8 @@ |
32 | float |
33 | __acosf (float x) |
34 | { |
35 | - if (__builtin_expect (fabsf (x) > 1.0f, 0) && _LIB_VERSION != _IEEE_) |
36 | + if (__builtin_expect (isgreater (fabsf (x), 1.0f), 0) |
37 | + && _LIB_VERSION != _IEEE_) |
38 | { |
39 | /* acos(|x|>1) */ |
40 | feraiseexcept (FE_INVALID); |
41 | diff --git a/math/w_acosh.c b/math/w_acosh.c |
42 | index 0bd2686..d632987 100644 |
43 | --- a/math/w_acosh.c |
44 | +++ b/math/w_acosh.c |
45 | @@ -1,4 +1,4 @@ |
46 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
47 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
48 | This file is part of the GNU C Library. |
49 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
50 | |
51 | @@ -24,7 +24,7 @@ |
52 | double |
53 | __acosh (double x) |
54 | { |
55 | - if (__builtin_expect (x < 1.0, 0) && _LIB_VERSION != _IEEE_) |
56 | + if (__builtin_expect (isless (x, 1.0), 0) && _LIB_VERSION != _IEEE_) |
57 | /* acosh(x<1) */ |
58 | return __kernel_standard (x, x, 29); |
59 | |
60 | diff --git a/math/w_acoshf.c b/math/w_acoshf.c |
61 | index c59bf94..f77df2b 100644 |
62 | --- a/math/w_acoshf.c |
63 | +++ b/math/w_acoshf.c |
64 | @@ -1,4 +1,4 @@ |
65 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
66 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
67 | This file is part of the GNU C Library. |
68 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
69 | |
70 | @@ -24,7 +24,7 @@ |
71 | float |
72 | __acoshf (float x) |
73 | { |
74 | - if (__builtin_expect (x < 1.0f, 0) && _LIB_VERSION != _IEEE_) |
75 | + if (__builtin_expect (isless (x, 1.0f), 0) && _LIB_VERSION != _IEEE_) |
76 | /* acosh(x<1) */ |
77 | return __kernel_standard_f (x, x, 129); |
78 | |
79 | diff --git a/math/w_acoshl.c b/math/w_acoshl.c |
80 | index 819bdfc..cc823b8 100644 |
81 | --- a/math/w_acoshl.c |
82 | +++ b/math/w_acoshl.c |
83 | @@ -1,4 +1,4 @@ |
84 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
85 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
86 | This file is part of the GNU C Library. |
87 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
88 | |
89 | @@ -24,7 +24,7 @@ |
90 | long double |
91 | __acoshl (long double x) |
92 | { |
93 | - if (__builtin_expect (x < 1.0L, 0) && _LIB_VERSION != _IEEE_) |
94 | + if (__builtin_expect (isless (x, 1.0L), 0) && _LIB_VERSION != _IEEE_) |
95 | /* acosh(x<1) */ |
96 | return __kernel_standard (x, x, 229); |
97 | |
98 | diff --git a/math/w_acosl.c b/math/w_acosl.c |
99 | index 6417068..05023b4 100644 |
100 | --- a/math/w_acosl.c |
101 | +++ b/math/w_acosl.c |
102 | @@ -1,4 +1,4 @@ |
103 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
104 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
105 | This file is part of the GNU C Library. |
106 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
107 | |
108 | @@ -25,7 +25,8 @@ |
109 | long double |
110 | __acosl (long double x) |
111 | { |
112 | - if (__builtin_expect (fabsl (x) > 1.0L, 0) && _LIB_VERSION != _IEEE_) |
113 | + if (__builtin_expect (isgreater (fabsl (x), 1.0L), 0) |
114 | + && _LIB_VERSION != _IEEE_) |
115 | { |
116 | /* acos(|x|>1) */ |
117 | feraiseexcept (FE_INVALID); |
118 | diff --git a/math/w_asin.c b/math/w_asin.c |
119 | index d4e89ce..0fa9487 100644 |
120 | --- a/math/w_asin.c |
121 | +++ b/math/w_asin.c |
122 | @@ -1,4 +1,4 @@ |
123 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
124 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
125 | This file is part of the GNU C Library. |
126 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
127 | |
128 | @@ -25,7 +25,8 @@ |
129 | double |
130 | __asin (double x) |
131 | { |
132 | - if (__builtin_expect (fabs (x) > 1.0, 0) && _LIB_VERSION != _IEEE_) |
133 | + if (__builtin_expect (isgreater (fabs (x), 1.0), 0) |
134 | + && _LIB_VERSION != _IEEE_) |
135 | { |
136 | /* asin(|x|>1) */ |
137 | feraiseexcept (FE_INVALID); |
138 | diff --git a/math/w_asinf.c b/math/w_asinf.c |
139 | index 270961f..c28edab 100644 |
140 | --- a/math/w_asinf.c |
141 | +++ b/math/w_asinf.c |
142 | @@ -1,4 +1,4 @@ |
143 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
144 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
145 | This file is part of the GNU C Library. |
146 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
147 | |
148 | @@ -25,7 +25,8 @@ |
149 | float |
150 | __asinf (float x) |
151 | { |
152 | - if (__builtin_expect (fabsf (x) > 1.0f, 0) && _LIB_VERSION != _IEEE_) |
153 | + if (__builtin_expect (isgreater (fabsf (x), 1.0f), 0) |
154 | + && _LIB_VERSION != _IEEE_) |
155 | { |
156 | /* asin(|x|>1) */ |
157 | feraiseexcept (FE_INVALID); |
158 | diff --git a/math/w_asinl.c b/math/w_asinl.c |
159 | index 32e5273..e4036d8 100644 |
160 | --- a/math/w_asinl.c |
161 | +++ b/math/w_asinl.c |
162 | @@ -1,4 +1,4 @@ |
163 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
164 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
165 | This file is part of the GNU C Library. |
166 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
167 | |
168 | @@ -25,7 +25,8 @@ |
169 | long double |
170 | __asinl (long double x) |
171 | { |
172 | - if (__builtin_expect (fabsl (x) > 1.0L, 0) && _LIB_VERSION != _IEEE_) |
173 | + if (__builtin_expect (isgreater (fabsl (x), 1.0L), 0) |
174 | + && _LIB_VERSION != _IEEE_) |
175 | { |
176 | /* asin(|x|>1) */ |
177 | feraiseexcept (FE_INVALID); |
178 | diff --git a/math/w_atanh.c b/math/w_atanh.c |
179 | index 1022bd5..190d2e9 100644 |
180 | --- a/math/w_atanh.c |
181 | +++ b/math/w_atanh.c |
182 | @@ -1,4 +1,4 @@ |
183 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
184 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
185 | This file is part of the GNU C Library. |
186 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
187 | |
188 | @@ -24,7 +24,8 @@ |
189 | double |
190 | __atanh (double x) |
191 | { |
192 | - if (__builtin_expect (fabs (x) >= 1.0, 0) && _LIB_VERSION != _IEEE_) |
193 | + if (__builtin_expect (isgreaterequal (fabs (x), 1.0), 0) |
194 | + && _LIB_VERSION != _IEEE_) |
195 | return __kernel_standard (x, x, |
196 | fabs (x) > 1.0 |
197 | ? 30 /* atanh(|x|>1) */ |
198 | diff --git a/math/w_atanhf.c b/math/w_atanhf.c |
199 | index 3c8cf83..e0c5dc3 100644 |
200 | --- a/math/w_atanhf.c |
201 | +++ b/math/w_atanhf.c |
202 | @@ -1,4 +1,4 @@ |
203 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
204 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
205 | This file is part of the GNU C Library. |
206 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
207 | |
208 | @@ -24,7 +24,8 @@ |
209 | float |
210 | __atanhf (float x) |
211 | { |
212 | - if (__builtin_expect (fabsf (x) >= 1.0f, 0) && _LIB_VERSION != _IEEE_) |
213 | + if (__builtin_expect (isgreaterequal (fabsf (x), 1.0f), 0) |
214 | + && _LIB_VERSION != _IEEE_) |
215 | return __kernel_standard_f (x, x, |
216 | fabsf (x) > 1.0f |
217 | ? 130 /* atanh(|x|>1) */ |
218 | diff --git a/math/w_atanhl.c b/math/w_atanhl.c |
219 | index f582acf..319535d 100644 |
220 | --- a/math/w_atanhl.c |
221 | +++ b/math/w_atanhl.c |
222 | @@ -1,4 +1,4 @@ |
223 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
224 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
225 | This file is part of the GNU C Library. |
226 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
227 | |
228 | @@ -24,7 +24,8 @@ |
229 | long double |
230 | __atanhl (long double x) |
231 | { |
232 | - if (__builtin_expect (fabsl (x) >= 1.0L, 0) && _LIB_VERSION != _IEEE_) |
233 | + if (__builtin_expect (isgreaterequal (fabsl (x), 1.0L), 0) |
234 | + && _LIB_VERSION != _IEEE_) |
235 | return __kernel_standard (x, x, |
236 | fabsl (x) > 1.0L |
237 | ? 230 /* atanh(|x|>1) */ |
238 | diff --git a/math/w_exp2.c b/math/w_exp2.c |
239 | index bf22326..7a3b0af 100644 |
240 | --- a/math/w_exp2.c |
241 | +++ b/math/w_exp2.c |
242 | @@ -12,7 +12,8 @@ static const double u_threshold = (double) (DBL_MIN_EXP - DBL_MANT_DIG - 1); |
243 | double |
244 | __exp2 (double x) |
245 | { |
246 | - if (__builtin_expect (x <= u_threshold || x > o_threshold, 0) |
247 | + if (__builtin_expect (islessequal (x, u_threshold) |
248 | + || isgreater (x, o_threshold), 0) |
249 | && _LIB_VERSION != _IEEE_ && __finite (x)) |
250 | /* exp2 overflow: 44, exp2 underflow: 45 */ |
251 | return __kernel_standard (x, x, 44 + (x <= o_threshold)); |
252 | diff --git a/math/w_exp2f.c b/math/w_exp2f.c |
253 | index 7215fca..c4e9e94 100644 |
254 | --- a/math/w_exp2f.c |
255 | +++ b/math/w_exp2f.c |
256 | @@ -12,7 +12,8 @@ static const float u_threshold = (float) (FLT_MIN_EXP - FLT_MANT_DIG - 1); |
257 | float |
258 | __exp2f (float x) |
259 | { |
260 | - if (__builtin_expect (x <= u_threshold || x > o_threshold, 0) |
261 | + if (__builtin_expect (islessequal (x, u_threshold) |
262 | + || isgreater (x, o_threshold), 0) |
263 | && _LIB_VERSION != _IEEE_ && __finitef (x)) |
264 | /* exp2 overflow: 144, exp2 underflow: 145 */ |
265 | return __kernel_standard_f (x, x, 144 + (x <= o_threshold)); |
266 | diff --git a/math/w_exp2l.c b/math/w_exp2l.c |
267 | index ac8d231..442a637 100644 |
268 | --- a/math/w_exp2l.c |
269 | +++ b/math/w_exp2l.c |
270 | @@ -13,7 +13,8 @@ static const long double u_threshold |
271 | long double |
272 | __exp2l (long double x) |
273 | { |
274 | - if (__builtin_expect (x <= u_threshold || x > o_threshold, 0) |
275 | + if (__builtin_expect (islessequal (x, u_threshold) |
276 | + || isgreater (x, o_threshold), 0) |
277 | && _LIB_VERSION != _IEEE_ && __finitel (x)) |
278 | /* exp2 overflow: 244, exp2 underflow: 245 */ |
279 | return __kernel_standard (x, x, 244 + (x <= o_threshold)); |
280 | diff --git a/math/w_j0.c b/math/w_j0.c |
281 | index 1dff8b4..f8d3724 100644 |
282 | --- a/math/w_j0.c |
283 | +++ b/math/w_j0.c |
284 | @@ -1,4 +1,4 @@ |
285 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
286 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
287 | This file is part of the GNU C Library. |
288 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
289 | |
290 | @@ -25,7 +25,8 @@ |
291 | double |
292 | j0 (double x) |
293 | { |
294 | - if (__builtin_expect (fabs (x) > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
295 | + if (__builtin_expect (isgreater (fabs (x), X_TLOSS), 0) |
296 | + && _LIB_VERSION != _IEEE_) |
297 | /* j0(|x|>X_TLOSS) */ |
298 | return __kernel_standard (x, x, 34); |
299 | |
300 | @@ -40,7 +41,8 @@ strong_alias (j0, j0l) |
301 | double |
302 | y0 (double x) |
303 | { |
304 | - if (__builtin_expect (x <= 0.0 || x > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
305 | + if (__builtin_expect (islessequal (x, 0.0) || isgreater (x, X_TLOSS), 0) |
306 | + && _LIB_VERSION != _IEEE_) |
307 | { |
308 | if (x < 0.0) |
309 | { |
310 | diff --git a/math/w_j0f.c b/math/w_j0f.c |
311 | index fc52f26..cef36aa 100644 |
312 | --- a/math/w_j0f.c |
313 | +++ b/math/w_j0f.c |
314 | @@ -1,4 +1,4 @@ |
315 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
316 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
317 | This file is part of the GNU C Library. |
318 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
319 | |
320 | @@ -25,7 +25,7 @@ |
321 | float |
322 | j0f (float x) |
323 | { |
324 | - if (__builtin_expect (fabsf (x) > (float) X_TLOSS, 0) |
325 | + if (__builtin_expect (isgreater (fabsf (x), (float) X_TLOSS), 0) |
326 | && _LIB_VERSION != _IEEE_) |
327 | /* j0(|x|>X_TLOSS) */ |
328 | return __kernel_standard_f (x, x, 134); |
329 | @@ -38,7 +38,8 @@ j0f (float x) |
330 | float |
331 | y0f (float x) |
332 | { |
333 | - if (__builtin_expect (x <= 0.0f || x > (float) X_TLOSS, 0) |
334 | + if (__builtin_expect (islessequal (x, 0.0f) |
335 | + || isgreater (x, (float) X_TLOSS), 0) |
336 | && _LIB_VERSION != _IEEE_) |
337 | { |
338 | if (x < 0.0f) |
339 | diff --git a/math/w_j0l.c b/math/w_j0l.c |
340 | index 8d72d50..144f33c 100644 |
341 | --- a/math/w_j0l.c |
342 | +++ b/math/w_j0l.c |
343 | @@ -1,4 +1,4 @@ |
344 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
345 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
346 | This file is part of the GNU C Library. |
347 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
348 | |
349 | @@ -25,7 +25,8 @@ |
350 | long double |
351 | __j0l (long double x) |
352 | { |
353 | - if (__builtin_expect (fabsl (x) > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
354 | + if (__builtin_expect (isgreater (fabsl (x), X_TLOSS), 0) |
355 | + && _LIB_VERSION != _IEEE_) |
356 | /* j0(|x|>X_TLOSS) */ |
357 | return __kernel_standard (x, x, 234); |
358 | |
359 | @@ -38,7 +39,8 @@ weak_alias (__j0l, j0l) |
360 | long double |
361 | __y0l (long double x) |
362 | { |
363 | - if (__builtin_expect (x <= 0.0L || x > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
364 | + if (__builtin_expect (islessequal (x, 0.0L) || isgreater (x, X_TLOSS), 0) |
365 | + && _LIB_VERSION != _IEEE_) |
366 | { |
367 | if (x < 0.0L) |
368 | { |
369 | diff --git a/math/w_j1.c b/math/w_j1.c |
370 | index 358e0e1..e9a5357 100644 |
371 | --- a/math/w_j1.c |
372 | +++ b/math/w_j1.c |
373 | @@ -1,4 +1,4 @@ |
374 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
375 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
376 | This file is part of the GNU C Library. |
377 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
378 | |
379 | @@ -25,7 +25,8 @@ |
380 | double |
381 | j1 (double x) |
382 | { |
383 | - if (__builtin_expect (fabs (x) > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
384 | + if (__builtin_expect (isgreater (fabs (x), X_TLOSS), 0) |
385 | + && _LIB_VERSION != _IEEE_) |
386 | /* j1(|x|>X_TLOSS) */ |
387 | return __kernel_standard (x, x, 36); |
388 | |
389 | @@ -40,7 +41,8 @@ strong_alias (j1, j1l) |
390 | double |
391 | y1 (double x) |
392 | { |
393 | - if (__builtin_expect (x <= 0.0 || x > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
394 | + if (__builtin_expect (islessequal (x, 0.0) || isgreater (x, X_TLOSS), 0) |
395 | + && _LIB_VERSION != _IEEE_) |
396 | { |
397 | if (x < 0.0) |
398 | { |
399 | diff --git a/math/w_j1f.c b/math/w_j1f.c |
400 | index 096fdf5..29bd949 100644 |
401 | --- a/math/w_j1f.c |
402 | +++ b/math/w_j1f.c |
403 | @@ -1,4 +1,4 @@ |
404 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
405 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
406 | This file is part of the GNU C Library. |
407 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
408 | |
409 | @@ -25,7 +25,8 @@ |
410 | float |
411 | j1f (float x) |
412 | { |
413 | - if (__builtin_expect (fabsf (x) > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
414 | + if (__builtin_expect (isgreater (fabsf (x), X_TLOSS), 0) |
415 | + && _LIB_VERSION != _IEEE_) |
416 | /* j1(|x|>X_TLOSS) */ |
417 | return __kernel_standard_f (x, x, 136); |
418 | |
419 | @@ -37,7 +38,8 @@ j1f (float x) |
420 | float |
421 | y1f (float x) |
422 | { |
423 | - if (__builtin_expect (x <= 0.0f || x > (float) X_TLOSS, 0) |
424 | + if (__builtin_expect (islessequal (x, 0.0f) |
425 | + || isgreater (x, (float) X_TLOSS), 0) |
426 | && _LIB_VERSION != _IEEE_) |
427 | { |
428 | if (x < 0.0f) |
429 | diff --git a/math/w_j1l.c b/math/w_j1l.c |
430 | index 93e4ee4..01b8551 100644 |
431 | --- a/math/w_j1l.c |
432 | +++ b/math/w_j1l.c |
433 | @@ -1,4 +1,4 @@ |
434 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
435 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
436 | This file is part of the GNU C Library. |
437 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
438 | |
439 | @@ -25,7 +25,8 @@ |
440 | long double |
441 | __j1l (long double x) |
442 | { |
443 | - if (__builtin_expect (fabsl (x) > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
444 | + if (__builtin_expect (isgreater (fabsl (x), X_TLOSS), 0) |
445 | + && _LIB_VERSION != _IEEE_) |
446 | /* j1(|x|>X_TLOSS) */ |
447 | return __kernel_standard (x, x, 236); |
448 | |
449 | @@ -38,7 +39,8 @@ weak_alias (__j1l, j1l) |
450 | long double |
451 | __y1l (long double x) |
452 | { |
453 | - if (__builtin_expect (x <= 0.0L || x > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
454 | + if (__builtin_expect (islessequal (x, 0.0L) || isgreater (x, X_TLOSS), 0) |
455 | + && _LIB_VERSION != _IEEE_) |
456 | { |
457 | if (x < 0.0L) |
458 | { |
459 | diff --git a/math/w_jn.c b/math/w_jn.c |
460 | index f0dd8c6..fd3fb16 100644 |
461 | --- a/math/w_jn.c |
462 | +++ b/math/w_jn.c |
463 | @@ -1,4 +1,4 @@ |
464 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
465 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
466 | This file is part of the GNU C Library. |
467 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
468 | |
469 | @@ -25,7 +25,8 @@ |
470 | double |
471 | jn (int n, double x) |
472 | { |
473 | - if (__builtin_expect (fabs (x) > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
474 | + if (__builtin_expect (isgreater (fabs (x), X_TLOSS), 0) |
475 | + && _LIB_VERSION != _IEEE_) |
476 | /* jn(n,|x|>X_TLOSS) */ |
477 | return __kernel_standard (n, x, 38); |
478 | |
479 | @@ -40,7 +41,8 @@ strong_alias (jn, jnl) |
480 | double |
481 | yn (int n, double x) |
482 | { |
483 | - if (__builtin_expect (x <= 0.0 || x > X_TLOSS, 0) && _LIB_VERSION != _IEEE_) |
484 | + if (__builtin_expect (islessequal (x, 0.0) || isgreater (x, X_TLOSS), 0) |
485 | + && _LIB_VERSION != _IEEE_) |
486 | { |
487 | if (x < 0.0) |
488 | { |
489 | diff --git a/math/w_jnf.c b/math/w_jnf.c |
490 | index ef29eb4..36d6f6d 100644 |
491 | --- a/math/w_jnf.c |
492 | +++ b/math/w_jnf.c |
493 | @@ -1,4 +1,4 @@ |
494 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
495 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
496 | This file is part of the GNU C Library. |
497 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
498 | |
499 | @@ -25,7 +25,7 @@ |
500 | float |
501 | jnf (int n, float x) |
502 | { |
503 | - if (__builtin_expect (fabsf (x) > (float) X_TLOSS, 0) |
504 | + if (__builtin_expect (isgreater (fabsf (x), (float) X_TLOSS), 0) |
505 | && _LIB_VERSION != _IEEE_) |
506 | /* jn(n,|x|>X_TLOSS) */ |
507 | return __kernel_standard_f (n, x, 138); |
508 | @@ -38,7 +38,8 @@ jnf (int n, float x) |
509 | float |
510 | ynf (int n, float x) |
511 | { |
512 | - if (__builtin_expect (x <= 0.0f || x > (float) X_TLOSS, 0) |
513 | + if (__builtin_expect (islessequal (x, 0.0f) |
514 | + || isgreater (x, (float) X_TLOSS), 0) |
515 | && _LIB_VERSION != _IEEE_) |
516 | { |
517 | if (x < 0.0f) |
518 | diff --git a/math/w_log.c b/math/w_log.c |
519 | index efc1c4c..ec33605 100644 |
520 | --- a/math/w_log.c |
521 | +++ b/math/w_log.c |
522 | @@ -1,4 +1,4 @@ |
523 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
524 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
525 | This file is part of the GNU C Library. |
526 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
527 | |
528 | @@ -25,7 +25,7 @@ |
529 | double |
530 | __log (double x) |
531 | { |
532 | - if (__builtin_expect (x <= 0.0, 0) && _LIB_VERSION != _IEEE_) |
533 | + if (__builtin_expect (islessequal (x, 0.0), 0) && _LIB_VERSION != _IEEE_) |
534 | { |
535 | if (x == 0.0) |
536 | { |
537 | diff --git a/math/w_log10.c b/math/w_log10.c |
538 | index 2717ade..fe799ad 100644 |
539 | --- a/math/w_log10.c |
540 | +++ b/math/w_log10.c |
541 | @@ -1,4 +1,4 @@ |
542 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
543 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
544 | This file is part of the GNU C Library. |
545 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
546 | |
547 | @@ -25,7 +25,7 @@ |
548 | double |
549 | __log10 (double x) |
550 | { |
551 | - if (__builtin_expect (x <= 0.0, 0) && _LIB_VERSION != _IEEE_) |
552 | + if (__builtin_expect (islessequal (x, 0.0), 0) && _LIB_VERSION != _IEEE_) |
553 | { |
554 | if (x == 0.0) |
555 | { |
556 | diff --git a/math/w_log10f.c b/math/w_log10f.c |
557 | index 60737ca..4b821f7 100644 |
558 | --- a/math/w_log10f.c |
559 | +++ b/math/w_log10f.c |
560 | @@ -1,4 +1,4 @@ |
561 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
562 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
563 | This file is part of the GNU C Library. |
564 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
565 | |
566 | @@ -25,7 +25,7 @@ |
567 | float |
568 | __log10f (float x) |
569 | { |
570 | - if (__builtin_expect (x <= 0.0f, 0) && _LIB_VERSION != _IEEE_) |
571 | + if (__builtin_expect (islessequal (x, 0.0f), 0) && _LIB_VERSION != _IEEE_) |
572 | { |
573 | if (x == 0.0f) |
574 | { |
575 | diff --git a/math/w_log10l.c b/math/w_log10l.c |
576 | index b26f18c..0e5a137 100644 |
577 | --- a/math/w_log10l.c |
578 | +++ b/math/w_log10l.c |
579 | @@ -1,4 +1,4 @@ |
580 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
581 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
582 | This file is part of the GNU C Library. |
583 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
584 | |
585 | @@ -25,7 +25,7 @@ |
586 | long double |
587 | __log10l (long double x) |
588 | { |
589 | - if (__builtin_expect (x <= 0.0L, 0) && _LIB_VERSION != _IEEE_) |
590 | + if (__builtin_expect (islessequal (x, 0.0L), 0) && _LIB_VERSION != _IEEE_) |
591 | { |
592 | if (x == 0.0L) |
593 | { |
594 | diff --git a/math/w_log2.c b/math/w_log2.c |
595 | index 998e5d9..e58e109 100644 |
596 | --- a/math/w_log2.c |
597 | +++ b/math/w_log2.c |
598 | @@ -1,4 +1,4 @@ |
599 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
600 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
601 | This file is part of the GNU C Library. |
602 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
603 | |
604 | @@ -25,7 +25,7 @@ |
605 | double |
606 | __log2 (double x) |
607 | { |
608 | - if (__builtin_expect (x <= 0.0, 0) && _LIB_VERSION != _IEEE_) |
609 | + if (__builtin_expect (islessequal (x, 0.0), 0) && _LIB_VERSION != _IEEE_) |
610 | { |
611 | if (x == 0.0) |
612 | { |
613 | diff --git a/math/w_log2f.c b/math/w_log2f.c |
614 | index 6d91bf4..6963ed2 100644 |
615 | --- a/math/w_log2f.c |
616 | +++ b/math/w_log2f.c |
617 | @@ -1,4 +1,4 @@ |
618 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
619 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
620 | This file is part of the GNU C Library. |
621 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
622 | |
623 | @@ -25,7 +25,7 @@ |
624 | float |
625 | __log2f (float x) |
626 | { |
627 | - if (__builtin_expect (x <= 0.0f, 0) && _LIB_VERSION != _IEEE_) |
628 | + if (__builtin_expect (islessequal (x, 0.0f), 0) && _LIB_VERSION != _IEEE_) |
629 | { |
630 | if (x == 0.0) |
631 | { |
632 | diff --git a/math/w_log2l.c b/math/w_log2l.c |
633 | index e51c1bc..eed04ff6c 100644 |
634 | --- a/math/w_log2l.c |
635 | +++ b/math/w_log2l.c |
636 | @@ -1,4 +1,4 @@ |
637 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
638 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
639 | This file is part of the GNU C Library. |
640 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
641 | |
642 | @@ -25,7 +25,7 @@ |
643 | long double |
644 | __log2l (long double x) |
645 | { |
646 | - if (__builtin_expect (x <= 0.0L, 0) && _LIB_VERSION != _IEEE_) |
647 | + if (__builtin_expect (islessequal (x, 0.0L), 0) && _LIB_VERSION != _IEEE_) |
648 | { |
649 | if (x == 0.0L) |
650 | { |
651 | diff --git a/math/w_logf.c b/math/w_logf.c |
652 | index 8aa27c8..38d408f 100644 |
653 | --- a/math/w_logf.c |
654 | +++ b/math/w_logf.c |
655 | @@ -1,4 +1,4 @@ |
656 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
657 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
658 | This file is part of the GNU C Library. |
659 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
660 | |
661 | @@ -25,7 +25,7 @@ |
662 | float |
663 | __logf (float x) |
664 | { |
665 | - if (__builtin_expect (x <= 0.0f, 0) && _LIB_VERSION != _IEEE_) |
666 | + if (__builtin_expect (islessequal (x, 0.0f), 0) && _LIB_VERSION != _IEEE_) |
667 | { |
668 | if (x == 0.0f) |
669 | { |
670 | diff --git a/math/w_logl.c b/math/w_logl.c |
671 | index a3139ff..593b37d 100644 |
672 | --- a/math/w_logl.c |
673 | +++ b/math/w_logl.c |
674 | @@ -1,4 +1,4 @@ |
675 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
676 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
677 | This file is part of the GNU C Library. |
678 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
679 | |
680 | @@ -25,7 +25,7 @@ |
681 | long double |
682 | __logl (long double x) |
683 | { |
684 | - if (__builtin_expect (x <= 0.0L, 0) && _LIB_VERSION != _IEEE_) |
685 | + if (__builtin_expect (islessequal (x, 0.0L), 0) && _LIB_VERSION != _IEEE_) |
686 | { |
687 | if (x == 0.0L) |
688 | { |
689 | diff --git a/math/w_sqrt.c b/math/w_sqrt.c |
690 | index 409a6df..f6ba542 100644 |
691 | --- a/math/w_sqrt.c |
692 | +++ b/math/w_sqrt.c |
693 | @@ -1,4 +1,4 @@ |
694 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
695 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
696 | This file is part of the GNU C Library. |
697 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
698 | |
699 | @@ -24,7 +24,7 @@ |
700 | double |
701 | __sqrt (double x) |
702 | { |
703 | - if (__builtin_expect (x < 0.0, 0) && _LIB_VERSION != _IEEE_) |
704 | + if (__builtin_expect (isless (x, 0.0), 0) && _LIB_VERSION != _IEEE_) |
705 | return __kernel_standard (x, x, 26); /* sqrt(negative) */ |
706 | |
707 | return __ieee754_sqrt (x); |
708 | diff --git a/math/w_sqrtf.c b/math/w_sqrtf.c |
709 | index 3c3d2f8..c128e9b 100644 |
710 | --- a/math/w_sqrtf.c |
711 | +++ b/math/w_sqrtf.c |
712 | @@ -1,4 +1,4 @@ |
713 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
714 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
715 | This file is part of the GNU C Library. |
716 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
717 | |
718 | @@ -24,7 +24,7 @@ |
719 | float |
720 | __sqrtf (float x) |
721 | { |
722 | - if (__builtin_expect (x < 0.0f, 0) && _LIB_VERSION != _IEEE_) |
723 | + if (__builtin_expect (isless (x, 0.0f), 0) && _LIB_VERSION != _IEEE_) |
724 | return __kernel_standard_f (x, x, 126); /* sqrt(negative) */ |
725 | |
726 | return __ieee754_sqrtf (x); |
727 | diff --git a/math/w_sqrtl.c b/math/w_sqrtl.c |
728 | index 5e18f44..2a4a048 100644 |
729 | --- a/math/w_sqrtl.c |
730 | +++ b/math/w_sqrtl.c |
731 | @@ -1,4 +1,4 @@ |
732 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
733 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
734 | This file is part of the GNU C Library. |
735 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
736 | |
737 | @@ -24,7 +24,7 @@ |
738 | long double |
739 | __sqrtl (long double x) |
740 | { |
741 | - if (__builtin_expect (x < 0.0L, 0) && _LIB_VERSION != _IEEE_) |
742 | + if (__builtin_expect (isless (x, 0.0L), 0) && _LIB_VERSION != _IEEE_) |
743 | return __kernel_standard (x, x, 226); /* sqrt(negative) */ |
744 | |
745 | return __ieee754_sqrtl (x); |
746 | diff --git a/sysdeps/ieee754/dbl-64/e_atanh.c b/sysdeps/ieee754/dbl-64/e_atanh.c |
747 | index 9fc21ab..5f471b1 100644 |
748 | --- a/sysdeps/ieee754/dbl-64/e_atanh.c |
749 | +++ b/sysdeps/ieee754/dbl-64/e_atanh.c |
750 | @@ -1,4 +1,4 @@ |
751 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
752 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
753 | This file is part of the GNU C Library. |
754 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
755 | |
756 | @@ -46,7 +46,7 @@ __ieee754_atanh (double x) |
757 | { |
758 | double xa = fabs (x); |
759 | double t; |
760 | - if (xa < 0.5) |
761 | + if (isless (xa, 0.5)) |
762 | { |
763 | if (__builtin_expect (xa < 0x1.0p-28, 0)) |
764 | { |
765 | @@ -57,11 +57,11 @@ __ieee754_atanh (double x) |
766 | t = xa + xa; |
767 | t = 0.5 * __log1p (t + t * xa / (1.0 - xa)); |
768 | } |
769 | - else if (__builtin_expect (xa < 1.0, 1)) |
770 | + else if (__builtin_expect (isless (xa, 1.0), 1)) |
771 | t = 0.5 * __log1p ((xa + xa) / (1.0 - xa)); |
772 | else |
773 | { |
774 | - if (xa > 1.0) |
775 | + if (isgreater (xa, 1.0)) |
776 | return (x - x) / (x - x); |
777 | |
778 | return x / 0.0; |
779 | diff --git a/sysdeps/ieee754/dbl-64/w_exp.c b/sysdeps/ieee754/dbl-64/w_exp.c |
780 | index ee42587..b584ed8 100644 |
781 | --- a/sysdeps/ieee754/dbl-64/w_exp.c |
782 | +++ b/sysdeps/ieee754/dbl-64/w_exp.c |
783 | @@ -1,4 +1,4 @@ |
784 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
785 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
786 | This file is part of the GNU C Library. |
787 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
788 | |
789 | @@ -28,12 +28,12 @@ u_threshold= -7.45133219101941108420e+02; /* 0xc0874910, 0xD52D3051 */ |
790 | double |
791 | __exp (double x) |
792 | { |
793 | - if (__builtin_expect (x > o_threshold, 0)) |
794 | + if (__builtin_expect (isgreater (x, o_threshold), 0)) |
795 | { |
796 | if (_LIB_VERSION != _IEEE_) |
797 | return __kernel_standard_f (x, x, 6); |
798 | } |
799 | - else if (__builtin_expect (x < u_threshold, 0)) |
800 | + else if (__builtin_expect (isless (x, u_threshold), 0)) |
801 | { |
802 | if (_LIB_VERSION != _IEEE_) |
803 | return __kernel_standard_f (x, x, 7); |
804 | diff --git a/sysdeps/ieee754/flt-32/e_atanhf.c b/sysdeps/ieee754/flt-32/e_atanhf.c |
805 | index 75ed691..7af2f6c 100644 |
806 | --- a/sysdeps/ieee754/flt-32/e_atanhf.c |
807 | +++ b/sysdeps/ieee754/flt-32/e_atanhf.c |
808 | @@ -1,4 +1,4 @@ |
809 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
810 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
811 | This file is part of the GNU C Library. |
812 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
813 | |
814 | @@ -46,7 +46,7 @@ __ieee754_atanhf (float x) |
815 | { |
816 | float xa = fabsf (x); |
817 | float t; |
818 | - if (xa < 0.5f) |
819 | + if (isless (xa, 0.5f)) |
820 | { |
821 | if (__builtin_expect (xa < 0x1.0p-28f, 0)) |
822 | { |
823 | @@ -57,11 +57,11 @@ __ieee754_atanhf (float x) |
824 | t = xa + xa; |
825 | t = 0.5f * __log1pf (t + t * xa / (1.0f - xa)); |
826 | } |
827 | - else if (__builtin_expect (xa < 1.0f, 1)) |
828 | + else if (__builtin_expect (isless (xa, 1.0f), 1)) |
829 | t = 0.5f * __log1pf ((xa + xa) / (1.0f - xa)); |
830 | else |
831 | { |
832 | - if (xa > 1.0f) |
833 | + if (isgreater (xa, 1.0f)) |
834 | return (x - x) / (x - x); |
835 | |
836 | return x / 0.0f; |
837 | diff --git a/sysdeps/ieee754/flt-32/w_expf.c b/sysdeps/ieee754/flt-32/w_expf.c |
838 | index 5500872..bc3b2f6 100644 |
839 | --- a/sysdeps/ieee754/flt-32/w_expf.c |
840 | +++ b/sysdeps/ieee754/flt-32/w_expf.c |
841 | @@ -1,4 +1,4 @@ |
842 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
843 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
844 | This file is part of the GNU C Library. |
845 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
846 | |
847 | @@ -28,12 +28,12 @@ u_threshold= -1.0397208405e+02; /* 0xc2cff1b5 */ |
848 | float |
849 | __expf (float x) |
850 | { |
851 | - if (__builtin_expect (x > o_threshold, 0)) |
852 | + if (__builtin_expect (isgreater (x, o_threshold), 0)) |
853 | { |
854 | if (_LIB_VERSION != _IEEE_) |
855 | return __kernel_standard_f (x, x, 106); |
856 | } |
857 | - else if (__builtin_expect (x < u_threshold, 0)) |
858 | + else if (__builtin_expect (isless (x, u_threshold), 0)) |
859 | { |
860 | if (_LIB_VERSION != _IEEE_) |
861 | return __kernel_standard_f (x, x, 107); |
862 | diff --git a/sysdeps/ieee754/ldbl-96/w_expl.c b/sysdeps/ieee754/ldbl-96/w_expl.c |
863 | index ec9d8a7..d61c0a3 100644 |
864 | --- a/sysdeps/ieee754/ldbl-96/w_expl.c |
865 | +++ b/sysdeps/ieee754/ldbl-96/w_expl.c |
866 | @@ -1,4 +1,4 @@ |
867 | -/* Copyright (C) 2011 Free Software Foundation, Inc. |
868 | +/* Copyright (C) 2011, 2012 Free Software Foundation, Inc. |
869 | This file is part of the GNU C Library. |
870 | Contributed by Ulrich Drepper <drepper@gmail.com>, 2011. |
871 | |
872 | @@ -30,12 +30,12 @@ u_threshold= -1.140019167866942050398521670162263001513e4; |
873 | long double |
874 | __expl (long double x) |
875 | { |
876 | - if (__builtin_expect (x > o_threshold, 0)) |
877 | + if (__builtin_expect (isgreater (x, o_threshold), 0)) |
878 | { |
879 | if (_LIB_VERSION != _IEEE_) |
880 | return __kernel_standard (x, x, 206); |
881 | } |
882 | - else if (__builtin_expect (x < u_threshold, 0)) |
883 | + else if (__builtin_expect (isless (x, u_threshold), 0)) |
884 | { |
885 | if (_LIB_VERSION != _IEEE_) |
886 | return __kernel_standard (x, x, 207); |