From 572a902566471b882267d0193784d2afd05ca4ba Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Tue, 19 Oct 2021 13:27:55 +0200 Subject: [PATCH] aco: fix emitting stream outputs when the first component isn't zero Fixes a bunch of XFB piglit tests with Zink. Cc: 21.3 mesa-stable Signed-off-by: Samuel Pitoiset Reviewed-by: Rhys Perry Part-of: --- src/amd/compiler/aco_instruction_selection.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/amd/compiler/aco_instruction_selection.cpp b/src/amd/compiler/aco_instruction_selection.cpp index 743fed4a7d8..c9990971106 100644 --- a/src/amd/compiler/aco_instruction_selection.cpp +++ b/src/amd/compiler/aco_instruction_selection.cpp @@ -11174,7 +11174,7 @@ emit_stream_output(isel_context* ctx, Temp const* so_buffers, Temp const* so_wri aco_opcode::p_create_vector, Format::PSEUDO, count, 1)}; for (int i = 0; i < count; ++i) vec->operands[i] = - (ctx->outputs.mask[loc] & 1 << (start + i)) ? Operand(out[start + i]) : Operand::zero(); + (ctx->outputs.mask[loc] & 1 << (start + first_comp + i)) ? Operand(out[start + i]) : Operand::zero(); vec->definitions[0] = Definition(write_data); ctx->block->instructions.emplace_back(std::move(vec));