[issue13150] Most of Python's startup time is sysconfig

Terry J. Reedy report at bugs.python.org
Wed Oct 12 21:52:06 CEST 2011


Terry J. Reedy <tjreedy at udel.edu> added the comment:

Since #9878 proposes an *alternate* solution to *part* of the sysconfig problem, I disagree with 'supersede'. A Python solution would be more useful for other implementations if enough of the sysconfig info is not CPython specific.

A CPython design feature is that it parses and compiles Python code just once per run, and imported modules just once until the code changes (or might have). For functions, everything possible is put into a behind-the-scenes code object. So even inner functions are parsed and compiled just once.

The problem with sysconfig, it appears, is that lacks the equivalent design feature but instead does the equivalent of re-parsing and re-compiling inner functions with each outer function call.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue13150>
_______________________________________


More information about the Python-bugs-list mailing list