aboutsummaryrefslogtreecommitdiff
path: root/math/s_clogf.c
diff options
context:
space:
mode:
Diffstat (limited to 'math/s_clogf.c')
-rw-r--r--math/s_clogf.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/math/s_clogf.c b/math/s_clogf.c
index 92f782c47b..2b9038b411 100644
--- a/math/s_clogf.c
+++ b/math/s_clogf.c
@@ -85,6 +85,19 @@ __clogf (__complex__ float x)
d2m1 += absy * absy;
__real__ result = __log1pf (d2m1) / 2.0f;
}
+ else if (absx < 1.0f
+ && absx >= 0.75f
+ && absy < FLT_EPSILON / 2.0f
+ && scale == 0)
+ {
+ float d2m1 = (absx - 1.0f) * (absx + 1.0f);
+ __real__ result = __log1pf (d2m1) / 2.0f;
+ }
+ else if (absx < 1.0f && (absx >= 0.75f || absy >= 0.5f) && scale == 0)
+ {
+ float d2m1 = __x2y2m1f (absx, absy);
+ __real__ result = __log1pf (d2m1) / 2.0f;
+ }
else
{
float d = __ieee754_hypotf (absx, absy);