aco: Handle NSA with vectors in get_mimg_nsa_dwords.

No Foz-DB changes.

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20370>
This commit is contained in:
Georg Lehmann
2022-12-17 12:32:49 +01:00
committed by Marge Bot
parent 1ab80eb061
commit 9abe4850ba

View File

@@ -68,7 +68,8 @@ get_mimg_nsa_dwords(const Instruction* instr)
{
unsigned addr_dwords = instr->operands.size() - 3;
for (unsigned i = 1; i < addr_dwords; i++) {
if (instr->operands[3 + i].physReg() != instr->operands[3].physReg().advance(i * 4))
if (instr->operands[3 + i].physReg() !=
instr->operands[3 + (i - 1)].physReg().advance(instr->operands[3 + (i - 1)].bytes()))
return DIV_ROUND_UP(addr_dwords - 1, 4);
}
return 0;