diff --git a/backends/asm/optimize_ir.c b/backends/asm/optimize_ir.c index 4bca8d281..a1ea29457 100644 --- a/backends/asm/optimize_ir.c +++ b/backends/asm/optimize_ir.c @@ -2619,6 +2619,9 @@ static int IsSafeShortForwardJump(IR *irbase) { if (ir->opc == OPC_LABEL) { if (ir->dst == target) return n; else return 0; + } else if ((curfunc->optimize_flags & OPT_EXPERIMENTAL) && ir->opc == OPC_JUMP && ir->dst == target && ir->cond == irbase->cond) { + // Found jump that goes where we want to go, anyways. + return n; } // BRK instruction cannot be conditionalized?? if (ir->opc == OPC_BREAK) {