[Mesa-stable] [Mesa-dev] [PATCH 1/5] st/nine: Clamp RCP when 0*inf!=0
Axel Davy
davyaxel0 at gmail.com
Wed Sep 12 06:31:40 UTC 2018
On 9/12/18 8:17 AM, Axel Davy wrote:
>
> The goal is to catch inf and -inf and replace them by FLT_MAX and
> -FLT_MAX.
>
> Without, the NaN would appear when doing mul or mad.
>
> Axel
>
>
>
I small precision I want to add: This is not the only place clamping
makes a difference.
Indeed else MUL_ZERO_WINS would be safe to use and remove all the clamping.
The rasterizers can produce NaN when given Inf in the vertex shader on
some devices for example,
and I think on some devices inf and FLT_MAX give different color in the
pixel shader.
Thus why I want to test carefully what do the other vendors for all the
shader versions (we know already there are
behaviour changes for some) and check with the behaviours mentionned
above, before removing the clamps when MUL_ZERO_WINS.
Axel
More information about the mesa-stable
mailing list