1 /*
2 Copyright (C) 1998, 2002 by Red Hat Inc. All rights reserved.
3 
4 Permission to use, copy, modify, and distribute this
5 software is freely granted, provided that this notice
6 is preserved.
7  */
8 #ifndef __F_MATH_H__
9 #define __F_MATH_H__
10 
11 #include <_ansi.h>
12 #include "fdlibm.h"
13 
14 __inline__
15 static
16 int
check_finite(double x)17 check_finite (double x)
18 {
19   __int32_t hx;
20   GET_HIGH_WORD(hx,x);
21   return  (int)((__uint32_t)((hx&0x7fffffff)-0x7ff00000)>>31);
22 }
23 
24 __inline__
25 static
26 int
check_finitef(float x)27 check_finitef (float x)
28 {
29   __int32_t ix;
30   GET_FLOAT_WORD(ix,x);
31   return  (int)((__uint32_t)((ix&0x7fffffff)-0x7f800000)>>31);
32 }
33 
34 #endif /* __F_MATH_H__ */
35