User:Ajak/Portage Performance

= Portage performance notes =

I've noticed some odd things with regard to Portage performance. I'm documenting them here so I have a public way to reference them.

cpython vs pypy
mgorny has noticed that pypy3 is much faster for dependency calculations (for him). In his blog post, he notes that many people were not able to reproduce his results. I surmise that much of this is due to few people realizing that  drastically affects pypy performance. With that flag on, Portage compiles C extensions, while pypy.org's performance page notes, "Any C extension module recompiled with PyPy takes a very large hit in performance. PyPy supports C extension modules solely to provide basic functionality."

Once I turn that flag off, I can indeed produce a similar speedup:

However, even with this change, some people still report no significant change between cpython and pypy.

Anecdotally, I've noticed that package merges are much slower with pypy3 (as opposed to just dependency calculations as above). I haven't found a package with which I can reproducibly demonstrate the performance difference.