Author: Alex Gaynor <[email protected]>
Branch: unroll-if-alt
Changeset: r46100:43844f5e9cdc
Date: 2011-07-29 21:05 -0700
http://bitbucket.org/pypy/pypy/changeset/43844f5e9cdc/

Log:    You can't just grab the box of a virtual, call force_box. NOTE:
        this causes a slight regression, strcopycontent now forces boht the
        src and dst boxes, even if the op will be eliminated because it is
        length 0. FIX THIS!

diff --git a/pypy/jit/metainterp/optimizeopt/vstring.py 
b/pypy/jit/metainterp/optimizeopt/vstring.py
--- a/pypy/jit/metainterp/optimizeopt/vstring.py
+++ b/pypy/jit/metainterp/optimizeopt/vstring.py
@@ -466,7 +466,14 @@
         srcstart = self.getvalue(op.getarg(2))
         dststart = self.getvalue(op.getarg(3))
         length = self.getvalue(op.getarg(4))
-        copy_str_content(self.optimizer, src.box, dst.box, srcstart.box, 
dststart.box, length.box, mode, need_next_offset=False)
+        copy_str_content(self.optimizer,
+            src.force_box(),
+            dst.force_box(),
+            srcstart.force_box(),
+            dststart.force_box(),
+            length.force_box(),
+            mode, need_next_offset=False
+        )
 
     def optimize_CALL(self, op):
         # dispatch based on 'oopspecindex' to a method that handles
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to