mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-04 20:38:06 +02:00
nv50/ir/nir: convert 8/16 bit src to 32 bit for {i,u}2f64
Converting signed and unsigned integers from 8/16 bit sources to a 64 bit floating point destination (i2f64 / u2f64) isn't possible, hence convert the source to 32 bit first. Reviewed-by: Karol Herbst <kherbst@redhat.com> Signed-off-by: Danilo Krummrich <dakr@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18109>
This commit is contained in:
parent
78fc5e3773
commit
109d56f612
1 changed files with 9 additions and 0 deletions
|
|
@ -3291,6 +3291,15 @@ Converter::lowerBitSizeCB(const nir_instr *instr, void *data)
|
|||
|
||||
return 0;
|
||||
}
|
||||
case nir_op_i2f64:
|
||||
case nir_op_u2f64: {
|
||||
DataType stype = instance->getSTypes(alu)[0];
|
||||
|
||||
if (isIntType(stype) && (typeSizeof(stype) <= 2))
|
||||
return 32;
|
||||
|
||||
return 0;
|
||||
}
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue