aco: fix 64bit fsub

Fixes: 425558bfd5 ('aco: use v_subrev_f32 for fsub with an sgpr operand in src1')

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4642>
This commit is contained in:
Daniel Schürmann 2020-04-20 12:59:21 +01:00 committed by Marge Bot
parent ad3ef6d0fc
commit be0bb7e101
1 changed files with 1 additions and 1 deletions

View File

@ -1654,7 +1654,7 @@ void visit_alu_instr(isel_context *ctx, nir_alu_instr *instr)
emit_vop2_instruction(ctx, instr, aco_opcode::v_subrev_f32, dst, true);
} else if (dst.regClass() == v2) {
Instruction* add = bld.vop3(aco_opcode::v_add_f64, Definition(dst),
src0, src1);
as_vgpr(ctx, src0), as_vgpr(ctx, src1));
VOP3A_instruction* sub = static_cast<VOP3A_instruction*>(add);
sub->neg[1] = true;
} else {