pika-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Pika-dev] floating point conversions progress


From: Matthew Dempsky
Subject: [Pika-dev] floating point conversions progress
Date: Mon, 22 Dec 2003 09:57:48 -0600
User-agent: Gnus/5.1002 (Gnus v5.10.2) XEmacs/21.4 (Rational FORTRAN, windows-nt)

I tried sending an email to the mailing list the other day with some
of the code for cvt_double_to_string, but apparently it didn't get
sent.  Since then I've pushed the code into my archive as
address@hidden/cvt--devo--0.1.  It's still not perfect, but I
rewrote the code to use GMP and now it's about 2.5x the performance of
glibc (but like I've said a few times - mine still doesn't do proper
formatting for everything).

I can add the remaining code to test for special cases like nan, inf,
and to handle negative numbers, but then I can either start
integrating it into hackerlab and users will have to just settle with
the fact that right now printfmt will always print doubles in
free-form precision (as many or few digits necessary to accurately
print out) and extend it to support fixed-form precision later, or
work on that now before integrating into printfmt.

Since r5rs (6.2.6) says "If z is inexact, the radix is 10, and the
above expression can be satisfied by a result that contains a decimal
point, then the result contains a decimal point and is expressed using
the minimum number of digits (exclusive of exponent and trailing
zeroes) needed to make the above expression true [howtoprint],
[howtoread]; otherwise the format of the result is unspecified" and
Pika's the only project in need of doubles in hackerlab at the moment
it wouldn't be too bad.

Finally, I branched address@hidden/elisp--devo--0.1 and commited
a patch to the templates for s/tag/arch-tag/.

-jivera





reply via email to

[Prev in Thread] Current Thread [Next in Thread]