From: Tom Lane <tgl@sss.pgh.pa.us>
To: Dean Rasheed <dean.a.rasheed@gmail.com>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Cc: laetitia.avrot@gmail.com
Subject: Re: pgsql: Add support for hyperbolic functions, as well as log10().
Date: Wed, 13 Mar 2019 20:48:49 -0400
Message-ID: <27340.1552524529@sss.pgh.pa.us> (raw)
In-Reply-To: <CAEZATCX-mFwmx0NKbGsYJ6RAo8Hb=c+_CeNNXWQ7-BmK2_XVWw@mail.gmail.com>
References: <E1h3nUY-0000sM-Vf@gemulon.postgresql.org>
<20190313022159.GR13812@paquier.xyz>
<24813.1552447002@sss.pgh.pa.us>
<20190313050331.GT13812@paquier.xyz>
<17820.1552514192@sss.pgh.pa.us>
<CAEZATCX-mFwmx0NKbGsYJ6RAo8Hb=c+_CeNNXWQ7-BmK2_XVWw@mail.gmail.com>
Dean Rasheed <dean.a.rasheed@gmail.com> writes:
> It's not unreasonable to expect these functions to be accurate to within
> the last 1 or 2 digits, so testing with extra_float_digits or whatever
> seems reasonable, but I think a wider variety of test inputs is required.
Meh. As I said before, we're not in the business of improving on what
libm does --- if someone has a beef with the results, they need to take
it to their platform's libm maintainer, not us. The point of testing
this at all is just to ensure that we've wired up the SQL functions
to the library functions correctly.
> I also wonder if we should be doing what we do for the regular trig
> functions and explicitly handle special cases like Inf and NaN to ensure
> POSIX compatibility on all platforms.
I'm not too excited about this, but perhaps it would be interesting to
throw in tests of the inf/nan cases temporarily, just to see how big
a problem there is of that sort. If the answer comes out to be
"all modern platforms get this right", I don't think it's our job to
clean up after the stragglers. But if the answer is not that, maybe
I could be talked into spending code on it.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-committers@postgresql.org
Cc: tgl@sss.pgh.pa.us, dean.a.rasheed@gmail.com, michael@paquier.xyz, pgsql-hackers@lists.postgresql.org, laetitia.avrot@gmail.com
Subject: Re: pgsql: Add support for hyperbolic functions, as well as log10().
In-Reply-To: <27340.1552524529@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox