[Python-Dev] Re: Who cares about the performance of these opcodes?

A.M. Kuchling amk at amk.ca
Tue Mar 9 12:20:31 EST 2004


On Tue, 09 Mar 2004 08:59:52 -0500, Phillip J. Eby <pje at telecommunity.com> 
wrote:
> I personally don't think it'll help much, if the goal is to reduce cache 
> misses.  After all, the code is all still there.  But, it should not do

For a planned PyCon lightning talk, I'm benchmarking various combinations 
of optimizer options.
One interesting result: CVS Python gets 25997 pystones on my machine when 
compiled with
-O3 (the default), but 26707 when compiled with gcc's -Os flag.  -Os 
optimizes for size,
running the subset of the -O2 optimizations that don't increase code size.

The test script is http://www.amk.ca/files/misc/python-opt-benchmark.sh, 
should anyone want
to run it.  I'm now trying to figure out if -mregparm makes any 
significant difference to Python's
performance.

--amk




More information about the Python-Dev mailing list