| Commit | Line | Data |
|---|---|---|
| b34b60bc JS |
1 | /* |
| 2 | * Written by J.T. Conklin <jtc@NetBSD.org>. | |
| 3 | * Public domain. | |
| 4 | * | |
| 5 | * $NetBSD: s_finitef.S,v 1.6 2003/07/26 19:25:01 salo Exp $ | |
| b34b60bc JS |
6 | */ |
| 7 | ||
| 8 | #include <machine/asm.h> | |
| 9 | ||
| 10 | ENTRY(finitef) | |
| 11 | #ifdef __i386__ | |
| 12 | movl 4(%esp),%eax | |
| 13 | andl $0x7f800000, %eax | |
| 14 | cmpl $0x7f800000, %eax | |
| 15 | setne %al | |
| 16 | andl $0x000000ff, %eax | |
| 17 | #else | |
| 18 | xorl %eax,%eax | |
| 19 | movl $0x7ff00000,%esi | |
| 20 | movss %xmm0,-4(%rsp) | |
| 21 | andl -4(%rsp),%esi | |
| 22 | cmpl $0x7ff00000,%esi | |
| 23 | setne %al | |
| 24 | #endif | |
| 25 | ret | |
| d04e8698 | 26 | END(finitef) |
| 70e34eb2 JM |
27 | |
| 28 | .section .note.GNU-stack,"",%progbits |