(j3.2006) decimal floats
Andy Vaught
andyv
Sat Jan 12 14:21:16 EST 2008
On Sat, 12 Jan 2008, Andy Vaught wrote:
> On Fri, 11 Jan 2008, Robert Corbett wrote:
>
> >
> > I agree that implicit conversions should be banned. There should be
> > functions for explicit conversions. I suspect that most people do not
> > understand how expensive radix conversions are, especially for large
> > exponents.
> >
> > Some people on the committee think arithmetic should be done in the
> > format used to represent values in memory. That could create problems
> > for programs that use IEEE 754r's storage format such as binary16 and
> > decimal32.
>
> The parsing and printing of binary numbers to and from ascii is a prime
> example of radix conversion.
>
> The fortran philosophy of the past, however, is that you can even
> interoperate reals and integers without explicit conversion. Or even
> adding reals to logicals on some implementations. If people are concerned
> about speed, they're going to figure out not to do a conversion pretty
> quick, and, IMO, not use decimal arithmetic at all.
Having given some more thought to this, I think the real insanity is a
chip that does floating point in two different radices. If someone wants
to make a chip that does decimal floating point, fortran 90 will support
that perfectly-- radix(0.0) is 10 and everything else works as it should.
If a chipmaker uses two radices, it means that they don't think that
decimal floating point will stand on its own and are hedging their bets.
Andy
More information about the J3
mailing list