Author: Maciej Fijalkowski <[email protected]>
Branch: callback-jit
Changeset: r59572:7f535e6ede3f
Date: 2012-12-26 21:59 +0200
http://bitbucket.org/pypy/pypy/changeset/7f535e6ede3f/
Log: hack differently
diff --git a/pypy/jit/metainterp/warmspot.py b/pypy/jit/metainterp/warmspot.py
--- a/pypy/jit/metainterp/warmspot.py
+++ b/pypy/jit/metainterp/warmspot.py
@@ -290,11 +290,13 @@
callgraph = inlinable_static_callers(self.translator.graphs,
store_calls=True)
new_callgraph = []
new_portals = set()
+ inlined_jit_merge_points = set()
for caller, block, op_call, callee in callgraph:
func = getattr(callee, 'func', None)
_inline_jit_merge_point_ = getattr(func,
'_inline_jit_merge_point_', None)
if _inline_jit_merge_point_:
_inline_jit_merge_point_._always_inline_ = True
+ inlined_jit_merge_points.add(_inline_jit_merge_point_)
op_jmp_call, jmp_graph = get_jmp_call(callee,
_inline_jit_merge_point_)
#
# now we move the op_jmp_call from callee to caller, just
@@ -315,6 +317,9 @@
# inline them!
inline_threshold = 0.1 # we rely on the _always_inline_ set above
auto_inlining(self.translator, inline_threshold, new_callgraph)
+ # clean up _always_inline_ = True, it can explode later
+ for item in inlined_jit_merge_points:
+ del item._always_inline_
# make a fresh copy of the JitDriver in all newly created
# jit_merge_points
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit