develooper Front page | perl.perl5.porters | Postings from September 2014

Re: new long doubles option: gcc libquadmath

Thread Previous | Thread Next
Jarkko Hietaniemi
September 21, 2014 12:32
Re: new long doubles option: gcc libquadmath
Message ID:
On Sunday-201409-21, 8:12, wrote:
> 1) Is it planned that POSIX::strtoflt128 will be provided for this
> configuration ?


(1a) It's nowhere near 'POSIX' or 'OpenGroup' or 'C99' (the current
sources of POSIX:: interfaces: basically, interfaces beyond what the 
mid-90s SunOS where Perl 5 was born in, had)

(1b) the strtoflt128 is already used by the quadmath Perl build,
instead of strtod/strtold, always, for obvious reasons.

(1c) The same with quadmath_snprintf() vs Gconvert()/snprintf().

(1d) Having those interfaces separately would indicate/necessitate that
Perl has more than one NV precision internally, which it of course does

> 2) Will we see a unique $Config{archname} suffix for this configuration ?
> (Currently it just shows up as 'ld', same as for nvtype eq long double.)


(2a) quadmath is bitwise identical to IEEE 754 quadruple precision.
It is not a new format, just an implementation of one.

(2b) We currently do not difference in the archname between the 
different flavors of long double (at least three fundamentally
different flavors exist).

(2c) Because of 2b I think it's time not to think of "uselongdouble"
as "using the 'C long double'" (since that doesn't guarantee any
particular mantissa/exponent) but instead as "using something larger
than double".

(2d) There is now, with 5.21.4, $Config{longdblkind}.  The values
are documented e.g. in Porting/Glossary.

(2e) There's also $Config{usequadmath} if one is interested in
that in particular.

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About