1 /* Copyright (C) 2002 by Red Hat, Incorporated. All rights reserved.
2 *
3 * Permission to use, copy, modify, and distribute this software
4 * is freely granted, provided that this notice is preserved.
5 */
6
7 #include "fdlibm.h"
8
9 /*
10 * On the SPU, single precision floating point returns only FP_NORMAL and
11 * FP_ZERO, since FP_NAN, FP_INFINITE, and FP_SUBNORMAL are not
12 * supported, base on the common f_fpclassify.c.
13 */
14 int
__fpclassifyf(float x)15 __fpclassifyf (float x)
16 {
17 __uint32_t w;
18
19 GET_FLOAT_WORD(w,x);
20
21 if (w == 0x00000000 || w == 0x80000000)
22 return FP_ZERO;
23 return FP_NORMAL;
24 }
25