rename amd64 architecture to x86_64
[dragonfly.git] / lib / libc / x86_64 / gen / fpgetmask.S
CommitLineData
05ecdcef
SS
1/*
2 * Written by J.T. Conklin, Apr 4, 1995
3 * Public domain.
4 *
5 * $NetBSD: fpgetmask.S,v 1.3 2002/06/12 19:17:22 fvdl Exp $
05ecdcef
SS
6 */
7
8#include <machine/asm.h>
9
10/*
11 * XXX only read x87 control word here. If an application only
12 * uses the fp* interface to manipulate FP bits, it should
13 * always remain in sync with the SSE mxcsr register.
14 */
15
16#ifdef WEAK_ALIAS
17WEAK_ALIAS(fpgetmask, _fpgetmask)
18ENTRY(_fpgetmask)
19#else
20ENTRY(fpgetmask)
21#endif
22 fnstcw -4(%rsp)
23 movl -4(%rsp),%eax
24 notl %eax
25 andl $63,%eax
26 ret