This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fix powl inaccuracy for ldbl-128ibm (bug 14914)


From: "Joseph S. Myers" <joseph@codesourcery.com>
Date: Mon, 3 Dec 2012 22:42:26 +0000

> Bug 14914 is inaccuracy of powl for ldbl-128ibm, which showed up in
> validation for 2.17.
> 
> In various places the code, based on that for ldbl-128, tries to split
> numbers into high and low parts in order to carry out operations on
> those parts separately, with at least some of the high-part operations
> needing to be exact.  However, the way the code extracts high parts is
> to clear the low 47 bits of the mantissa.  I've no idea how that
> figure was chosen - the ldbl-128 code clears 59 bits, i.e. more than
> half the mantissa - but as shown by the large errors for powl in the
> testsuite, it doesn't work well.  This patch changes the code to clear
> the whole low double of the long double value.  This eliminates all
> the ulps seen for the tests recently added or enabled for long double;
> no ulps at all are needed for pow for powerpc test-ldouble after this
> patch.  (Tested powerpc32, hard float; if this goes in then I'll
> retest powerpc-nofpu to see if any pow ulps updates are needed there.)

There aren't any major powl ULPs for sparc, so presumably ldbl-128 is
OK?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]