From: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
---|---|
To: | Magnus Hagander <mha(at)sollentuna(dot)net> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Regression error on float8 |
Date: | 2006-04-24 18:23:17 |
Message-ID: | 20060424182317.GD2747@svana.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, Apr 24, 2006 at 03:01:51PM +0200, Magnus Hagander wrote:
> If I undefine HAVE_CBRT on Linux, I get the exact same failure! So it
> seems our own version of cbrt() is broken wrt our own regression tests
> :-( Must be that nobody else (at least on i386) uses that code.
<snip>
> What do you think is best - try to adapt that version, or update our
> regression tests outputs to accept the output from our current code?
Given that our output gets very very close, perhaps we should take a
hint from the end of the MinGW version, do a single Newton iteration to
fixup those last few digits.
Adding this before the last line of our version of cbrt():
tmpres -= ( tmpres - (x/(tmpres*tmpres)) )*0.33333333333333333333;
Makes it give the same result as my system version...
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2006-04-24 19:42:22 | Re: 2x compile warning |
Previous Message | Kris Jurka | 2006-04-24 18:16:04 | Re: 2x compile warning |