[pypy-commit] pypy issue-2148: Add incomplete pypyjit test for issue #2148
rlamy
noreply at buildbot.pypy.org
Sun Oct 4 19:18:36 CEST 2015
Author: Ronan Lamy <ronan.lamy at gmail.com>
Branch: issue-2148
Changeset: r79979:aa3aabb40221
Date: 2015-10-04 02:53 +0100
http://bitbucket.org/pypy/pypy/changeset/aa3aabb40221/
Log: Add incomplete pypyjit test for issue #2148
diff --git a/pypy/module/pypyjit/test_pypy_c/test_micronumpy.py b/pypy/module/pypyjit/test_pypy_c/test_micronumpy.py
--- a/pypy/module/pypyjit/test_pypy_c/test_micronumpy.py
+++ b/pypy/module/pypyjit/test_pypy_c/test_micronumpy.py
@@ -248,3 +248,19 @@
guard_false(i157, descr=...)
jump(..., descr=...)
""")
+
+ def test_mixed_div(self):
+ N = 1500
+ def main():
+ N = 1500
+ import _numpypy.multiarray as np
+ arr = np.zeros(N)
+ l = [arr[i]/2. for i in range(N)]
+ return l
+ log = self.run(main, [])
+ assert log.result == [0.] * N
+ loop, = log.loops_by_filename(self.filepath)
+ assert loop.match("""
+ f3 = float_truediv(f1, f2)
+ jump(..., descr=...)
+ """)
More information about the pypy-commit
mailing list