40 #ifdef POK_NEEDS_LIBMATH
44 #include "math_private.h"
47 one = 1.00000000000000000000e+00,
48 ln2 = 6.93147180559945286227e-01,
49 huge= 1.00000000000000000000e+300;
58 if(ix>=0x7ff00000)
return x+x;
60 if(huge+x>one)
return x;
63 w = __ieee754_log(fabs(x))+ln2;
64 }
else if (ix>0x40000000) {
66 w = __ieee754_log(2.0*t+one/(__ieee754_sqrt(x*x+one)+t));
69 w =log1p(fabs(x)+t/(one+__ieee754_sqrt(one+t)));
71 if(hx>0)
return w;
else return -w;