Merge "Refactor code in preparation of correct stack maps in slow path."