diff options
author | Kenneth Graunke <[email protected]> | 2015-03-27 21:29:07 -0700 |
---|---|---|
committer | Kenneth Graunke <[email protected]> | 2015-04-02 14:20:02 -0700 |
commit | 7380c641b116a47d5729c553dcf3ed7143e877cc (patch) | |
tree | ea9a4c837f8ed0bbbfd513d40f378ce4bc8a204c /src/glsl | |
parent | 131444e1c5e08cbac4694489110ab53c9c07816d (diff) |
nir: Allocate predecessor and dominance frontier sets from block itself.
These sets are part of the block, and their lifetime needs to match the
block itself. So, allocate them using the block itself as the context.
Signed-off-by: Kenneth Graunke <[email protected]>
Reviewed-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'src/glsl')
-rw-r--r-- | src/glsl/nir/nir.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/glsl/nir/nir.c b/src/glsl/nir/nir.c index e96f113f2b2..73d3008a0b3 100644 --- a/src/glsl/nir/nir.c +++ b/src/glsl/nir/nir.c @@ -285,10 +285,10 @@ nir_block_create(void *mem_ctx) cf_init(&block->cf_node, nir_cf_node_block); block->successors[0] = block->successors[1] = NULL; - block->predecessors = _mesa_set_create(mem_ctx, _mesa_hash_pointer, + block->predecessors = _mesa_set_create(block, _mesa_hash_pointer, _mesa_key_pointer_equal); block->imm_dom = NULL; - block->dom_frontier = _mesa_set_create(mem_ctx, _mesa_hash_pointer, + block->dom_frontier = _mesa_set_create(block, _mesa_hash_pointer, _mesa_key_pointer_equal); exec_list_make_empty(&block->instr_list); |