xref: /netbsd-src/lib/libc/arch/i386/gen/fpgetround.S (revision 76dfffe33547c37f8bdd446e3e4ab0f3c16cea4b)
1/*
2 * Written by J.T. Conklin, Apr 4, 1995
3 * Public domain.
4 */
5
6#include <machine/asm.h>
7
8ENTRY(fpgetround)
9	subl $4,%esp
10	fnstcw (%esp)
11	movl (%esp),%eax
12	rorl $10,%eax
13	andl $3,%eax
14	addl $4,%esp
15	ret
16