mailing list of musl libc
 help / color / mirror / code / Atom feed
* Various fixes for ancient typos in Sun fdlibm comments
@ 2018-07-28  2:51 CM Graff
  0 siblings, 0 replies; only message in thread
From: CM Graff @ 2018-07-28  2:51 UTC (permalink / raw)
  To: musl

[-- Attachment #1: Type: text/plain, Size: 106 bytes --]

Hello,
Here is a patch that fixes some typographical errors in the comments
of the Sun fdlibm code.
Graff

[-- Attachment #2: ancient_typos.patch --]
[-- Type: text/x-patch, Size: 3194 bytes --]

From 84b0162882783114ebc67d060b7c7a8224a227c6 Mon Sep 17 00:00:00 2001
From: cmgraff <cm0graff@gmail.com>
Date: Fri, 27 Jul 2018 21:43:01 -0500
Subject: [PATCH] Fix various ancient typos in Sun fdlibm's comments.

---
 src/math/__rem_pio2_large.c | 4 ++--
 src/math/cbrt.c             | 2 +-
 src/math/pow.c              | 2 +-
 src/math/powl.c             | 2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/math/__rem_pio2_large.c b/src/math/__rem_pio2_large.c
index 958f28c..f712268 100644
--- a/src/math/__rem_pio2_large.c
+++ b/src/math/__rem_pio2_large.c
@@ -47,7 +47,7 @@
  *                      64-bit  precision       2
  *                      113-bit precision       3
  *              The actual value is the sum of them. Thus for 113-bit
- *              precison, one may have to do something like:
+ *              precision, one may have to do something like:
  *
  *              long double t,w,r_head, r_tail;
  *              t = (long double)y[2] + (long double)y[1];
@@ -78,7 +78,7 @@
  *              jk+1 must be 2 larger than you might expect so that our
  *              recomputation test works. (Up to 24 bits in the integer
  *              part (the 24 bits of it that we compute) and 23 bits in
- *              the fraction part may be lost to cancelation before we
+ *              the fraction part may be lost to cancellation before we
  *              recompute.)
  *
  *      jz      local integer variable indicating the number of
diff --git a/src/math/cbrt.c b/src/math/cbrt.c
index 7599d3e..b51da62 100644
--- a/src/math/cbrt.c
+++ b/src/math/cbrt.c
@@ -48,7 +48,7 @@ double cbrt(double x)
 	 * error of about 1 in 16.  Adding a bias of -0.03306235651 to the
 	 * (e%3+m)/3 term reduces the error to about 1 in 32. With the IEEE
 	 * floating point representation, for finite positive normal values,
-	 * ordinary integer divison of the value in bits magically gives
+	 * ordinary integer division of the value in bits magically gives
 	 * almost exactly the RHS of the above provided we first subtract the
 	 * exponent bias (1023 for doubles) and later add it back.  We do the
 	 * subtraction virtually to keep e >= 0 so that ordinary integer
diff --git a/src/math/pow.c b/src/math/pow.c
index 3ddc1b6..ab5d573 100644
--- a/src/math/pow.c
+++ b/src/math/pow.c
@@ -15,7 +15,7 @@
  *      1. Compute and return log2(x) in two pieces:
  *              log2(x) = w1 + w2,
  *         where w1 has 53-24 = 29 bit trailing zeros.
- *      2. Perform y*log2(x) = n+y' by simulating muti-precision
+ *      2. Perform y*log2(x) = n+y' by simulating multi-precision
  *         arithmetic, where |y'|<=0.5.
  *      3. Return x**y = 2**n*exp(y'*log2)
  *
diff --git a/src/math/powl.c b/src/math/powl.c
index 5b6da07..e4595d5 100644
--- a/src/math/powl.c
+++ b/src/math/powl.c
@@ -199,7 +199,7 @@ long double powl(long double x, long double y)
 	volatile long double z=0;
 	long double w=0, W=0, Wa=0, Wb=0, ya=0, yb=0, u=0;
 
-	/* make sure no invalid exception is raised by nan comparision */
+	/* make sure no invalid exception is raised by nan comparison */
 	if (isnan(x)) {
 		if (!isnan(y) && y == 0.0)
 			return 1.0;
-- 
2.7.4


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2018-07-28  2:51 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-28  2:51 Various fixes for ancient typos in Sun fdlibm comments CM Graff

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).