[pypy-svn] r51383 - in pypy/branch/jit-refactoring/pypy/jit: rainbow rainbow/test timeshifter

cfbolz at codespeak.net cfbolz at codespeak.net
Mon Feb 11 14:21:18 CET 2008


Author: cfbolz
Date: Mon Feb 11 14:21:18 2008
New Revision: 51383

Modified:
   pypy/branch/jit-refactoring/pypy/jit/rainbow/interpreter.py
   pypy/branch/jit-refactoring/pypy/jit/rainbow/test/test_vdict.py
   pypy/branch/jit-refactoring/pypy/jit/timeshifter/vdict.py
Log:
make all vdict tests pass


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	Mon Feb 11 14:21:18 2008
@@ -324,6 +324,13 @@
         # XXX all this jitstate.greens business is a bit messy
         self.green_result(self.jitstate.greens[0])
 
+    def opimpl_red_oopspec_call_0(self):
+        oopspecindex = self.load_2byte()
+        deepfrozen = self.load_bool()
+        oopspec = self.frame.bytecode.oopspecdescs[oopspecindex]
+        result = oopspec.ll_handler(self.jitstate, oopspec, deepfrozen)
+        self.red_result(result)
+
     def opimpl_red_oopspec_call_1(self):
         oopspecindex = self.load_2byte()
         deepfrozen = self.load_bool()

Modified: pypy/branch/jit-refactoring/pypy/jit/rainbow/test/test_vdict.py
==============================================================================
--- pypy/branch/jit-refactoring/pypy/jit/rainbow/test/test_vdict.py	(original)
+++ pypy/branch/jit-refactoring/pypy/jit/rainbow/test/test_vdict.py	Mon Feb 11 14:21:18 2008
@@ -5,7 +5,6 @@
 
 P_OOPSPEC = HintAnnotatorPolicy(novirtualcontainer = True,
                                 oopspec = True)
-py.test.skip("implement me")
 
 
 class TestVDict(AbstractInterpretationTest):

Modified: pypy/branch/jit-refactoring/pypy/jit/timeshifter/vdict.py
==============================================================================
--- pypy/branch/jit-refactoring/pypy/jit/timeshifter/vdict.py	(original)
+++ pypy/branch/jit-refactoring/pypy/jit/timeshifter/vdict.py	Mon Feb 11 14:21:18 2008
@@ -95,9 +95,7 @@
 class DictTypeDesc(object):
     __metaclass__ = cachedtype
 
-    def __init__(self, hrtyper, DICT):
-        RGenOp = hrtyper.RGenOp
-        rtyper = hrtyper.rtyper
+    def __init__(self, RGenOp, rtyper, DICT):
         bk = rtyper.annotator.bookkeeper
         self.DICT = DICT
         self.DICTPTR = lltype.Ptr(DICT)
@@ -266,7 +264,7 @@
         raise NotImplementedError
 
 
-def oop_newdict(jitstate, oopspecdesc):
+def oop_newdict(jitstate, oopspecdesc, deepfrozen):
     return oopspecdesc.typedesc.factory()
 
 def oop_dict_setitem(jitstate, oopspecdesc, deepfrozen, selfbox, keybox, valuebox):



More information about the Pypy-commit mailing list