broadcom/compiler: free defin and defout arrays if they already exist
authorIago Toral Quiroga <itoral@igalia.com>
Wed, 5 Jul 2023 08:40:34 +0000 (10:40 +0200)
committerMarge Bot <emma+marge@anholt.net>
Wed, 5 Jul 2023 21:52:01 +0000 (21:52 +0000)
commitdcc6288a137fc8f1eed1cb1e7431e2f8640ac972
tree14cea22805876d2582e2e1cfc60c0980fba44c2a
parentb9de7da421d2dde4e473c50cc9293e693836d7f7
broadcom/compiler: free defin and defout arrays if they already exist

Just like we do for everything else here, since we are going to realloc
them again right below. Notice this is not exactly a memory leak, since
all these arrays are allocated with ralloc using v3d_compile as context,
so all allocations will be eventually freed when the context is destroyed.

Reviewed-by: Alejandro PiƱeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24001>
src/broadcom/compiler/vir_live_variables.c