Author: Armin Rigo <[email protected]>
Branch: emit-call-x86
Changeset: r64345:ac2bd751b3c4
Date: 2013-05-19 21:02 +0200
http://bitbucket.org/pypy/pypy/changeset/ac2bd751b3c4/
Log: Improve the test
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
@@ -2708,9 +2708,8 @@
loadcodes.append(' ^'[load])
if load:
b2 = b1.clonebox()
- ops += [
- ResOperation(rop.SAME_AS, [b1], b2)
- ]
+ ops.insert(rnd.randrange(0, len(ops)+1),
+ ResOperation(rop.SAME_AS, [b1], b2))
b1 = b2
insideboxes.append(b1)
loadcodes = ''.join(loadcodes)
@@ -2722,6 +2721,11 @@
ResOperation(rop.FINISH, [], None, descr=BasicFinalDescr(0))
]
ops[-2].setfailargs([])
+ # keep alive a random subset of the insideboxes
+ for b1 in insideboxes:
+ if rnd.random() < 0.333:
+ ops.insert(-1, ResOperation(rop.SAME_AS, [b1],
+ b1.clonebox()))
looptoken = JitCellToken()
self.cpu.compile_loop(argboxes, ops, looptoken)
#
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit