About Social Code
aboutsummaryrefslogtreecommitdiff
path: root/src/compiler/nir/nir_opt_call.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/compiler/nir/nir_opt_call.c')
-rw-r--r--src/compiler/nir/nir_opt_call.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/compiler/nir/nir_opt_call.c b/src/compiler/nir/nir_opt_call.c
index 7b8747d3b48..45dda349d0a 100644
--- a/src/compiler/nir/nir_opt_call.c
+++ b/src/compiler/nir/nir_opt_call.c
@@ -10,7 +10,7 @@
struct call_liveness_entry {
struct list_head list;
nir_call_instr *instr;
- const BITSET_WORD *live_set;
+ struct u_sparse_bitset *live_set;
};
static bool
@@ -188,8 +188,6 @@ nir_minimize_call_live_states_impl(nir_function_impl *impl)
BITSET_WORD *def_blocks = ralloc_array(mem_ctx, BITSET_WORD, block_words);
list_for_each_entry(struct call_liveness_entry, entry, &call_list, list) {
- unsigned i;
-
nir_builder b = nir_builder_at(nir_after_instr(&entry->instr->instr));
struct nir_phi_builder *builder = nir_phi_builder_create(impl);
@@ -198,7 +196,7 @@ nir_minimize_call_live_states_impl(nir_function_impl *impl)
struct hash_table *remap_table =
_mesa_pointer_hash_table_create(mem_ctx);
- BITSET_FOREACH_SET(i, entry->live_set, num_defs) {
+ U_SPARSE_BITSET_FOREACH_SET(entry->live_set, i) {
if (!rematerializable[i] ||
_mesa_hash_table_search(remap_table, rematerializable[i]))
continue;