On 7/30/07, Petter Urkedal <[EMAIL PROTECTED]> wrote:
> On 2007-07-30, Andre Pouliot wrote:
> > In that case I'm going to modify the program to make the result go to
> > infinity when we receive an infinite/NAN or force the output at zero when we
> > receive an denormalized/zero value. So no more denormalized value. All case
> > that make the pipeline behave strangely will be covered. The case infinite
> > multiplied by zero will result in zero unless someone have an objection.
>
> I think I'd let Inf*0 = NaN, the argument being as follows: Ignoring the
> sign, if the result of an operation on finite values is Inf, the true
> value can be anything above the greatest representable, and if the
> result is 0, the value can be anything below the smallest representable.
> The product of the two can be *any* value including 0 and infinite.

For us, infinity is just as undefined as NaN.  Sure, we can clamp
infinity to the max value when converting to fixed point, and we
probably will, but we'll do it with the least logic, meaning that NaN
will end up being clamped the same.

Anyhow, there's a reason I prefer that 0*inf yield zero.  That's
because zero is defined.  Zero may be used as a way to take some
operand out of consideration.  To generalize, we might have a constant
of zero as one operand and GARBAGE as the other because of some other
optimization.

-- 
Timothy Normand Miller
http://www.cse.ohio-state.edu/~millerti
Open Graphics Project
_______________________________________________
Open-graphics mailing list
[email protected]
http://lists.duskglow.com/mailman/listinfo/open-graphics
List service provided by Duskglow Consulting, LLC (www.duskglow.com)

Reply via email to