[Mesa-dev] [PATCH 3/9] i965/fs: Get rid of the sel.sat peephole
Francisco Jerez
currojerez at riseup.net
Thu Mar 17 21:50:17 UTC 2016
Matt Turner <mattst88 at gmail.com> writes:
> On Thu, Mar 17, 2016 at 10:21 AM, Jason Ekstrand <jason at jlekstrand.net> wrote:
>> Shader-db results on Broadwell:
>>
>> total instructions in shared programs: 7517815 -> 7517816 (0.00%)
>> instructions in affected programs: 46 -> 47 (2.17%)
>> HURT: 1
>>
>> The one hurt shader is a shader from "The Swapper" that writes to
>> gl_FrontColor and, as such, gets an implicit sat added to the output write.
>> Since this is invisible to NIR, the optimization in the previous commit
>> can't fix it for us.
>> ---
>
> How could this possibly cause problems? I don't understand why you're
> trying to remove it.
Yeah, this optimization seems invariant- and precise-safe modulo the
handling of NaNs in the src[1] >= 1.0 case (the <= 0 case is NaN and
denorm-correct AFAICT because MOV.sat flushes them to zero just like
'SEL.sat.g(e) x, 0'), and it seems moderately useful, not sure it's a
good plan to just get rid of it.
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 212 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160317/505cdad4/attachment.sig>
More information about the mesa-dev
mailing list