diff options
Diffstat (limited to 'sysdeps/ieee754/ldbl-128/s_log1pl.c')
-rw-r--r-- | sysdeps/ieee754/ldbl-128/s_log1pl.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c index 4ecea0fddd..fad18e9da2 100644 --- a/sysdeps/ieee754/ldbl-128/s_log1pl.c +++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c @@ -138,6 +138,12 @@ __log1pl (long double xm1) && (u.parts32.w1 | u.parts32.w2 | u.parts32.w3) == 0) return xm1; + if ((hx & 0x7fffffff) < 0x3f8e0000) + { + if ((int) xm1 == 0) + return xm1; + } + x = xm1 + 1.0L; /* log1p(-1) = -inf */ |