From 6c7d23e6caf6ac505dee7a8c394ede78e05eb283 Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Wed, 15 Sep 2021 17:59:52 -0500 Subject: [PATCH] nir: Stop sweeping indirects They're no longer ralloc'd. Fixes: 879a569884b1 "nir: Switch from ralloc to malloc for NIR instructions." Reviewed-by: Emma Anholt Reviewed-by: Ian Romanick Part-of: --- src/compiler/nir/nir_sweep.c | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/src/compiler/nir/nir_sweep.c b/src/compiler/nir/nir_sweep.c index 812a450fdb8..0c5c71ad970 100644 --- a/src/compiler/nir/nir_sweep.c +++ b/src/compiler/nir/nir_sweep.c @@ -40,24 +40,6 @@ static void sweep_cf_node(nir_shader *nir, nir_cf_node *cf_node); -static bool -sweep_src_indirect(nir_src *src, void *nir) -{ - if (!src->is_ssa && src->reg.indirect) - ralloc_steal(nir, src->reg.indirect); - - return true; -} - -static bool -sweep_dest_indirect(nir_dest *dest, void *nir) -{ - if (!dest->is_ssa && dest->reg.indirect) - ralloc_steal(nir, dest->reg.indirect); - - return true; -} - static void sweep_block(nir_shader *nir, nir_block *block) { @@ -75,9 +57,6 @@ sweep_block(nir_shader *nir, nir_block *block) nir_foreach_instr(instr, block) { list_del(&instr->gc_node); list_add(&instr->gc_node, &nir->gc_list); - - nir_foreach_src(instr, sweep_src_indirect, nir); - nir_foreach_dest(instr, sweep_dest_indirect, nir); } }