mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 09:38:07 +02:00
nir/spirv: Stop wrapping carry/borrow in b2i
The upstream versions now return an integer like GLSL/SPIR-V want.
This commit is contained in:
parent
dee09d7393
commit
c381906bbd
1 changed files with 2 additions and 4 deletions
|
|
@ -309,15 +309,13 @@ vtn_handle_alu(struct vtn_builder *b, SpvOp opcode,
|
|||
case SpvOpIAddCarry:
|
||||
assert(glsl_type_is_struct(val->ssa->type));
|
||||
val->ssa->elems[0]->def = nir_iadd(&b->nb, src[0], src[1]);
|
||||
val->ssa->elems[1]->def =
|
||||
nir_b2i(&b->nb, nir_uadd_carry(&b->nb, src[0], src[1]));
|
||||
val->ssa->elems[1]->def = nir_uadd_carry(&b->nb, src[0], src[1]);
|
||||
return;
|
||||
|
||||
case SpvOpISubBorrow:
|
||||
assert(glsl_type_is_struct(val->ssa->type));
|
||||
val->ssa->elems[0]->def = nir_isub(&b->nb, src[0], src[1]);
|
||||
val->ssa->elems[1]->def =
|
||||
nir_b2i(&b->nb, nir_usub_borrow(&b->nb, src[0], src[1]));
|
||||
val->ssa->elems[1]->def = nir_usub_borrow(&b->nb, src[0], src[1]);
|
||||
return;
|
||||
|
||||
case SpvOpUMulExtended:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue