<div dir="ltr">To finish my timing work I decided to see where Py_InitializeEx_Private() spends its time. The following is a breakdown measured in microseconds running using -E:<div><br></div><div><div>INIT: </div><div>setlocale: 11</div>

<div>envvar: 2</div><div>random init: 2</div><div>interp creation: 15</div><div>thread creation: 6</div><div>GIL: 10</div><div>_Py_ReadyTypes(): 930</div><div>more types: 44</div><div>builtins: 141</div><div>exceptions: 287</div>

<div>sys: 258</div><div>_PyImport_Init: 15</div><div>import hooks: 4</div><div>_PyWarnings_Init(): 15</div><div>ENTERING import_init():</div><div>  PyImport_ImportFrozenModule(_frozen_importlib): 1186</div><div>  interp->importlib: 6</div>

<div>  PyInit_imp(): 15</div><div>  _imp: 3</div><div>  importlib._install(): 876</div><div>  _PyImportZip_Init(): 130</div><div>_PyFaulthandler_Init(): 13</div><div>time: 3</div><div>ENTERING initfsencoding():</div><div>

  codec lookup: 2179</div><div>signals: 120</div><div>tracemalloc: 7</div><div>__main__: 13</div><div>initstdio(): 1568</div><div>warnings module: 4</div><div>initsite(): 9552</div></div></div>