Commit 132bb814 authored by Alyssa Rosenzweig's avatar Alyssa Rosenzweig 💜

midgard: Fix regression in regression fix

parent 9046a0e9
......@@ -846,10 +846,10 @@ emit_binary_instruction(compiler_context *ctx, midgard_instruction *ins, struct
int index = 0, last_unit = 0;
while (ins + index) {
midgard_instruction *ains = ins + (index++);
midgard_instruction *ains = ins + index;
/* Ensure that the chain can continue */
if (ains->unused) continue;
if (ains->unused) goto skip_instruction;
if (ains->type != TAG_ALU_4 || ains->unit <= last_unit) break;
control |= ains->unit;
......@@ -879,6 +879,9 @@ emit_binary_instruction(compiler_context *ctx, midgard_instruction *ins, struct
/* TODO: Emit pipeline registers and batch instructions once we know how XXX */
break;
}
skip_instruction:
++index;
}
/* Bubble up the number of instructions for skipping */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment