Commits

Carl Friedrich Bolz committed 044fb52

move the guard generation really directly before the JUMP (there was other
stuff generated in between in some cases, which caused the remaining test
failures)

  • Participants
  • Parent commits 98bf5d3
  • Branches small-unroll-improvements

Comments (0)

Files changed (1)

rpython/jit/metainterp/pyjitpl.py

             # much less expensive to blackhole out of.
             saved_pc = self.pc
             self.pc = orgpc
-            self.metainterp.generate_guard(rop.GUARD_FUTURE_CONDITION, resumepc=orgpc)
             self.metainterp.reached_loop_header(greenboxes, redboxes)
             self.pc = saved_pc
             # no exception, which means that the jit_merge_point did not
                                               duplicates)
             live_arg_boxes += self.virtualizable_boxes
             live_arg_boxes.pop()
-        #
+
+        # generate a dummy guard just before the JUMP so that unroll can use it
+        # when it's creating artificial guards.
+        self.generate_guard(rop.GUARD_FUTURE_CONDITION)
+
         assert len(self.virtualref_boxes) == 0, "missing virtual_ref_finish()?"
         # Called whenever we reach the 'loop_header' hint.
         # First, attempt to make a bridge: