aco/ra: Always rename copy-kill operands, even if the temporary doesn't match

This makes it independent of whether the operand already got renamed or not.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34359>
This commit is contained in:
Daniel Schürmann
2025-05-23 14:54:10 +02:00
committed by Marge Bot
parent 4fad3514a9
commit 92b1154397
+4 -4
View File
@@ -879,9 +879,6 @@ update_renames(ra_ctx& ctx, RegisterFile& reg_file, std::vector<parallelcopy>& p
if (is_def)
continue;
/* The loop below might change this if is_copy_kill=true, but we will want the original */
Operand copy_op = it->op;
/* Check if we moved another parallelcopy definition. We use a different path for copy-kill
* copies, since they are able to exist alongside a normal copy with the same operand.
*/
@@ -919,7 +916,10 @@ update_renames(ra_ctx& ctx, RegisterFile& reg_file, std::vector<parallelcopy>& p
ctx.assignments.emplace_back(copy.def.physReg(), copy.def.regClass());
assert(ctx.assignments.size() == ctx.program->peekAllocationId());
/* check if we moved an operand */
/* Check if we moved an operand:
* For copy-kill operands, use the current Operand name so that kill flags stay correct.
*/
Operand copy_op = is_copy_kill ? instr->operands[copy.copy_kill] : it->op;
bool first[2] = {true, true};
bool fill = !is_copy_kill;
for (unsigned i = 0; i < instr->operands.size(); i++) {