[Mesa-dev] [PATCH 3/6] nir: Turn -(b2f(a) + b2f(b) >= 0 into !(a || b).
Kenneth Graunke
kenneth at whitecape.org
Wed Aug 10 18:09:10 UTC 2016
On Wednesday, August 10, 2016 10:58:49 AM PDT Ian Romanick wrote:
> On 08/09/2016 07:30 PM, Kenneth Graunke wrote:
> > On Haswell (GL 3.3):
> >
> > total instructions in shared programs: 6211485 -> 6211427 (-0.00%)
> > instructions in affected programs: 16260 -> 16202 (-0.36%)
> > helped: 25
> > HURT: 37
> >
> > On Broadwell (GL 4.4):
> >
> > total instructions in shared programs: 11640288 -> 11640218 (-0.00%)
> > instructions in affected programs: 16313 -> 16243 (-0.43%)
> > helped: 27
> > HURT: 37
>
> Interesting... I had a similar version of this that worked on arbitrary
> length sequences of (b2f(a_0) + .. b2f(a_n)), but I didn't get any
> benefit. I also had tests for a couple other relational operators with
> 0 that didn't see benefit. Maybe one of us should try to revive my old,
> more generic series at some point.
>
> For now, this patch is
>
> Reviewed-by: Ian Romanick <ian.d.romanick at intel.com>
I believe I first saw this sequence after my bcsel -1.0 -0.0 optimization.
I also imported over 11,000 more shaders recently - probably after
you last did this experiment.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part.
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160810/868d6493/attachment.sig>
More information about the mesa-dev
mailing list