summaryrefslogtreecommitdiff
path: root/math/R/patches/patch-ae
diff options
context:
space:
mode:
Diffstat (limited to 'math/R/patches/patch-ae')
-rw-r--r--math/R/patches/patch-ae24
1 files changed, 24 insertions, 0 deletions
diff --git a/math/R/patches/patch-ae b/math/R/patches/patch-ae
new file mode 100644
index 00000000000..2be9e1bc9c4
--- /dev/null
+++ b/math/R/patches/patch-ae
@@ -0,0 +1,24 @@
+$NetBSD: patch-ae,v 1.13 2006/02/26 11:58:25 markd Exp $
+
+--- src/nmath/log1p.c.orig 2005-12-06 12:00:17.000000000 +1300
++++ src/nmath/log1p.c
+@@ -98,16 +98,18 @@ double log1p(double x)
+ -.33410026677731010351377066666666e-30,
+ +.63533936180236187354180266666666e-31,
+ };
+- const static double xmin = -1 + sqrt(DBL_EPSILON);/*was sqrt(d1mach(4)); */
+
+ #ifdef NOMORE_FOR_THREADS
+ static int nlnrel = 0;
++ static double xmin = 0.0;
+
++ if (xmin == 0.0) xmin = -1 + sqrt(DBL_EPSILON);/*was sqrt(d1mach(4)); */
+ if (nlnrel == 0) {/* initialize chebychev coefficients */
+ nlnrel = chebyshev_init(alnrcs, 43, DBL_EPSILON/20);/*was .1*d1mach(3)*/
+ }
+ #else
+ # define nlnrel 22
++ const static double xmin = -0.999999985;
+ /* 22: for IEEE double precision where DBL_EPSILON = 2.22044604925031e-16 */
+ #endif
+