Author: Antonio Cuni <[email protected]>
Branch: autoreds
Changeset: r58851:ead40a8ddca6
Date: 2012-11-13 13:02 +0100
http://bitbucket.org/pypy/pypy/changeset/ead40a8ddca6/

Log:    of course we need to do the can_enter_jit check only if we are using
        autoreds, else everything breaks

diff --git a/pypy/jit/metainterp/warmspot.py b/pypy/jit/metainterp/warmspot.py
--- a/pypy/jit/metainterp/warmspot.py
+++ b/pypy/jit/metainterp/warmspot.py
@@ -256,6 +256,9 @@
         # add all the variables across the links to the reds.
         for block, op in graph.iterblockops():
             if op.opname == 'jit_marker':
+                jitdriver = op.args[1].value
+                if not jitdriver.autoreds:
+                    continue
                 # if we want to support also can_enter_jit, we should find a
                 # way to detect a consistent set of red vars to pass *both* to
                 # jit_merge_point and can_enter_jit. The current simple
@@ -266,9 +269,6 @@
                     "reds='auto' is supported only for jit drivers which " 
                     "calls only jit_merge_point. Found a call to %s" % 
methname)
                 #
-                jitdriver = op.args[1].value
-                if not jitdriver.autoreds:
-                    continue
                 assert jitdriver.confirm_enter_jit is None
                 # compute the set of live variables before the jit_marker
                 alive_v = set(block.inputargs)
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to