From 8037b215732d889399d760ff4bf7c1fb79a16ed2 Mon Sep 17 00:00:00 2001 From: Rhys Perry Date: Mon, 30 Aug 2021 13:58:52 +0100 Subject: [PATCH] aco/ra: allow v1b operands with 16-bit instructions MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Instruction selection can create these. Signed-off-by: Rhys Perry Reviewed-by: Timur Kristóf Fixes: ec1bbfa6088 ("aco/ra: refactor subdword operand stride") Part-of: --- src/amd/compiler/aco_register_allocation.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/amd/compiler/aco_register_allocation.cpp b/src/amd/compiler/aco_register_allocation.cpp index bcb70ee..2ed68fd 100644 --- a/src/amd/compiler/aco_register_allocation.cpp +++ b/src/amd/compiler/aco_register_allocation.cpp @@ -510,12 +510,12 @@ add_subdword_operand(ra_ctx& ctx, aco_ptr& instr, unsigned idx, uns if (instr->isVALU()) { /* check if we can use opsel */ if (instr->format == Format::VOP3) { - assert(rc == v2b && byte == 2); + assert(byte == 2); instr->vop3().opsel |= 1 << idx; return; } if (instr->isVOP3P()) { - assert(rc == v2b && byte == 2 && !(instr->vop3p().opsel_lo & (1 << idx))); + assert(byte == 2 && !(instr->vop3p().opsel_lo & (1 << idx))); instr->vop3p().opsel_lo |= 1 << idx; instr->vop3p().opsel_hi |= 1 << idx; return; -- 2.7.4