www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - testing various reals

reply berni44 <dlang d-ecke.de> writes:
How do you test the different real implementations, when you've 
got to go into the internals of them?

I ask, because for the replacement of snprintf in std.format I 
sooner or later need to add support for reals. While it should 
not be too much a problem to look up the supported types and 
their layout in memory in std.math, I still have no means to test 
them (only intel's 80bit version and real=double). How did you do 
that in the past? Is there any simulation or something, that can 
be used for this? And does anyone know which formats are 
supported by the 10 auto-tester-machines?
Nov 14
parent kinke <noone nowhere.com> writes:
On Thursday, 14 November 2019 at 20:30:01 UTC, berni44 wrote:
 And does anyone know which formats are supported by the 10 
 auto-tester-machines?
Almost certainly just 80-bit X87, as the machines are all x86 AFAIK and DMD uses X87 for all tested OS. LDC uses 64-bit double-precision for MSVC Windows targets (CI tested; also used for most other architectures), software 128-bit quadruple for Android x86_64 (not CI tested) and X87 for all other x86 targets (CI tested: Linux and Mac). 128-bit quadruple is tested by our AArch64 CI. IBM's 128-bit doubledouble format for PowerPC isn't tested.
Nov 14