Re: [HACKERS] regression bigtest needs very long time

From: wieck(at)debis(dot)com (Jan Wieck)
To: tgl(at)sss(dot)pgh(dot)pa(dot)us (Tom Lane)
Cc: maillist(at)candle(dot)pha(dot)pa(dot)us, jwieck(at)debis(dot)com, sakaida(at)psn(dot)co(dot)jp, pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: [HACKERS] regression bigtest needs very long time
Date: 1999-06-29 16:01:16
Message-ID: m10z0Jw-0003ktC@orion.SAPserv.Hamburg.dsh.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:

> One thing worth thinking about is whether the storage format shouldn't
> be made the same as the calculation format, so as to eliminate the
> conversion costs. At four decimal digits per int2, it wouldn't cost
> us anything to do so.

That's an extra bonus point from the described internal
format.

>
> regards, tom lane
>
> PS: BTW, Jan, if you do not have a copy of Knuth's volume 2, I'd
> definitely recommend laying your hands on it for this project.
> His description of multiprecision arithmetic is the best I've seen
> anywhere.

I don't have so far - thanks for the hint.

> If we thought that the math functions (sqrt, exp, etc) for numerics
> were really getting used for anything, it might also be fun to try
> to put in some better algorithms for them. I've got a copy of Cody
> and Waite, which has been the bible for such things for twenty years.
> But my guess is that it wouldn't be worth the trouble, except to the
> extent that it speeds up the regression tests ;-)

They are based on the standard Taylor/McLaurin definitions
for those functions.

Most times I need trigonometric functions or the like one of
my sliderules still has enough precision because I'm unable
to draw 0.1mm or more precise with a pencil on a paper. YES,
I love to USE sliderules (I have a dozen now, some regular
ones, some circular ones, some pocket sized and one circular
pocket sized one that looks more like a stopwatch than a
sliderule).

Thus, usually the precision of float8 should be more than
enough for those calculations. Making NUMERIC able to handle
these functions in it's extreme precision shouldn't really be
that time critical.

Remember: The lack of mathematical knowledge never shows up
better than in unappropriate precision of numerical
calculations.
C. F. Gauss
(Sorry for the poor translation)

What Gauss (born 1777 and the first who knew how to take the
square root out of negative numbers) meant by that is, it is
stupid to calculate with a precision of 10 or no digits after
the decimal point if you're able to measure with 4 digits.

Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#========================================= wieck(at)debis(dot)com (Jan Wieck) #

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fred Wilson Horch 1999-06-29 18:16:12 User requests now that 6.5 is out
Previous Message The Hermit Hacker 1999-06-29 15:52:48 Re: [HACKERS] Re: Mess