[pypy-issue] [Bitbucket] Issue #1792: SymPy (a pure Python library) runs multiple times slower than in CPython (pypy/pypy)

Armin Rigo issues-reply at bitbucket.org
Wed Jul 2 17:56:19 CEST 2014


--- you can reply above this line ---

Issue 1792: SymPy (a pure Python library) runs multiple times slower than in CPython
https://bitbucket.org/pypy/pypy/issue/1792/sympy-a-pure-python-library-runs-multiple

Armin Rigo:

sympy is pure Python, but it is a well-known hard program to optimize for PyPy, because it contains code that is extremely tracing-JIT-unfriendly.  Nevertheless, the official PyPy 2.3 gets me these results:

    time pypy x.py           real    0m10.964s
    time python2 x.py     real    0m11.086s

As Ben mentioned, the real problem is the warm-up time, which is extremely large in sympy.  If I add a "while" loop in your example, repeating the whole program, then the time above is only the first iteration; the second one runs in 3.5 seconds and after about 10 iterations it takes 2.2 seconds.  So this can be classified as an issue of the warm-up time.


--

Unsubscribe from issue emails for this repository.
https://bitbucket.org/pypy/pypy/issue/1792/unsubscribe/pypy-issue/d8d4477e9c650fb1a6d4877f8bbfd750a0122684/


More information about the pypy-issue mailing list