diff options
Diffstat (limited to 'src/mesa/program/ir_to_mesa.cpp')
-rw-r--r-- | src/mesa/program/ir_to_mesa.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/mesa/program/ir_to_mesa.cpp b/src/mesa/program/ir_to_mesa.cpp index 8aefcf7e2b3..2a82e9d9ddc 100644 --- a/src/mesa/program/ir_to_mesa.cpp +++ b/src/mesa/program/ir_to_mesa.cpp @@ -2817,10 +2817,7 @@ get_mesa_program(struct gl_context *ctx, prog->NumTemporaries = v.next_temp; - int num_instructions = 0; - foreach_in_list(ir_instruction, node, &v.instructions) { - num_instructions++; - } + unsigned num_instructions = v.instructions.length(); mesa_instructions = (struct prog_instruction *)calloc(num_instructions, |