[pypy-svn] r11986 - pypy/dist/pypy/objspace/flow

arigo at codespeak.net arigo at codespeak.net
Thu May 5 23:12:51 CEST 2005


Author: arigo
Date: Thu May  5 23:12:51 2005
New Revision: 11986

Modified:
   pypy/dist/pypy/objspace/flow/flowcontext.py
Log:
Hard-to-find problem with the flow objspace creating too large graphs in some
cases.


Modified: pypy/dist/pypy/objspace/flow/flowcontext.py
==============================================================================
--- pypy/dist/pypy/objspace/flow/flowcontext.py	(original)
+++ pypy/dist/pypy/objspace/flow/flowcontext.py	Thu May  5 23:12:51 2005
@@ -324,7 +324,7 @@
         currentblock.closeblock(Link(outputargs, newblock))
         # phew
         if not finished:
-            if block is not None and block.exits:
+            if block is not None:
                 # to simplify the graph, we patch the old block to point
                 # directly at the new block which is its generalization
                 block.dead = True
@@ -332,6 +332,7 @@
                 block.exitswitch = None
                 outputargs = block.framestate.getoutputargs(newstate)
                 block.recloseblock(Link(outputargs, newblock))
+                candidates.remove(block)
             candidates.insert(0, newblock)
             self.pendingblocks.append(newblock)
 



More information about the Pypy-commit mailing list