Author: Armin Rigo <[email protected]>
Branch: guard-compatible
Changeset: r83041:d99d2e0e37bb
Date: 2016-03-14 13:47 +0100
http://bitbucket.org/pypy/pypy/changeset/d99d2e0e37bb/
Log: add test for db4dc094a002
diff --git a/rpython/jit/backend/test/runner_test.py
b/rpython/jit/backend/test/runner_test.py
--- a/rpython/jit/backend/test/runner_test.py
+++ b/rpython/jit/backend/test/runner_test.py
@@ -191,9 +191,10 @@
assert res == 10
def test_extend_guard_compatible(self):
+ import weakref, gc
+
t1_box, T1_box, d1 = self.alloc_instance(self.T)
t2_box, T2_box, d2 = self.alloc_instance(self.T)
- t3_box, T3_box, d3 = self.alloc_instance(self.T)
faildescr1 = BasicFailDescr(1)
loop = parse("""
[p0]
@@ -222,6 +223,11 @@
fail = self.cpu.get_latest_descr(deadframe)
assert fail.identifier == 2
+ wr = weakref.ref(t2_box.getref_base())
+ del t2_box, T2_box, d2
+ gc.collect(); gc.collect()
+ assert wr() is not None # kept alive by grow_guard_compatible_switch
+
def test_compile_with_holes_in_fail_args(self):
targettoken = TargetToken()
loop = parse("""
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit