Try to use the "proximity" (~) operator consistently in comments

(x ~<= a, not x <= ~a).  This got messed up in some places when the
comments were moved from e_rem_pio2f.c.

Added my (non-)copyright.
This commit is contained in:
Bruce Evans 2005-11-28 05:46:13 +00:00
parent 960d3da0f0
commit 35ae347641
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=152871
2 changed files with 10 additions and 8 deletions

View file

@ -1,5 +1,6 @@
/* s_cosf.c -- float version of s_cos.c.
* Conversion to float by Ian Lance Taylor, Cygnus Support, ian@cygnus.com.
* Optimized by Bruce D. Evans.
*/
/*
@ -45,14 +46,14 @@ cosf(float x)
if(((int)x)==0) return 1.0; /* 1 with inexact if x != 0 */
return __kernel_cosdf(x);
}
if(ix<=0x407b53d1) { /* |x| <= ~5*pi/4 */
if(ix<=0x4016cbe3) /* |x| <= ~3pi/4 */
if(ix<=0x407b53d1) { /* |x| ~<= 5*pi/4 */
if(ix<=0x4016cbe3) /* |x| ~<= 3pi/4 */
return -__kernel_sindf(x - c1pio2);
else
return -__kernel_cosdf(x - c2pio2);
}
if(ix<=0x40e231d5) { /* |x| <= ~9*pi/4 */
if(ix<=0x40afeddf) /* |x| <= ~7*pi/4 */
if(ix<=0x40e231d5) { /* |x| ~<= 9*pi/4 */
if(ix<=0x40afeddf) /* |x| ~<= 7*pi/4 */
return __kernel_sindf(x - c3pio2);
else
return __kernel_cosdf(x - c4pio2);

View file

@ -1,5 +1,6 @@
/* s_sinf.c -- float version of s_sin.c.
* Conversion to float by Ian Lance Taylor, Cygnus Support, ian@cygnus.com.
* Optimized by Bruce D. Evans.
*/
/*
@ -45,8 +46,8 @@ sinf(float x)
if(((int)x)==0) return x; /* x with inexact if x != 0 */
return __kernel_sindf(x);
}
if(ix<=0x407b53d1) { /* |x| <= ~5*pi/4 */
if(ix<=0x4016cbe3) { /* |x| <= ~3pi/4 */
if(ix<=0x407b53d1) { /* |x| ~<= 5*pi/4 */
if(ix<=0x4016cbe3) { /* |x| ~<= 3pi/4 */
if(hx>0)
return __kernel_cosdf(x - s1pio2);
else
@ -54,8 +55,8 @@ sinf(float x)
} else
return -__kernel_sindf(x + (hx > 0 ? -s2pio2 : s2pio2));
}
if(ix<=0x40e231d5) { /* |x| <= ~9*pi/4 */
if(ix<=0x40afeddf) { /* |x| <= ~7*pi/4 */
if(ix<=0x40e231d5) { /* |x| ~<= 9*pi/4 */
if(ix<=0x40afeddf) { /* |x| ~<= 7*pi/4 */
if(hx>0)
return -__kernel_cosdf(x - s3pio2);
else