[erlang-questions] No JSON/MAPS interoperability in 17.0?

Richard A. O'Keefe ok@REDACTED
Mon Mar 17 03:00:49 CET 2014


On 16/03/2014, at 4:58 AM, Loïc Hoguin wrote:
> 
> I'm not sure you can guarantee this if the encoding/decoding happens on different architectures, can you? Is a 64bit floating point number the same on Intel, AMD, ARM, GPUs, FPGAs and so on?

There's an actively maintained standard.
Apple have supported it on three different hardware platforms
(M680x0, PowerPC, Intel).  SPARC does it.  HPPA and MIPS do it.
Alpha does it.  Even IBM mainframes, while still supporting
their old format, offer IEEE-compliant arithmetic these days.
Intel, AMD and ARM certainly support it.

About the only machines you are likely to meet these days
that _don't_ offer IEEE arithmetic are Unisys E-mode systems.
(Well, there might be some VAXen somewhere I suppose.)

As for FPGAs, they do whatever they are programmed to do.
Some have been programmed to do IEEE arithmetic, some haven't.

As for GPUs, they are why half-precision (16-bit) floats
are in IEEE-754:2008.  OpenCL says single-precision
floats will be there, double precision might or might not,
but they are expected to be IEEE-compliant.

XDR mandated the use of IEEE formats.  It's still around.





More information about the erlang-questions mailing list