[pypy-commit] pypy default: A controversial checkin - try to limit the size of write analyzer analysis
fijal
noreply at buildbot.pypy.org
Thu Oct 24 11:23:44 CEST 2013
Author: Maciej Fijalkowski <fijall at gmail.com>
Branch:
Changeset: r67557:c89621c833be
Date: 2013-10-24 11:21 +0200
http://bitbucket.org/pypy/pypy/changeset/c89621c833be/
Log: A controversial checkin - try to limit the size of write analyzer
analysis
diff --git a/rpython/translator/backendopt/writeanalyze.py b/rpython/translator/backendopt/writeanalyze.py
--- a/rpython/translator/backendopt/writeanalyze.py
+++ b/rpython/translator/backendopt/writeanalyze.py
@@ -4,6 +4,7 @@
top_set = object()
empty_set = frozenset()
+CUTOFF = 1000
class WriteAnalyzer(graphanalyze.GraphAnalyzer):
def bottom_result(self):
@@ -21,6 +22,8 @@
def add_to_result(self, result, other):
if other is top_set:
return top_set
+ if len(other) + len(result) > CUTOFF:
+ return top_set
result.update(other)
return result
More information about the pypy-commit
mailing list