Python too slow?

Hrvoje Niksic hniksic at xemacs.org
Fri Jan 11 09:41:20 EST 2008


Bruno Desthuilliers <bruno.42.desthuilliers at wtf.websiteburo.oops.com>
writes:

> fact 1: CPython compiles source code to byte-code.
> fact 2: CPython executes this byte-code.
> fact 3: Sun's JDK compiles source code to byte-code.
> fact 4: Sun's JDK executes this byte-code.
>
> Care to prove me wrong on any of these points ? Don't bother: you
> can't.

Fact 4 is misleading because it is only one option available to Sun's
JDK.  Sun's JDK is also capable of transforming the byte-code to
native code and letting the processor execute that instead of the
original byte code, and that is where the most significant speed
increase comes from.  Most importantly, it does so automatically, by
default, with no programmer intervention or configuration, and with
100% compatibility, so it doesn't compare well to Python accelerators
like psyco.



More information about the Python-list mailing list