mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 08:58:02 +02:00
nir/opt_algebraic: optimize ineg(a) == #b
No Foz-DB changes. v2 (idr): Remove some patterns that are now redundant. These were originally removed in a commit later in the MR. Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Reviewed-by: Timur Kristóf <timur.kristof@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/33498>
This commit is contained in:
parent
3e4ac92298
commit
000f14f7fd
1 changed files with 2 additions and 4 deletions
|
|
@ -691,8 +691,8 @@ optimizations.extend([
|
|||
(('fneu', a, '#b(is_negative_zero)'), ('fneu', 0.0, a)),
|
||||
(('feq', '#b(is_negative_zero)', a), ('feq', a, 0.0)),
|
||||
|
||||
(('ieq', ('ineg', a), 0), ('ieq', a, 0)),
|
||||
(('ine', ('ineg', a), 0), ('ine', a, 0)),
|
||||
(('ieq', ('ineg', 'a(is_not_const)'), '#b'), ('ieq', a, ('ineg', b))),
|
||||
(('ine', ('ineg', 'a(is_not_const)'), '#b'), ('ine', a, ('ineg', b))),
|
||||
(('ieq', ('iabs', a), 0), ('ieq', a, 0)),
|
||||
(('ine', ('iabs', a), 0), ('ine', a, 0)),
|
||||
|
||||
|
|
@ -1454,8 +1454,6 @@ for s in [8, 16, 32, 64]:
|
|||
])
|
||||
|
||||
optimizations.extend([
|
||||
(('ieq', ('ineg', ('b2i', 'a@1')), -1), a),
|
||||
(('ine', ('ineg', ('b2i', 'a@1')), -1), ('inot', a)),
|
||||
(('ige', ('ineg', ('b2i', 'a@1')), 0), ('inot', a)),
|
||||
(('ilt', ('ineg', ('b2i', 'a@1')), 0), a),
|
||||
(('ult', 0, ('ineg', ('b2i', 'a@1'))), a),
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue