fromAntocuni
2 weeks agoPython
Inside CPython's attribute lookup - Antonio Cuni's blog
Attribute lookup in Python is more complex than checking instance __dict__ then type; descriptors, instance vs type lookup, and metaclasses affect behavior.
Readers brave enough to run translate.py to translate PyPy by themselves surely know that the process takes quite a long time to complete, about a hour on super-fast hardware and even more on average computers. Unfortunately, it happened that translate.py was a bad match for our JIT and thus ran much slower on PyPy than on CPython. One of the main reasons is that the PyPy translation toolchain makes heavy