simplify asm mid_pred, as suggested by michaelni.