glsl/softfp64: Add fisfinite lowering.
This is generated by nir_lower_frexp, and if we leave fisfinite in place then the late algebraic pass lowering it to this pattern will cause an un-lowered fabs64 to be emitted. Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22083>
This commit is contained in:
@@ -1716,3 +1716,9 @@ __ffract64(uint64_t a)
|
||||
{
|
||||
return __fadd64(a, __fneg64(__ffloor64(a)));
|
||||
}
|
||||
|
||||
bool
|
||||
__fisfinite64(uint64_t __a)
|
||||
{
|
||||
return __extractFloat64Exp(__a) != 0x7ff;
|
||||
}
|
||||
|
||||
@@ -600,6 +600,11 @@ lower_doubles_instr_to_soft(nir_builder *b, nir_alu_instr *instr,
|
||||
name = "__fsat64";
|
||||
mangled_name = "__fsat64(u641;";
|
||||
break;
|
||||
case nir_op_fisfinite:
|
||||
name = "__fisfinite64";
|
||||
mangled_name = "__fisfinite64(u641;";
|
||||
return_type = glsl_bool_type();
|
||||
break;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user