Startup time is regressing

Antoine Pitrou solipsis at pitrou.net
Mon Nov 8 11:16:02 CST 2010


Matt Mackall <mpm <at> selenic.com> writes:
> 
> Some other numbers for comparison:
> 
> python 2.6.6 --version: 0.00501s
> python 2.6.6 -c 'print "hello world"': 0.02431s
> 
> python 3.1.2 --version: 0.00536s
> python 3.1.2 -c 'print("hello world")': 0.04105s

You should use the -E version to Python, so that site-local settings (e.g.
PYTHONPATH) don't interfere in the measurement.
Here:

[2.7]
$ time -p cpython/release2.7-maint/python -E -c "print('hello world')"
hello world
real 0.01
user 0.01
sys 0.00
[3.2]
$ time -p py3k/py3k/python -E -c "print('hello world')"
hello world
real 0.02
user 0.02
sys 0.00





More information about the Mercurial-devel mailing list