glsl/loops: Allocate loop_terminator using new(mem_ctx) syntax.
Patches to follow will introduce code into the loop_terminator constructor. Allocating loop_terminator using new(mem_ctx) syntax will ensure that the constructor runs. Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
This commit is contained in:
@@ -134,7 +134,7 @@ loop_terminator *
|
||||
loop_variable_state::insert(ir_if *if_stmt)
|
||||
{
|
||||
void *mem_ctx = ralloc_parent(this);
|
||||
loop_terminator *t = rzalloc(mem_ctx, loop_terminator);
|
||||
loop_terminator *t = new(mem_ctx) loop_terminator();
|
||||
|
||||
t->ir = if_stmt;
|
||||
this->terminators.push_tail(t);
|
||||
|
||||
Reference in New Issue
Block a user