xref: /netbsd-src/lib/libm/arch/i387/s_log1p.S (revision 17dd36da8292193180754d5047c0926dbb56818c)
1/*
2 * Written by J.T. Conklin <jtc@netbsd.org>.
3 * Public domain.
4 */
5
6#include <machine/asm.h>
7
8RCSID("$NetBSD: s_log1p.S,v 1.8 1999/07/02 15:37:34 simonb Exp $")
9
10/*
11 * Since the fyl2xp1 instruction has such a limited range:
12 *	-(1 - (sqrt(2) / 2)) <= x <= sqrt(2) - 1
13 * it's not worth trying to use it.
14 */
15
16ENTRY(log1p)
17	fldln2
18	fldl 4(%esp)
19	fld1
20	faddp
21	fyl2x
22	ret
23