mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-20 07:20:10 +01:00
Merge branch 'review/f-string-fixes' into 'main'
nir/algebraic: Add missing f on F-strings See merge request mesa/mesa!39031
This commit is contained in:
commit
58b9e514b4
2 changed files with 6 additions and 3 deletions
|
|
@ -107,6 +107,9 @@ class SearchExpression(object):
|
|||
self.sources = expr[1:]
|
||||
self.ignore_exact = False
|
||||
|
||||
assert '{' not in self.opcode, \
|
||||
'Malformed opcode name \"{}\".'.format(self.opcode)
|
||||
|
||||
@staticmethod
|
||||
def create(val):
|
||||
if isinstance(val, tuple):
|
||||
|
|
|
|||
|
|
@ -3680,16 +3680,16 @@ for int_sz in (8, 16, 32):
|
|||
late_optimizations.extend([
|
||||
# This requires is_a_number because f2i_sat(NaN) is zero, but
|
||||
# fmax(intmin, NaN) is intmin.
|
||||
((f'f2i{int_sz}', ('fmax', f'a@{float_sz}(is_a_number)', intmin)), ('f2i{int_sz}_sat', a), 'options->has_f2i_sat'),
|
||||
((f'f2i{int_sz}', ('fmax', f'a@{float_sz}(is_a_number)', intmin)), (f'f2i{int_sz}_sat', a), 'options->has_f2i_sat'),
|
||||
|
||||
((f'f2i{int_sz}', ('fmin', f'a@{float_sz}(is_a_number)', intmax)), ('f2i{int_sz}_sat', a), 'options->has_f2i_sat'),
|
||||
((f'f2i{int_sz}', ('fmin', f'a@{float_sz}(is_a_number)', intmax)), (f'f2i{int_sz}_sat', a), 'options->has_f2i_sat'),
|
||||
((f'f2u{int_sz}', ('fmin', f'a@{float_sz}(is_a_number)', uintmax)), (f'f2u{int_sz}_sat', a), 'options->has_f2u_sat'),
|
||||
])
|
||||
|
||||
late_optimizations.extend([
|
||||
# This does not require is_a_number because both f2u_sat(NaN) and
|
||||
# fmax(NaN, 0) are zero.
|
||||
((f'f2u{int_sz}', ('fmax', f'a@{float_sz}', 0.0)), ('f2u{int_sz}_sat', a), 'options->has_f2u_sat'),
|
||||
((f'f2u{int_sz}', ('fmax', f'a@{float_sz}', 0.0)), (f'f2u{int_sz}_sat', a), 'options->has_f2u_sat'),
|
||||
|
||||
((f'f2u{int_sz}', ('ftrunc', f'a@{float_sz}')), (f'f2u{int_sz}_sat', a), 'options->has_f2u_sat'),
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue