From a2c9e1cb50937577f918e643039f74a54585e699 Mon Sep 17 00:00:00 2001 From: Karol Herbst Date: Sun, 24 Apr 2022 21:55:34 +0200 Subject: [PATCH] nir: add 16 and 64 bit fisnormal lowering Signed-off-by: Karol Herbst Reviewed-by: Jason Ekstrand Part-of: --- src/compiler/nir/nir_opt_algebraic.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/compiler/nir/nir_opt_algebraic.py b/src/compiler/nir/nir_opt_algebraic.py index eec10407842..d0873b0e1aa 100644 --- a/src/compiler/nir/nir_opt_algebraic.py +++ b/src/compiler/nir/nir_opt_algebraic.py @@ -2419,7 +2419,9 @@ for op in ['ineg', 'iabs', 'inot', 'isign']: ] optimizations.extend([ - (('fisnormal', 'a@32'), ('ult', 0x1ffffff, ('iadd', ('ishl', a, 1), 0x1000000)), 'options->lower_fisnormal') + (('fisnormal', 'a@16'), ('ult', 0xfff, ('iadd', ('ishl', a, 1), 0x800)), 'options->lower_fisnormal'), + (('fisnormal', 'a@32'), ('ult', 0x1ffffff, ('iadd', ('ishl', a, 1), 0x1000000)), 'options->lower_fisnormal'), + (('fisnormal', 'a@64'), ('ult', 0x3fffffffffffff, ('iadd', ('ishl', a, 1), 0x20000000000000)), 'options->lower_fisnormal') ]) # This section contains optimizations to propagate downsizing conversions of