/* $NetBSD: fpgetround.c,v 1.4 2005/06/12 05:21:26 lukem Exp $ */ /* * Written by J.T. Conklin, Apr 11, 1995 * Public domain. */ #include #if defined(LIBC_SCCS) && !defined(lint) __RCSID("$NetBSD: fpgetround.c,v 1.4 2005/06/12 05:21:26 lukem Exp $"); #endif /* LIBC_SCCS and not lint */ #include "namespace.h" #include #ifdef __weak_alias __weak_alias(fpgetround,_fpgetround) #endif fp_rnd fpgetround() { int x; __asm__("cfc1 %0,$31" : "=r" (x)); return x & 0x03; }