how fast is Python?

Michele Simionato mis6 at
Sat Aug 23 13:18:12 CEST 2003

Alex Martelli <aleax at> wrote in message news:<qJ%0b.116361$cl3.3506646 at>...
> Irmen de Jong wrote:
>    ...
> > Nevertheless, a Psyco-optimized piece of Python code
> > that runs as fast as compiled C is still very impressive
> > to me. I know that JIT compiler technology theoretically
> > could produce better optimized code than a static optimizing
> > compiler, but am happy already if it reaches equal level :-)
> If anybody does have an actual example (idealy toy-sized:-)
> where psyco's JIT does make repeatably faster code than a
> C compiler (well-used, e.g. -O3 for gcc, NOT just -O...!-)
> I'd be overjoyed to see it, by the way.
> Alex

Actually, as I posted in the C sharp thread of few weeks ago, on my
machine psyco+psyco was FASTER than C. The numbers quoted are for C
option -o, but even for -o3 psyco was still faster and, notice, with
pow(x,2) replacedby x*x in C too. I would be happy if somebody can
reproduce that. Here is the link:*%2Bgroup%253Acomp.lang.python.*%26meta%3Dgroup%253Dcomp.lang.python.*

Michele Simionato, Ph. D.
MicheleSimionato at
--- Currently looking for a job ---

More information about the Python-list mailing list