Python too slow?

bruno.desthuilliers at gmail.com bruno.desthuilliers at gmail.com
Sat Jan 12 11:52:16 EST 2008


On 11 jan, 15:41, Hrvoje Niksic <hnik... at xemacs.org> wrote:
> Bruno Desthuilliers <bruno.42.desthuilli... 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.

Then fact 1 is misleading too since Python handles the compilation
automatically without programmer's intervention while Java requires
someone to explicitely invoke the byte-code compiler.

I just don't understand what's all that fuss with this simple and
quite comparison of Java and Python. You can google this ng archives,
you'll find hundreds of posts saying the same thing, and everyone so
far seemed to be smart enough to understand that this had nothing to
do with the byte-code specifications, VM implementation and presence
or absence of a JIT compiler.

Anyway, I do maintain that what I said is 100% correct, 100% accurate
given the context, and 0% misleading unless you're clueless enough to
not be able to parse a single english sentence (in which case I just
can't help). As a matter of fact, this didn't seem to "mislead" the OP
into thinking such a thing.

Regards.



More information about the Python-list mailing list