Complex number functions for std.math
Anders F Björklund
afb at algonet.se
Sun Apr 9 00:44:25 PDT 2006
James Dunne wrote:
> So, software-supported half-precision and hardware-supported
> quad-precision (if available)? Sounds interesting...
I think that SoftFloat has 128-bit support, but I've only seen the
double-double implementation in hardware (and it is *not* full IEEE)
There is an open source (C++) implementation of half from OpenEXR,
it uses unsigned short for storage and float for all calculations...
"single" and "double" are the ones usually present in hardware,
"extended" and "quad" might be available, and "half" never is.
(unless you count the graphics hardware, since OpenGL and some
GPU cards do have support for 16-bit floating point channels...)
As discussed earlier, type "real" is easiest to do as an alias.
> Why not throw in fixed-point types as well?
Oh, I thought you were talking about floating point formats here ?
I think that IEEE now includes fixed-point too, but haven't checked.
--anders
More information about the Digitalmars-d
mailing list