+#define isinf(x) ( \
+ sizeof(x) == sizeof(float) ? (__FLOAT_BITS(x) & 0x7fffffff) == 0x7f800000 : \
+ sizeof(x) == sizeof(double) ? (__DOUBLE_BITS(x) & (__uint64_t)-1>>1) == (__uint64_t)0x7ff<<52 : \
+ __fpclassifyl(x) == FP_INFINITE)
+
+#define isnan(x) ( \
+ sizeof(x) == sizeof(float) ? (__FLOAT_BITS(x) & 0x7fffffff) > 0x7f800000 : \
+ sizeof(x) == sizeof(double) ? (__DOUBLE_BITS(x) & (__uint64_t)-1>>1) > (__uint64_t)0x7ff<<52 : \
+ __fpclassifyl(x) == FP_NAN)
+
+#define isnormal(x) ( \
+ sizeof(x) == sizeof(float) ? ((__FLOAT_BITS(x)+0x00800000) & 0x7fffffff) >= 0x01000000 : \
+ sizeof(x) == sizeof(double) ? ((__DOUBLE_BITS(x)+((__uint64_t)1<<52)) & (__uint64_t)-1>>1) >= (__uint64_t)1<<53 : \
+ __fpclassifyl(x) == FP_NORMAL)
+
+#define isfinite(x) ( \
+ sizeof(x) == sizeof(float) ? (__FLOAT_BITS(x) & 0x7fffffff) < 0x7f800000 : \
+ sizeof(x) == sizeof(double) ? (__DOUBLE_BITS(x) & (__uint64_t)-1>>1) < (__uint64_t)0x7ff<<52 : \
+ __fpclassifyl(x) > FP_INFINITE)
+
+int __signbit(double);
+int __signbitf(float);
+int __signbitl(long double);
+
+#define signbit(x) ( \
+ sizeof(x) == sizeof(float) ? (int)(__FLOAT_BITS(x)>>31) : \
+ sizeof(x) == sizeof(double) ? (int)(__DOUBLE_BITS(x)>>63) : \
+ __signbitl(x) )
+
+#define isunordered(x,y) (isnan((x)) ? ((void)(y),1) : isnan((y)))
+
+#if __STDC_VERSION__ >= 199901L
+inline
+#endif
+static int __isrel(long double __x, long double __y, int __rel)
+{
+ if (isunordered(__x, __y)) return 0;
+ if (__rel==-2) return __x < __y;
+ if (__rel==2) return __x > __y;
+ if (__rel==-1) return __x <= __y;
+ if (__rel==1) return __x >= __y;
+ return __x != __y;
+}
+
+#define isless(x,y) __isrel((x), (y), -2)
+#define islessequal(x,y) __isrel((x), (y), -1)
+#define islessgreater(x,y) __isrel((x), (y), 0)
+#define isgreaterequal(x,y) __isrel((x), (y), 1)
+#define isgreater(x,y) __isrel((x), (y), 2)