Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upDifferent number for values for python_startup and python_startup_no_site between CPython 2.7 and PyPy 2.7 #31
Comments
|
You should be able to use "python3 -m perf compare_to ref.json patch.json" command to compare your two benchmark results. In perf, a warning is emitted if perf cannot check if the difference is significant. It doesn't crash. We should probably do the same in performance. Or maybe rewrite performance using perf compare? |
The problem
I tried to compare the performance results between different Python versions and implementations. While the comparison between CPython 3.6 and CPython 2.7 works as expected, I get an exception when comparing the results obtained with CPython 2.7.13 and PyP 2.7.13.
Exact versions:
CPython:
PyPy:
How to reproduce the issue
Run from CPython 2 environment:
Run from PyPy environment:
Compare:
What you expected to happen
I expected table like this:
+-------------------------+-----------+-------------+-----------------+-------------------------+
| Benchmark | py27.json | pypy27.json | Change | Significance |
+=========================+===========+=============+=================+=========================+
| 2to3 | 767 ms | 1.63 sec | 2.13x slower | Significant (t=-142.45) |
+-------------------------+-----------+-------------+-----------------+-------------------------+
| chaos | 215 ms | 5.58 ms | 38.62x faster | Significant (t=204.35) |
+-------------------------+-----------+-------------+-----------------+-------------------------+
What actually happens
I get this exception:
Note: The line number my have change do to my debug prints.
Cause
The number of values for the benchmarks
python_startupandpython_startup_no_siteare different, i.e. 200 for CPython and 60 for PyPy (same numbers for both benchmarks)My work around
I just skipped
python_startupandpython_startup_no_sitewith:in compare.compare_results:
Suggested better solution
Either: