[pypy-svn] r69750 - pypy/branch/virtual-forcing/pypy/jit/metainterp/test

arigo at codespeak.net arigo at codespeak.net
Mon Nov 30 11:05:49 CET 2009


Author: arigo
Date: Mon Nov 30 11:05:48 2009
New Revision: 69750

Modified:
   pypy/branch/virtual-forcing/pypy/jit/metainterp/test/test_recursive.py
Log:
Fix test: because of recursion, we use CALL_MAY_FORCE systematically.


Modified: pypy/branch/virtual-forcing/pypy/jit/metainterp/test/test_recursive.py
==============================================================================
--- pypy/branch/virtual-forcing/pypy/jit/metainterp/test/test_recursive.py	(original)
+++ pypy/branch/virtual-forcing/pypy/jit/metainterp/test/test_recursive.py	Mon Nov 30 11:05:48 2009
@@ -144,10 +144,11 @@
         f = self.get_interpreter(codes)
 
         assert self.meta_interp(f, [0, 0, 0], optimizer=OPTIMIZER_SIMPLE) == 42
-        self.check_loops(int_add = 1, call = 1)
+        self.check_loops(int_add = 1, call_may_force = 1, call = 0)
         assert self.meta_interp(f, [0, 0, 0], optimizer=OPTIMIZER_SIMPLE,
                                 inline=True) == 42
-        self.check_loops(int_add = 2, call = 0, guard_no_exception = 0)
+        self.check_loops(int_add = 2, call_may_force = 0, call = 0,
+                         guard_no_exception = 0)
 
     def test_inline_jitdriver_check(self):
         code = "021"
@@ -158,7 +159,7 @@
 
         assert self.meta_interp(f, [0, 0, 0], optimizer=OPTIMIZER_SIMPLE,
                                 inline=True) == 42
-        self.check_loops(call = 1)
+        self.check_loops(call_may_force = 1, call = 0)
 
     def test_inline_faulty_can_inline(self):
         code = "021"
@@ -488,10 +489,10 @@
             return loop(100)
 
         res = self.meta_interp(main, [0], optimizer=OPTIMIZER_SIMPLE, trace_limit=TRACE_LIMIT)
-        self.check_loops(call=1)
+        self.check_loops(call_may_force=1, call=0)
 
         res = self.meta_interp(main, [1], optimizer=OPTIMIZER_SIMPLE, trace_limit=TRACE_LIMIT)
-        self.check_loops(call=0)
+        self.check_loops(call_may_force=0, call=0)
 
     def test_leave_jit_hook(self):
         from pypy.rpython.annlowlevel import hlstr
@@ -645,7 +646,7 @@
                 result += f('-c-----------l-', i+100)
         self.meta_interp(g, [10], backendopt=True)
         self.check_aborted_count(1)
-        self.check_history(call=1)
+        self.check_history(call_may_force=1, call=0)
         self.check_tree_loop_count(3)
         
 



More information about the Pypy-commit mailing list