diff --git a/src/asahi/compiler/agx_register_allocate.c b/src/asahi/compiler/agx_register_allocate.c index 9042f4a2a9a..7c0bbda0edd 100644 --- a/src/asahi/compiler/agx_register_allocate.c +++ b/src/asahi/compiler/agx_register_allocate.c @@ -153,8 +153,12 @@ agx_ra(agx_context *ctx) } } - agx_foreach_block(ctx, block) + /* Assign registers in dominance-order. This coincides with source-order due + * to a NIR invariant, so we do not need special handling for this. + */ + agx_foreach_block(ctx, block) { agx_ra_assign_local(block, ssa_to_reg, ncomps, ctx->max_register); + } /* TODO: Coalesce combines */