summaryrefslogtreecommitdiff
path: root/sysdeps/ieee754/dbl-64/mplog.c
diff options
context:
space:
mode:
authorSiddhesh Poyarekar <siddhesh@redhat.com>2012-12-27 20:43:24 +0530
committerSiddhesh Poyarekar <siddhesh@redhat.com>2012-12-27 20:43:24 +0530
commitb76eb5f076d362cdfbb95f0986285a8661e4082f (patch)
tree86db1db19c800043d2a2061e2fe4f6ea21666527 /sysdeps/ieee754/dbl-64/mplog.c
parent8ebac7785b6ac0e412075d832af2ede21153148a (diff)
downloadglibc-b76eb5f076d362cdfbb95f0986285a8661e4082f.tar.gz
Move mpone out to a global const
Code cleanup.
Diffstat (limited to 'sysdeps/ieee754/dbl-64/mplog.c')
-rw-r--r--sysdeps/ieee754/dbl-64/mplog.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/sysdeps/ieee754/dbl-64/mplog.c b/sysdeps/ieee754/dbl-64/mplog.c
index 8255e2a100..c0606c6339 100644
--- a/sysdeps/ieee754/dbl-64/mplog.c
+++ b/sysdeps/ieee754/dbl-64/mplog.c
@@ -40,21 +40,13 @@
void __mpexp(mp_no *, mp_no *, int);
void __mplog(mp_no *x, mp_no *y, int p) {
-#include "mplog.h"
int i,m;
-#if 0
- int j,k,m1,m2,n;
- double a,b;
-#endif
static const int mp[33] = {0,0,0,0,0,1,1,2,2,2,2,3,3,3,3,3,3,3,3,
4,4,4,4,4,4,4,4,4,4,4,4,4,4};
- mp_no mpone = {0,{0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,
- 0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,
- 0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0}};
mp_no mpt1,mpt2;
- /* Choose m and initiate mpone */
- m = mp[p]; mpone.e = 1; mpone.d[0]=mpone.d[1]=ONE;
+ /* Choose m */
+ m = mp[p];
/* Perform m newton iterations to solve for y: exp(y)-x=0. */
/* The iterations formula is: y(n+1)=y(n)+(x*exp(-y(n))-1). */