[pypy-svn] r34877 - pypy/dist/pypy/jit/timeshifter/test
pedronis at codespeak.net
pedronis at codespeak.net
Wed Nov 22 20:05:18 CET 2006
Author: pedronis
Date: Wed Nov 22 20:05:17 2006
New Revision: 34877
Modified:
pypy/dist/pypy/jit/timeshifter/test/test_portal.py
pypy/dist/pypy/jit/timeshifter/test/test_timeshift.py
pypy/dist/pypy/jit/timeshifter/test/test_tlc.py
Log:
(arre, pedronis)
flag small on tests to control if the intermediate graphs are too huge to be worth showing normally, instead with small=False
only the hint-annotated graph and the generated graphs will be shown.
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 Nov 22 20:05:17 2006
@@ -13,6 +13,8 @@
class PortalTest(object):
from pypy.jit.codegen.llgraph.rgenop import RGenOp
+ small = True
+
def setup_class(cls):
cls._cache = {}
cls._cache_order = []
@@ -53,13 +55,13 @@
self.hrtyper = HintRTyper(ha, self.rtyper, self.RGenOp)
origportalgraph = graphof(t, portal)
self.hrtyper.specialize(origportalgraph=origportalgraph,
- view = conftest.option.view)
+ view = conftest.option.view and self.small)
for graph in ha.translator.graphs:
checkgraph(graph)
t.graphs.append(graph)
- if conftest.option.view:
+ if conftest.option.view and self.small:
t.view()
self.postprocess_timeshifting()
self.readportalgraph = self.hrtyper.readportalgraph
Modified: pypy/dist/pypy/jit/timeshifter/test/test_timeshift.py
==============================================================================
--- pypy/dist/pypy/jit/timeshifter/test/test_timeshift.py (original)
+++ pypy/dist/pypy/jit/timeshifter/test/test_timeshift.py Wed Nov 22 20:05:17 2006
@@ -63,6 +63,8 @@
class TimeshiftingTests(object):
from pypy.jit.codegen.llgraph.rgenop import RGenOp
+ small = True
+
def setup_class(cls):
cls._cache = {}
cls._cache_order = []
@@ -98,7 +100,7 @@
# make the timeshifted graphs
hrtyper = HintRTyper(ha, rtyper, self.RGenOp)
- hrtyper.specialize(view = conftest.option.view)
+ hrtyper.specialize(view = conftest.option.view and self.small)
fresh_jitstate = hrtyper.ll_fresh_jitstate
finish_jitstate = hrtyper.ll_finish_jitstate
@@ -218,7 +220,7 @@
self.rtyper = rtyper
self.hrtyper = hrtyper
self.annotate_interface_functions()
- if conftest.option.view:
+ if conftest.option.view and self.small:
from pypy.translator.tool.graphpage import FlowGraphPage
FlowGraphPage(t, ha.translator.graphs).display()
Modified: pypy/dist/pypy/jit/timeshifter/test/test_tlc.py
==============================================================================
--- pypy/dist/pypy/jit/timeshifter/test/test_tlc.py (original)
+++ pypy/dist/pypy/jit/timeshifter/test/test_tlc.py Wed Nov 22 20:05:17 2006
@@ -21,6 +21,7 @@
class TestTLC(PortalTest):
+ small = False
def test_factorial(self):
code = tlc.compile(FACTORIAL_SOURCE)
More information about the Pypy-commit
mailing list