diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2000-06-06 18:03:13 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2000-06-06 18:03:13 +0000 |
commit | 10ce8995f7e30f37ff40fc34979f5cd02328a1aa (patch) | |
tree | de92c2fdc7ffad556f18756faa9a042f2d4aadf3 /lib/libm/arch/i387/s_ceilf.S | |
parent | 3f73c5e38cd581435818ee9ebdb527c7687c6bc3 (diff) |
2nd patch for stack mishandling; wd@ics.nara-wu.ac.jp
Diffstat (limited to 'lib/libm/arch/i387/s_ceilf.S')
-rw-r--r-- | lib/libm/arch/i387/s_ceilf.S | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/lib/libm/arch/i387/s_ceilf.S b/lib/libm/arch/i387/s_ceilf.S index 253f4fc6933..4836bd94753 100644 --- a/lib/libm/arch/i387/s_ceilf.S +++ b/lib/libm/arch/i387/s_ceilf.S @@ -8,21 +8,19 @@ RCSID("$NetBSD: s_ceilf.S,v 1.3 1995/05/08 23:52:44 jtc Exp $") ENTRY(ceilf) - pushl %ebp - movl %esp,%ebp subl $8,%esp - fstcw -12(%ebp) /* store fpu control word */ - movw -12(%ebp),%dx + fstcw 4(%esp) /* store fpu control word */ + movw 4(%esp),%dx orw $0x0800,%dx /* round towards +oo */ andw $0xfbff,%dx - movw %dx,-16(%ebp) - fldcw -16(%ebp) /* load modfied control word */ + movw %dx,(%esp) + fldcw (%esp) /* load modfied control word */ - flds 8(%ebp); /* round */ + flds 12(%esp); /* round */ frndint - fldcw -12(%ebp) /* restore original control word */ + fldcw 4(%esp) /* restore original control word */ - leave + addl $8,%esp ret |