[pypy-svn] r43432 - pypy/dist/pypy/jit/timeshifter/test
cfbolz at codespeak.net
cfbolz at codespeak.net
Wed May 16 15:19:06 CEST 2007
Author: cfbolz
Date: Wed May 16 15:19:05 2007
New Revision: 43432
Modified:
pypy/dist/pypy/jit/timeshifter/test/test_portal.py
Log:
add a (skipped because failing) test for a recursive portal call.
Modified: pypy/dist/pypy/jit/timeshifter/test/test_portal.py
==============================================================================
--- pypy/dist/pypy/jit/timeshifter/test/test_portal.py (original)
+++ pypy/dist/pypy/jit/timeshifter/test/test_portal.py Wed May 16 15:19:05 2007
@@ -557,4 +557,18 @@
res = self.timeshift_from_portal(f, g, [42], policy=P_NOVIRTUAL)
-
+ def test_recursive_portal_call(self):
+ py.test.skip("recursive portal calls don't work right now")
+ def indirection(green, red):
+ return portal((green + red) % 100, red + 1)
+ def portal(green, red):
+ green = abs(green)
+ red = abs(red)
+ hint(green, concrete=True)
+ if green > 42:
+ return 0
+ if red > 42:
+ return 1
+ return indirection(green, red)
+ res = self.timeshift_from_portal(portal, portal, [41, 1], policy=P_NOVIRTUAL)
+ assert res == 0
More information about the Pypy-commit
mailing list