nir: Fix preseved metadata in sort_unstructured_blocks

Fixes: c859ea5783 ("nir: Add a sort_unstructured_blocks() helper")

Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Reviewed-by: Mel Henning <mhenning@darkrefraction.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38354>
This commit is contained in:
Christoph Pillmayer 2025-11-10 13:35:06 +00:00 committed by Marge Bot
parent 3858a6a696
commit 8db66767a9

View file

@ -968,7 +968,7 @@ nir_sort_unstructured_blocks(nir_function_impl *impl)
ralloc_free(blocks);
/* Dominance is toast but we indexed blocks as part of this pass. */
impl->valid_metadata &= nir_metadata_dominance;
/* Most metadata is toast but we indexed blocks as part of this pass. */
impl->valid_metadata &= nir_metadata_live_defs;
impl->valid_metadata |= nir_metadata_block_index;
}