[pypy-svn] r51718 - in pypy/branch/jit-refactoring/pypy/jit/rainbow: . test
cfbolz at codespeak.net
cfbolz at codespeak.net
Thu Feb 21 12:19:43 CET 2008
Author: cfbolz
Date: Thu Feb 21 12:19:42 2008
New Revision: 51718
Modified:
pypy/branch/jit-refactoring/pypy/jit/rainbow/interpreter.py
pypy/branch/jit-refactoring/pypy/jit/rainbow/test/test_interpreter.py
Log:
add a fresh_jitstate method to the interpreter
Modified: pypy/branch/jit-refactoring/pypy/jit/rainbow/interpreter.py
==============================================================================
--- pypy/branch/jit-refactoring/pypy/jit/rainbow/interpreter.py (original)
+++ pypy/branch/jit-refactoring/pypy/jit/rainbow/interpreter.py Thu Feb 21 12:19:42 2008
@@ -72,6 +72,11 @@
self.bytecode_loop()
return self.jitstate
+ def fresh_jitstate(self, builder):
+ return rtimeshift.JITState(builder, None,
+ self.exceptiondesc.null_exc_type_box,
+ self.exceptiondesc.null_exc_value_box)
+
def finish_jitstate(self, graphsigtoken):
jitstate = self.jitstate
exceptiondesc = self.exceptiondesc
Modified: pypy/branch/jit-refactoring/pypy/jit/rainbow/test/test_interpreter.py
==============================================================================
--- pypy/branch/jit-refactoring/pypy/jit/rainbow/test/test_interpreter.py (original)
+++ pypy/branch/jit-refactoring/pypy/jit/rainbow/test/test_interpreter.py Thu Feb 21 12:19:42 2008
@@ -153,9 +153,8 @@
sigtoken = rgenop.sigToken(self.RESIDUAL_FUNCTYPE)
builder, gv_generated, inputargs_gv = rgenop.newgraph(sigtoken, "generated")
builder.start_writing()
- jitstate = rtimeshift.JITState(builder, None,
- writer.exceptiondesc.null_exc_type_box,
- writer.exceptiondesc.null_exc_value_box)
+ jitstate = writer.interpreter.fresh_jitstate(builder)
+
# build arguments
greenargs = []
redargs = []
More information about the Pypy-commit
mailing list