[Python-Dev] Python startup time
Lukasz Langa
lukasz at langa.pl
Thu May 3 20:22:39 EDT 2018
> On May 2, 2018, at 8:57 PM, INADA Naoki <songofacandy at gmail.com> wrote:
>
> Recently, I reported how stdlib slows down `import requests`.
> https://github.com/requests/requests/issues/4315#issuecomment-385584974
>
> For Python 3.8, my ideas for faster startup time are:
>
> * Add lazy compiling API or flag in `re` module. The pattern is compiled
> when first used.
How about go the other way and allow compiling at Python *compile*-time? That would actually make things faster instead of just moving the time spent around.
I do see value in being less eager in Python but I think the real wins are hiding behind ahead-of-time compilation.
- Ł
More information about the Python-Dev
mailing list