Author: Armin Rigo <[email protected]>
Branch: jit-simplify-backendintf
Changeset: r50426:b43f4ac19a1b
Date: 2011-12-12 15:17 +0100
http://bitbucket.org/pypy/pypy/changeset/b43f4ac19a1b/
Log: Translation fix.
diff --git a/pypy/jit/backend/llgraph/llimpl.py
b/pypy/jit/backend/llgraph/llimpl.py
--- a/pypy/jit/backend/llgraph/llimpl.py
+++ b/pypy/jit/backend/llgraph/llimpl.py
@@ -330,7 +330,11 @@
def compile_started_vars(clt):
if not hasattr(clt, '_debug_argtypes'): # only when compiling the loop
- clt._debug_argtypes = [v.concretetype for v in _variables]
+ argtypes = [v.concretetype for v in _variables]
+ try:
+ clt._debug_argtypes = argtypes
+ except AttributeError: # when translated
+ pass
def compile_add(loop, opnum):
loop = _from_opaque(loop)
@@ -407,7 +411,10 @@
(loop_target, target_opindex, target_inputargs, target_clt
) = TARGET_TOKENS[descrobj]
#
- assert source_clt._debug_argtypes == target_clt._debug_argtypes
+ try:
+ assert source_clt._debug_argtypes == target_clt._debug_argtypes
+ except AttributeError: # when translated
+ pass
#
op = loop.operations[-1]
op.jump_target = loop_target
@@ -1828,6 +1835,7 @@
setannotation(compile_start_int_var, annmodel.SomeInteger())
setannotation(compile_start_ref_var, annmodel.SomeInteger())
setannotation(compile_start_float_var, annmodel.SomeInteger())
+setannotation(compile_started_vars, annmodel.s_None)
setannotation(compile_add, annmodel.s_None)
setannotation(compile_add_descr, annmodel.s_None)
setannotation(compile_add_descr_arg, annmodel.s_None)
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit