[pypy-commit] pypy release-gil-flush-heapcache: Fix for translation, not everything has a func (why? I don't know). With this patch it actually seems to fix my deadlock. I get some other weird error though. Somehow that seems better.

alex_gaynor noreply at buildbot.pypy.org
Tue Jul 19 04:29:28 CEST 2011


Author: Alex Gaynor <alex.gaynor at gmail.com>
Branch: release-gil-flush-heapcache
Changeset: r45735:e4e34dd540f5
Date: 2011-07-18 19:29 -0700
http://bitbucket.org/pypy/pypy/changeset/e4e34dd540f5/

Log:	Fix for translation, not everything has a func (why? I don't know).
	With this patch it actually seems to fix my deadlock. I get some
	other weird error though. Somehow that seems better.

diff --git a/pypy/jit/codewriter/effectinfo.py b/pypy/jit/codewriter/effectinfo.py
--- a/pypy/jit/codewriter/effectinfo.py
+++ b/pypy/jit/codewriter/effectinfo.py
@@ -202,7 +202,7 @@
 class CanReleaseGILAnalyzer(BoolGraphAnalyzer):
     def analyze_direct_call(self, graph, seen=None):
         releases_gil = False
-        if hasattr(graph.func, "_ptr"):
+        if hasattr(graph, "func") and hasattr(graph.func, "_ptr"):
             releases_gil = graph.func._ptr._obj.releases_gil
         return releases_gil or super(CanReleaseGILAnalyzer, self).analyze_direct_call(graph, seen)
 


More information about the pypy-commit mailing list