[Python-Dev] Re: Re: Who cares about the performance of these
amk at amk.ca
Wed Mar 10 07:48:54 EST 2004
On Wed, 10 Mar 2004 09:07:04 +1100 (EST), Andrew MacIntyre
<andymac at bullseye.apana.org.au> wrote:
> In my own experiments along these lines, I found that the best results
> with various versions of gcc (2.8.1, 2.95.2, 3.2.1 on OS/2; 2.95.4,
> 3.3.2 on FreeBSD) was to compile ceval.c with -Os (-O2 on 2.8.1, which
> doesn't have -Os) and the rest of Python with -O3.
That seems to roughly match what I'm seeing; I haven't tried compiling
Python on different optimization settings.
Python doesn't use any architecture-specific settings such as -march=i686
the -fast setting Bob Ippolito mentions. Most Python installations are
on the same machine they're compiled on, so maybe we could add a
--optimize-for-arch switch to configure that took no arguments and figured
the right arch-specific compiler arguments for the current machine.
Eventually we could
enable it by default and provide a switch to turn it off.
More information about the Python-Dev