Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 15 Mar 2012 04:23:04 +0100
From: Szabolcs Nagy <nsz@...t70.net>
To: musl@...ts.openwall.com
Subject: Re: correctly rounded sqrt

* Szabolcs Nagy <nsz@...t70.net> [2012-03-15 02:46:48 +0100]:
> /* dekker exact mult u*u == hi + lo */
> static void sq(long double *hi, long double *lo, long double u)
> {
> 	static const long double c = 1.0 + 0x1p33;
this was wrong, c = 1.0 + 0x1p32; the correct value

and probably
*hi = u1*u1;
*lo = u1*u2*2.0 + u2*u2;
is enough instead of
> 	*hi = u*u;
> 	*lo = (u1*u1 - *hi) + u1*u2*2.0 + u2*u2;

but now that we figured out the fpu status register based
solution this does not matter..

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.