[pypy-svn] r72150 - pypy/trunk/pypy/jit/tool

fijal at codespeak.net fijal at codespeak.net
Fri Mar 12 02:15:05 CET 2010


Author: fijal
Date: Fri Mar 12 02:15:04 2010
New Revision: 72150

Modified:
   pypy/trunk/pypy/jit/tool/traceviewer.py
Log:
Kill some code. Kills dict-dependency order as a side effect (code
was not doing anything useful anyway)


Modified: pypy/trunk/pypy/jit/tool/traceviewer.py
==============================================================================
--- pypy/trunk/pypy/jit/tool/traceviewer.py	(original)
+++ pypy/trunk/pypy/jit/tool/traceviewer.py	Fri Mar 12 02:15:04 2010
@@ -38,9 +38,7 @@
 class Page(GraphPage):
     def compute(self, graphs):
         dotgen = DotGen('trace')
-        self.loops = set()
-        for graph in graphs:
-            graph.grab_loops(self.loops)
+        self.loops = graphs
         self.links = {}
         self.cache = {}
         for loop in self.loops:
@@ -114,13 +112,6 @@
     def postprocess(self, loops, memo):
         postprocess_loop(self.target, loops, memo)
 
-    def grab_loops(self, loops):
-        if self in loops:
-            return
-        loops.add(self)
-        if self.target is not None:
-            self.target.grab_loops(loops)
-
     def generate(self, dotgen):
         BasicBlock.generate(self, dotgen)
         if self.target is not None:
@@ -136,13 +127,6 @@
         postprocess_loop(self.left, loops, memo)
         postprocess_loop(self.right, loops, memo)
 
-    def grab_loops(self, loops):
-        if self in loops:
-            return
-        loops.add(self)
-        self.left.grab_loops(loops)
-        self.right.grab_loops(loops)
-
     def generate(self, dotgen):
         BasicBlock.generate(self, dotgen)
         dotgen.emit_edge(self.name(), self.left.name())



More information about the Pypy-commit mailing list