<p dir="ltr"><br>
On Apr 9, 2016 11:05 AM, "Kenneth Graunke" <<a href="mailto:kenneth@whitecape.org">kenneth@whitecape.org</a>> wrote:<br>
><br>
> On Saturday, April 9, 2016 3:31:16 AM PDT Markus Wick wrote:<br>
> > Dolphin uses them a lot. Range tracking would be better in the long term,<br>
> > but this two lines works fine for now.<br>
><br>
> these four lines<br>
><br>
> Reviewed-by: Kenneth Graunke <<a href="mailto:kenneth@whitecape.org">kenneth@whitecape.org</a>><br>
><br>
> Thanks for fixing this!  I can push the patch for you in a day or two<br>
> assuming nobody else has feedback.</p>
<p dir="ltr">LGTM.  Of course, shader-db numbers would be nice.</p>
<p dir="ltr">> > Signed-off-by: Markus Wick <<a href="mailto:markus@selfnet.de">markus@selfnet.de</a>><br>
> > ---<br>
> >  src/compiler/nir/nir_opt_algebraic.py | 5 ++++-<br>
> >  1 file changed, 4 insertions(+), 1 deletion(-)<br>
> ><br>
> > diff --git a/src/compiler/nir/nir_opt_algebraic.py b/src/compiler/nir/<br>
> nir_opt_algebraic.py<br>
> > index e72b4a7..31d7655 100644<br>
> > --- a/src/compiler/nir/nir_opt_algebraic.py<br>
> > +++ b/src/compiler/nir/nir_opt_algebraic.py<br>
> > @@ -137,7 +137,10 @@ optimizations = [<br>
> >     (('~fmax', ('fmin', a, 1.0), 0.0), ('fsat', a), '!options->lower_fsat'),<br>
> >     (('fsat', a), ('fmin', ('fmax', a, 0.0), 1.0), 'options->lower_fsat'),<br>
> >     (('fsat', ('fsat', a)), ('fsat', a)),<br>
> > -   (('fmin', ('fmax', ('fmin', ('fmax', a, 0.0), 1.0), 0.0), 1.0), ('fmin',<br>
> ('fmax', a, 0.0), 1.0)),<br>
> > +   (('fmin', ('fmax', ('fmin', ('fmax', a, b), c), b), c), ('fmin',<br>
> ('fmax', a, b), c)),<br>
> > +   (('imin', ('imax', ('imin', ('imax', a, b), c), b), c), ('imin',<br>
> ('imax', a, b), c)),<br>
> > +   (('umin', ('umax', ('umin', ('umax', a, b), c), b), c), ('umin',<br>
> ('umax', a, b), c)),<br>
> > +   (('extract_u8', ('imin', ('imax', a, 0), 0xff), 0), ('imin', ('imax', a,<br>
> 0), 0xff)),<br>
> >     (('~ior', ('flt', a, b), ('flt', a, c)), ('flt', a, ('fmax', b, c))),<br>
> >     (('~ior', ('flt', a, c), ('flt', b, c)), ('flt', ('fmin', a, b), c)),<br>
> >     (('~ior', ('fge', a, b), ('fge', a, c)), ('fge', a, ('fmin', b, c))),<br>
> ><br>
><br>
><br>
> _______________________________________________<br>
> mesa-dev mailing list<br>
> <a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
> <a href="https://lists.freedesktop.org/mailman/listinfo/mesa-dev">https://lists.freedesktop.org/mailman/listinfo/mesa-dev</a><br>
><br>
</p>