aco: fix Temp and assignment of renamed operands during RA

Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-By: Timur Kristóf <timur.kristof@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4002>
This commit is contained in:
Daniel Schürmann 2020-03-25 12:15:54 +01:00
parent 2d957311f1
commit 7de003473c

View file

@ -1492,10 +1492,11 @@ void register_allocation(Program *program, std::vector<std::set<Temp>> live_out_
pc_op.setFixed(reg);
PhysReg new_reg = get_reg(ctx, register_file, operand.regClass(), parallelcopy, instr);
Definition pc_def = Definition(program->allocateId(), new_reg, pc_op.regClass());
ctx.assignments[pc_def.tempId()] = {reg, pc_def.regClass()};
ctx.assignments[pc_def.tempId()] = {new_reg, pc_def.regClass()};
register_file.clear(pc_op);
register_file.fill(pc_def);
parallelcopy.emplace_back(pc_op, pc_def);
operand.setTemp(pc_def.getTemp());
operand.setFixed(new_reg);
}