Initial import of binutils 2.22 on the new vendor branch
[dragonfly.git] / lib / libc / i386 / gen / fpgetmask.S
1 /*
2  * Written by J.T. Conklin, Apr 4, 1995
3  * Public domain.
4  *
5  * $NetBSD: fpgetmask.S,v 1.4 2002/01/13 21:45:42 thorpej Exp $
6  * $DragonFly: src/lib/libc/i386/gen/fpgetmask.S,v 1.1 2005/07/26 21:15:19 joerg Exp $
7  */
8
9 #include <machine/asm.h>
10
11 #ifdef WEAK_ALIAS
12 WEAK_ALIAS(fpgetmask, _fpgetmask)
13 ENTRY(_fpgetmask)
14 #else
15 ENTRY(fpgetmask)
16 #endif
17         subl $4,%esp
18         fnstcw (%esp)
19         movl (%esp),%eax
20         notl %eax
21         andl $63,%eax
22         addl $4,%esp
23         ret