Remix.run Logo
wanderingmind 7 months ago

How in the world is pypy faster than cpython by almost 2 orders of magnitude. Is pypy normally faster in other benchmarks. If so, why? Can some python expert pitch in?

lights0123 7 months ago | parent | next [-]

PyPy uses just-in-time compilation, so for arithmetic-heavy computations not involving the GC, it should absolutely be faster.

igouy 7 months ago | parent | prev | next [-]

"On average, PyPy is 4.4 times faster than CPython 3.7."

https://pypy.org/

igouy 7 months ago | parent [-]

https://speed.pypy.org/

cuchoi 7 months ago | parent | prev [-]

This is the exact code you would expect pypy to run faster.