add SPE FPU support to powerpc-sf
[musl.git] / src / fenv / fesetround.c
blob4e2f164dd5e12d1d866d88e9203c1c1d76f969f6
1 #include <fenv.h>
2 #include <features.h>
4 /* __fesetround wrapper for arch independent argument check */
6 hidden int __fesetround(int);
8 int fesetround(int r)
10 if (r != FE_TONEAREST
11 #ifdef FE_DOWNWARD
12 && r != FE_DOWNWARD
13 #endif
14 #ifdef FE_UPWARD
15 && r != FE_UPWARD
16 #endif
17 #ifdef FE_TOWARDZERO
18 && r != FE_TOWARDZERO
19 #endif
21 return -1;
22 return __fesetround(r);