mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-06 06:40:08 +01:00
aco/ra: assert that the register file is empty after register allocation completed
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28876>
This commit is contained in:
parent
be1e68b4ee
commit
e1c9b2a455
1 changed files with 5 additions and 2 deletions
|
|
@ -3333,9 +3333,12 @@ register_allocation(Program* program, live& live_vars, ra_test_policy policy)
|
|||
|
||||
if ((block.kind & block_kind_top_level) && block.linear_succs.empty()) {
|
||||
/* Reset this for block_kind_resume. */
|
||||
ASSERTED PhysRegInterval linear_vgpr_bounds = get_reg_bounds(ctx, RegType::vgpr, true);
|
||||
assert(register_file.count_zero(linear_vgpr_bounds) == linear_vgpr_bounds.size);
|
||||
ctx.num_linear_vgprs = 0;
|
||||
|
||||
ASSERTED PhysRegInterval vgpr_bounds = get_reg_bounds(ctx, RegType::vgpr, false);
|
||||
ASSERTED PhysRegInterval sgpr_bounds = get_reg_bounds(ctx, RegType::sgpr, false);
|
||||
assert(register_file.count_zero(vgpr_bounds) == ctx.vgpr_bounds);
|
||||
assert(register_file.count_zero(sgpr_bounds) == ctx.sgpr_bounds);
|
||||
} else if (should_compact_linear_vgprs(ctx, live_vars, register_file)) {
|
||||
aco_ptr<Instruction> br = std::move(instructions.back());
|
||||
instructions.pop_back();
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue