Hacker News new | past | comments | ask | show | jobs | submit login

Can anyone comment on startup latency and performance early in a run?

One of my use cases for Python is relatively small, short-running scripts, and JIT engines often take a fair amount of runtime before all the optimizations kick in. So I wonder how PyPy does at startup time and whether it's able to leverage its execution speed prowess over brief runtimes - is it still a net performance win in the end, or at least not-worse-than-CPython?




Last I checked we startup faster than CPython. As for early-run-performance. Startup really depends on the total amount of code you have, if you've got a few hundred lines of code the JIT's often warmed up and fast in under half a second. On the other hand if you have a few hundred thousand lines it might take a minute to warm up.


Faster startup sounds nifty :-).

How's performance while the JIT is not yet warmed up, compared to CPython?


Pypy starts a light weight interpreter first (that is probebly just about the same speed as CPython maybe a bit faster) and then only compiles if it sees a recuring pattern.


With the JIT totally disabled I think we're between .8-2x slower, depending on what you're doing.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: