Refactor the dead block prediction based replacement code.