xref: /netbsd/lib/libc/arch/x86_64/gen/fpgetmask.S (revision bf9ec67e)
1/*	$NetBSD: fpgetmask.S,v 1.2 2002/01/13 21:45:51 thorpej Exp $	*/
2
3/*
4 * Written by J.T. Conklin, Apr 4, 1995
5 * Public domain.
6 */
7
8#include <machine/asm.h>
9
10#ifdef WEAK_ALIAS
11WEAK_ALIAS(fpgetmask, _fpgetmask)
12ENTRY(_fpgetmask)
13#else
14ENTRY(fpgetmask)
15#endif
16	fnstcw -4(%rsp)
17	movl -4(%rsp),%eax
18	notl %eax
19	andl $63,%eax
20	ret
21