summaryrefslogtreecommitdiffstats
path: root/libm/src/e_j1f.c
diff options
context:
space:
mode:
authorJean-Baptiste Queru <jbq@google.com>2010-05-11 10:43:56 -0700
committerAndroid Code Review <code-review@android.com>2010-05-11 10:43:56 -0700
commitc3581dc78a51180d3550d0d04596657cb2db852c (patch)
tree16afa49179291157e58d2bf380b673348248aa1a /libm/src/e_j1f.c
parent7911e057a5ff835157d253d13e24c2cd9a26e935 (diff)
parentc1f8dd9f0b0fe4d3953edefd2d6172573f6b7504 (diff)
downloadbionic-c3581dc78a51180d3550d0d04596657cb2db852c.zip
bionic-c3581dc78a51180d3550d0d04596657cb2db852c.tar.gz
bionic-c3581dc78a51180d3550d0d04596657cb2db852c.tar.bz2
Merge "Sometimes the compiler is very right! Found bug in bessel routines for float."
Diffstat (limited to 'libm/src/e_j1f.c')
-rw-r--r--libm/src/e_j1f.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libm/src/e_j1f.c b/libm/src/e_j1f.c
index 539399e..ea05774 100644
--- a/libm/src/e_j1f.c
+++ b/libm/src/e_j1f.c
@@ -1,5 +1,6 @@
/* e_j1f.c -- float version of e_j1.c.
* Conversion to float by Ian Lance Taylor, Cygnus Support, ian@cygnus.com.
+ * Bug in __ieee754_j1f fixed by Scott Turner 1/16/2010
*/
/*
@@ -64,7 +65,7 @@ __ieee754_j1f(float x)
* j1(x) = 1/sqrt(pi) * (P(1,x)*cc - Q(1,x)*ss) / sqrt(x)
* y1(x) = 1/sqrt(pi) * (P(1,x)*ss + Q(1,x)*cc) / sqrt(x)
*/
- if(ix>0x80000000) z = (invsqrtpi*cc)/sqrtf(y);
+ if(((uint32_t)hx)>0x80000000) z = (invsqrtpi*cc)/sqrtf(y);
else {
u = ponef(y); v = qonef(y);
z = invsqrtpi*(u*cc-v*ss)/sqrtf(y);