[pypy-svn] r43559 - pypy/branch/prolog-jit-experiments/pypy/jit/hintannotator

cfbolz at codespeak.net cfbolz at codespeak.net
Tue May 22 12:16:52 CEST 2007


Author: cfbolz
Date: Tue May 22 12:16:51 2007
New Revision: 43559

Modified:
   pypy/branch/prolog-jit-experiments/pypy/jit/hintannotator/policy.py
Log:
fix problems


Modified: pypy/branch/prolog-jit-experiments/pypy/jit/hintannotator/policy.py
==============================================================================
--- pypy/branch/prolog-jit-experiments/pypy/jit/hintannotator/policy.py	(original)
+++ pypy/branch/prolog-jit-experiments/pypy/jit/hintannotator/policy.py	Tue May 22 12:16:51 2007
@@ -1,5 +1,6 @@
 from pypy.annotation import policy
 from pypy.annotation.specialize import getuniquenondirectgraph
+from pypy.translator.translator import graphof
 
 class HintAnnotatorPolicy(policy.AnnotatorPolicy):
     novirtualcontainer     = False
@@ -48,7 +49,7 @@
         self.translator = t
         self.bookkeeper = t.annotator.bookkeeper
         self.timeshift_graphs = {}
-        portal = getattr(PORTAL, 'im_func', PORTAL)
+        portal = getattr(self.PORTAL, 'im_func', self.PORTAL)
         portal_graph = graphof(t, portal)
         self.fill_timeshift_graphs(t, portal_graph)
 
@@ -90,15 +91,15 @@
         graphs = graphs_on_the_path_to(self.translator, self._graph(fromfunc),
                                        targetgraphs)
         for graph in graphs:
-            result_graphs[graph] = True
+            self.timeshift_graphs[graph] = True
 
     def seepath(self, *path):
         for i in range(1, len(path)):
             self.seefunc(path[i-1], path[i])
 
     def seegraph(self, func, look=True):
-        graph = _graph(func)
-        result_graphs[graph] = look
+        graph = self._graph(func)
+        self.timeshift_graphs[graph] = look
 
 
 



More information about the Pypy-commit mailing list