Author: Antonio Cuni <[email protected]>
Branch: ffistruct
Changeset: r47185:3acdc8abbdc4
Date: 2011-09-09 15:35 +0200
http://bitbucket.org/pypy/pypy/changeset/3acdc8abbdc4/

Log:    another unit test for when not to optimize

diff --git a/pypy/jit/metainterp/optimizeopt/test/test_optimizefficall.py 
b/pypy/jit/metainterp/optimizeopt/test/test_optimizefficall.py
--- a/pypy/jit/metainterp/optimizeopt/test/test_optimizefficall.py
+++ b/pypy/jit/metainterp/optimizeopt/test/test_optimizefficall.py
@@ -303,3 +303,13 @@
         jump(i1)
         """
         loop = self.optimize_loop(ops, expected)
+
+    def test_ffi_struct_fields_nonconst(self):
+        ops = """
+        [i0, i1]
+        i2 = call(0, ConstClass(ffi_slong), i0, i1,  
descr=libffi_struct_getfield)
+        i3 = call(0, i1                   , i0, 123, 
descr=libffi_struct_getfield)
+        jump(i1)
+        """
+        expected = ops
+        loop = self.optimize_loop(ops, expected)
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to