When finding a good place for a register, we can ignore
killed operands.
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4130>
continue;
/* dead operands effectively reduce the number of estimated moves */
- if (remaining_op_moves && reg_file.is_blocked(PhysReg{j})) {
- k--;
- remaining_op_moves--;
+ if (reg_file.is_blocked(PhysReg{j})) {
+ if (remaining_op_moves) {
+ k--;
+ remaining_op_moves--;
+ }
continue;
}