Tweaks to avoid some loop cases