[Mesa-dev] [RFC PATCH] nir/algebraic: Remove problematic "optimization"

Jason Ekstrand jason at jlekstrand.net
Thu May 16 01:58:13 UTC 2019


Ran it through shader-db.  No changes.  Feel free to stuff that in the
commit message somewhere.

Reviewed-by: Jason Ekstrand <jason at jlekstrand.net>

On Wed, May 15, 2019 at 12:04 AM Alyssa Rosenzweig <alyssa at rosenzweig.io>
wrote:

> This line is no longer relevant now that booleans are 1-bit, and in fact
> causes issues (infinite progress loop between algebraic optimizations
> and copy prop) with constant vector masks.
>
> Signed-off-by: Alyssa Rosenzweig <alyssa at rosenzweig.io>
> Cc: Jason Ekstrand <jason.ekstrand at intel.com>
> ---
>  src/compiler/nir/nir_opt_algebraic.py | 3 ---
>  1 file changed, 3 deletions(-)
>
> diff --git a/src/compiler/nir/nir_opt_algebraic.py
> b/src/compiler/nir/nir_opt_algebraic.py
> index 1c7b3597c1f..89d07aa1261 100644
> --- a/src/compiler/nir/nir_opt_algebraic.py
> +++ b/src/compiler/nir/nir_opt_algebraic.py
> @@ -621,9 +621,6 @@ optimizations = [
>     (('bcsel', True, b, c), b),
>     (('bcsel', False, b, c), c),
>     (('bcsel', a, ('b2f(is_used_once)', 'b at 32'), ('b2f', 'c at 32')),
> ('b2f', ('bcsel', a, b, c))),
> -   # The result of this should be hit by constant propagation and, in the
> -   # next round of opt_algebraic, get picked up by one of the above two.
> -   (('bcsel', '#a', b, c), ('bcsel', ('ine', 'a', 0), b, c)),
>
>     (('bcsel', a, b, b), b),
>     (('fcsel', a, b, b), b),
> --
> 2.20.1
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20190515/4fb1def2/attachment.html>


More information about the mesa-dev mailing list