agx: Maintain ctx->max_reg while assigning regs
authorAlyssa Rosenzweig <alyssa@rosenzweig.io>
Mon, 31 Jul 2023 21:42:58 +0000 (17:42 -0400)
committerMarge Bot <emma+marge@anholt.net>
Fri, 11 Aug 2023 20:31:27 +0000 (20:31 +0000)
commitd0b966cb10656457af503cffc5792ae75a895655
treee565e3be8d0fb6364682673f6b4563809dd554fe
parentb973e3821483a8897d7d0068492fee91b52ae3c3
agx: Maintain ctx->max_reg while assigning regs

We can't calculate after since ssa_to_reg[] gets overwritten during live range
splits. Theoretical issue only, but let's fix it while squashing live range
splitting bugs.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24635>
src/asahi/compiler/agx_register_allocate.c