nir/lower_reg: Support unstructured control-flow

Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28300>
This commit is contained in:
Faith Ekstrand 2024-03-18 11:10:26 -05:00 committed by Marge Bot
parent bef0601d51
commit 42853b8115
2 changed files with 2 additions and 2 deletions

View file

@ -146,7 +146,7 @@ nir_lower_reg_intrinsics_to_ssa_impl(nir_function_impl *impl)
state.values = rzalloc_array(dead_ctx, struct nir_phi_builder_value *,
impl->ssa_alloc);
nir_foreach_block(block, impl) {
nir_foreach_block_unstructured(block, impl) {
nir_foreach_instr_safe(instr, block) {
if (instr->type != nir_instr_type_intrinsic)
continue;

View file

@ -100,7 +100,7 @@ nir_phi_builder_create(nir_function_impl *impl)
pb->num_blocks = impl->num_blocks;
pb->blocks = ralloc_array(pb, nir_block *, pb->num_blocks);
nir_foreach_block(block, impl) {
nir_foreach_block_unstructured(block, impl) {
pb->blocks[block->index] = block;
}