aco/ra: Assert operands only clear their own id

This is useful for debugging register assignment, as this case would
usually result in RA silently assigning the same register to multiple
temps at the same time.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29576>
This commit is contained in:
Natalie Vock 2024-05-02 17:28:15 +02:00 committed by Marge Bot
parent 1967b0f0c4
commit d5a2666ad9

View file

@ -367,7 +367,12 @@ public:
}
}
void clear(Operand op) { clear(op.physReg(), op.regClass()); }
void clear(Operand op)
{
if (op.isTemp() && !is_empty_or_blocked(op.physReg()))
assert(get_id(op.physReg()) == op.tempId());
clear(op.physReg(), op.regClass());
}
void fill(Definition def)
{