cvs commit: src/sys/i386/include _types.h

David Schultz das at FreeBSD.ORG
Fri Mar 7 03:41:16 UTC 2008


On Thu, Mar 06, 2008, Colin Percival wrote:
> David Schultz wrote:
> > On Thu, Mar 06, 2008, Colin Percival wrote:
> >>   explicit or implicit final destination. When a variable with a declared format
> >>                                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> >>   is a final destination, as in format conversion to a variable, that declared
> >>   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> >>   format of that variable governs its rounding. The format of an implicit
> >>   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> >>   destination, or of an explicit destination without a declared format, is
> >>   defined by language standard expression evaluation rules.
> > 
> > I think you missed the point about implicit destinations.
> 
> No.  Another quote:
>   2.2.14 destination: The location for the result of an operation upon one or
>   more operands. A destination might be either explicitly designated by the user
>   or implicitly supplied by the system (for example, intermediate results in
>   subexpressions or arguments for procedures). [...]
> 
> Implicit destinations are things like the (x * y) in "x * y - 1.0" or in
> "sqrt(x * y)".
> 
> > The register is an implicit destination. IEEE 754R explains this
> > in more detail.
> 
> Really?   I can't find any such statements... quite the contrary.

When reading the above quotation, you need to keep in mind that in
their terminology, 'z = x + y' is an expression and 'x + y' is a
subexpression. What you're claiming doesn't even make sense.  With
your rules, the 'x * y' in 'k = x * y - 1.0' could be evaluated
with extra precision, the '- 1.0' would be forced to machine
precision, and you'd still have double rounding on the multiply.
This really *isn't* what they meant.

Look, please have a careful look at section 10.2. This is a really
busy week for me, and I don't have the inclination to continue
this discussion if you keep sniping.


More information about the cvs-all mailing list