[issue11314] Subprocess suffers 40% process creation overhead penalty

Charles-Francois Natali report at bugs.python.org
Wed Mar 2 14:01:28 CET 2011


Charles-Francois Natali <neologix at free.fr> added the comment:

> pitrou> I think your analysis is wrong. These mmap() calls are for
> pitrou> anonymous memory, most likely they are emitted by the libc's
> pitrou> malloc() to get some memory from the kernel. In other words
> pitrou> they will be blazingly fast.
>
> Are you sure? :-)

Well, it is fast. It's true that mmap is slower than brk, since the
kernel zero-fills the pages, but the overhead probably doesn't come
from this, but more likely from pymalloc or malloc, and also from the
call to _PyBytes_resize in posix_read when the number of bytes read is
smaller than what has been requested.

----------

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


More information about the Python-bugs-list mailing list