[pypy-commit] pypy jit-short_from_state: caching the setfield prioritized over moving the pure int_sub out of the loop
hakanardo
noreply at buildbot.pypy.org
Fri Jul 15 19:39:12 CEST 2011
Author: Hakan Ardo <hakan at debian.org>
Branch: jit-short_from_state
Changeset: r45637:8710093c4d2e
Date: 2011-07-13 18:04 +0200
http://bitbucket.org/pypy/pypy/changeset/8710093c4d2e/
Log: caching the setfield prioritized over moving the pure int_sub out of
the loop
diff --git a/pypy/jit/metainterp/optimizeopt/test/test_optimizeopt.py b/pypy/jit/metainterp/optimizeopt/test/test_optimizeopt.py
--- a/pypy/jit/metainterp/optimizeopt/test/test_optimizeopt.py
+++ b/pypy/jit/metainterp/optimizeopt/test/test_optimizeopt.py
@@ -5485,16 +5485,16 @@
escape(i5)
i4 = int_sub(i2, i1)
setfield_gc(p2, i4, descr=valuedescr)
- jump(p1, i1, i2, p2)
+ jump(p1, i1, i2, p2, i4)
"""
expected = """
[p1, i1, i2, p2, i5]
escape(i5)
- setfield_gc(p2, i5, descr=valuedescr)
- jump(p1, i1, i2, p2, i5)
- """
- #self.optimize_strunicode_loop(ops, expected, preamble)
- self.optimize_loop(ops, preamble)
+ i6 = int_sub(i2, i1)
+ setfield_gc(p2, i6, descr=valuedescr)
+ jump(p1, i1, i2, p2, i6)
+ """
+ self.optimize_strunicode_loop(ops, expected, preamble)
def test_str_slice_1(self):
ops = """
More information about the pypy-commit
mailing list