mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-24 08:10:22 +01:00
nir: Lower all bit sizes of usub_borrow
It's not clear why this is restricted to 32-bit besides that being the only bit size where GLSL has an intrinsic for this. All drivers that set this probably want it lowered for all bit sizes as far as I can tell. Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6353 Fixes:8a3e344180("nir/opt_algebraic: Fix some expressions with ambiguous bit sizes") Reviewed-by: Emma Anholt <emma@anholt.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16146> (cherry picked from commit1755730362)
This commit is contained in:
parent
74f39aeec5
commit
98fb3bf943
2 changed files with 2 additions and 2 deletions
|
|
@ -332,7 +332,7 @@
|
|||
"description": "nir: Lower all bit sizes of usub_borrow",
|
||||
"nominated": true,
|
||||
"nomination_type": 1,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"because_sha": "8a3e3441802c417ec944f02a9f38491b3b236d7c"
|
||||
},
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1643,7 +1643,7 @@ optimizations.extend([
|
|||
(('fmod', a, b), ('fsub', a, ('fmul', b, ('ffloor', ('fdiv', a, b)))), 'options->lower_fmod'),
|
||||
(('frem', a, b), ('fsub', a, ('fmul', b, ('ftrunc', ('fdiv', a, b)))), 'options->lower_fmod'),
|
||||
(('uadd_carry', a, b), ('b2i', ('ult', ('iadd', a, b), a)), 'options->lower_uadd_carry'),
|
||||
(('usub_borrow@32', a, b), ('b2i', ('ult', a, b)), 'options->lower_usub_borrow'),
|
||||
(('usub_borrow', a, b), ('b2i', ('ult', a, b)), 'options->lower_usub_borrow'),
|
||||
|
||||
(('bitfield_insert', 'base', 'insert', 'offset', 'bits'),
|
||||
('bcsel', ('ult', 31, 'bits'), 'insert',
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue