Re: is order urgent doubt



Walter Roberson <roberson@xxxxxxxxxxxxxxxxxx> wrote:

Long double arithmetic is supported by the compiler. The
representation used is not IEEE compliant; long doubles are
represented on this system as the sum or difference of two doubles,
normalized so that the smaller double is <= .5 ULP of the larger.
This is equivalent to a 107 bit mantissa with an 11 bit biased
exponent (bias = 1023), and 1 sign bit. In terms of decimal
precision, this is approximately 34 decimal digits.

Which is a perfectly valid implementation, but only because of the
normalization. Without it, the number of bits in the (virtual) mantissa
is not fixed (there can be arbitrarily many virtual zero bits between
the actual bits from the two double, or they can overlap), which doesn't
conform to C's floating point model.

-- Larry Jones

What a stupid world. -- Calvin
.



Relevant Pages

  • Re: Why does 1.2 % 0.01 not equal to zero?
    ... My integer method is sort of a back door cheat. ... It avoids the real ... results of the % operator on floats or doubles is so insidious ... ... Eventually even the 128 bit decimal representation fails to provide ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Why no Floor for fixed point types
    ... The name 'Mantissa' is misleading, ... >> not be the mantissa (the decimal digits to the left of the decimal ... floating-point representation (because the machine has sufficient support ... me, as a compiler writer!). ...
    (comp.lang.ada)
  • Re: float precision
    ... In "debug view"? ... Since the precision of any 'float' value is 24 bits of mantissa, ... In the internal representation with an infinite mantissa ...
    (microsoft.public.vc.language)
  • Re: Applesoft: find address that variable is stored at?
    ... anyone have a better explanation of the 5 byte representation? ... format works like this: ... the mantissa is stored in the other four bytes. ... Since this is always known to be the case, we don't have to actually store these bits anywhere. ...
    (comp.sys.apple2.programmer)
  • Re: is order urgent doubt
    ... Long double arithmetic is supported by the compiler. ... represented on this system as the sum or difference of two doubles, ... Long double constants are coded as double precision constants followed ... require a double denormal in their representation and therefore ...
    (comp.lang.c)