1 /* 2 * Written by J.T. Conklin, Apr 10, 1995 3 * Public domain. 4 */ 5 6 #include <ieeefp.h> 7 8 fp_rnd 9 fpgetround() 10 { 11 int x; 12 13 __asm__("st %%fsr,%0" : "=m" (*&x)); 14 return (x >> 30) & 0x03; 15 } 16