aco/ra: fix stride check on subdword parallelcopies for create_vector

On GFX6/7, info.rc is in full dwords.

Fixes: 9476986e6f ('aco/ra: special-case get_reg_for_create_vector_copy()')
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15393>
This commit is contained in:
Daniel Schürmann 2022-03-14 13:56:12 +01:00 committed by Marge Bot
parent d32656bc65
commit db8c401f71

View file

@ -1041,8 +1041,8 @@ get_reg_for_create_vector_copy(ra_ctx& ctx, RegisterFile& reg_file,
for (unsigned i = 0; i < instr->operands.size(); i++) {
if (instr->operands[i].isTemp() && instr->operands[i].tempId() == id &&
instr->operands[i].isKillBeforeDef()) {
assert(!reg_file.test(reg, info.rc.bytes()));
return {reg, !info.rc.is_subdword() || (reg.byte() % info.stride == 0)};
assert(!reg_file.test(reg, instr->operands[i].bytes()));
return {reg, info.rc.is_subdword() || reg.byte() == 0};
}
reg.reg_b += instr->operands[i].bytes();
}