xref: /inferno-os/emu/MacOSX/asm-386.s (revision 6e425a9de8c003b5a733621a6b6730ec3cc902b8)
1/*
2 * these are the same as on the PC (eg, Linux)
3*/
4
5	.globl	_FPsave
6_FPsave:
7	pushl	%ebp
8	movl	%esp, %ebp
9	movl	8(%ebp), %eax
10	fstenv	(%eax)
11	popl	%ebp
12	ret
13
14	.globl	_FPrestore
15_FPrestore:
16	pushl	%ebp
17	movl	%esp, %ebp
18	movl	8(%ebp), %eax
19	fldenv	(%eax)
20	popl	%ebp
21	ret
22
23	.globl	__tas
24__tas:
25	movl	$1, %eax
26	movl	4(%esp), %ecx
27	xchgl	%eax, 0(%ecx)
28	ret
29