From: Timothy Arceri Date: Wed, 30 May 2018 10:32:24 +0000 (+1000) Subject: nir: add unsigned comparison simplifications X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e8b368ad1c4bdafc32505b722617b8ab19296fbe;p=mesa.git nir: add unsigned comparison simplifications This avoids loop unrolling regressions in Wolfenstein II on DXVK with an upcoming optimisation series from Samuel. Reviewed-by: Bas Nieuwenhuizen --- diff --git a/src/compiler/nir/nir_opt_algebraic.py b/src/compiler/nir/nir_opt_algebraic.py index 909ea3daf42..21b9acecbe2 100644 --- a/src/compiler/nir/nir_opt_algebraic.py +++ b/src/compiler/nir/nir_opt_algebraic.py @@ -149,7 +149,9 @@ optimizations = [ (('~inot', ('feq', a, b)), ('fne', a, b)), (('~inot', ('fne', a, b)), ('feq', a, b)), (('inot', ('ilt', a, b)), ('ige', a, b)), + (('inot', ('ult', a, b)), ('uge', a, b)), (('inot', ('ige', a, b)), ('ilt', a, b)), + (('inot', ('uge', a, b)), ('ult', a, b)), (('inot', ('ieq', a, b)), ('ine', a, b)), (('inot', ('ine', a, b)), ('ieq', a, b)),