} else if (!in_ds && opcode_is_load(c) && c.i.op != OP_LWC2) {
next = block->opcode_list[i + 1].c;
- if (c.i.op == OP_LWL && next.i.op == OP_LWR)
+ switch (next.i.op) {
+ case OP_LWL:
+ case OP_LWR:
+ case OP_REGIMM:
+ case OP_BEQ:
+ case OP_BNE:
+ case OP_BLEZ:
+ case OP_BGTZ:
continue;
+ }
if (opcode_reads_register(next, c.i.rt)
&& !opcode_writes_register(next, c.i.rs)) {