INADA Naoki <songofaca...@gmail.com> added the comment:

> i did 2 implementations in both python and pure bash, python takes about 
> 500ms to run while bash is more than 10 times faster.

VM startup + `import site` are done in 10~20ms on common Linux machine.
It won't take 500ms.

While Python VM startup is not lightning fast, library import time is much 
slower than VM startup in many cases.  And since "importing library" may have 
many important side effects, we can't "pre warm" it.

Have you tried `PYTHONPROFILEIMPORTTIME=1` environment variable added by Python 
3.7?
https://dev.to/methane/how-to-speed-up-python-application-startup-time-nkf

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue34296>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to