From 9f5e5fb912203c0ae6de242144a91da8a7e41c8b Mon Sep 17 00:00:00 2001 From: Gert Wollny Date: Wed, 14 Oct 2020 14:58:00 +0200 Subject: [PATCH] r600/sfn: Fix the parameter component type Signed-off-by: Gert Wollny Part-of: --- src/gallium/drivers/r600/sfn/sfn_shader_fragment.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/gallium/drivers/r600/sfn/sfn_shader_fragment.cpp b/src/gallium/drivers/r600/sfn/sfn_shader_fragment.cpp index a8ae6e6..109f60f 100644 --- a/src/gallium/drivers/r600/sfn/sfn_shader_fragment.cpp +++ b/src/gallium/drivers/r600/sfn/sfn_shader_fragment.cpp @@ -713,7 +713,7 @@ bool FragmentShaderFromNir::load_interpolated_one_comp(GPRVector &dest, auto ir = new AluInstruction(op, dest[chan], i & 1 ? ip.j : ip.i, - PValue(new InlineConstValue(ALU_SRC_PARAM_BASE + io.lds_pos(), 0)), + PValue(new InlineConstValue(ALU_SRC_PARAM_BASE + io.lds_pos(), i)), i == 0 ? EmitInstruction::write : EmitInstruction::last); dest.pin_to_channel(chan); @@ -728,7 +728,7 @@ bool FragmentShaderFromNir::load_interpolated_two_comp(GPRVector &dest, ShaderIn { AluInstruction *ir = nullptr; for (unsigned i = 0; i < 4 ; ++i) { - ir = new AluInstruction(op, dest[i], i & 1 ? ip.j : ip.i, PValue(new InlineConstValue(ALU_SRC_PARAM_BASE + io.lds_pos(), 0)), + ir = new AluInstruction(op, dest[i], i & 1 ? ip.j : ip.i, PValue(new InlineConstValue(ALU_SRC_PARAM_BASE + io.lds_pos(), i)), (writemask & (1 << i)) ? EmitInstruction::write : EmitInstruction::empty); dest.pin_to_channel(i); ir->set_bank_swizzle(alu_vec_210); @@ -745,7 +745,7 @@ bool FragmentShaderFromNir::load_interpolated_two_comp_for_one(GPRVector &dest, AluInstruction *ir = nullptr; for (int i = 0; i < 4 ; ++i) { ir = new AluInstruction(op, dest[i], i & 1 ? ip.j : ip.i, - PValue(new InlineConstValue(ALU_SRC_PARAM_BASE + io.lds_pos(), 0)), + PValue(new InlineConstValue(ALU_SRC_PARAM_BASE + io.lds_pos(), i)), i == comp ? EmitInstruction::write : EmitInstruction::empty); ir->set_bank_swizzle(alu_vec_210); dest.pin_to_channel(i); -- 2.7.4