[pypy-dev] Talk in the Supercomputing Day, Madrid

Maciej Fijalkowski fijall at gmail.com
Wed Jan 14 10:10:36 CET 2009

Hi Guillem

> I think that you'll have to start explaining what a JIT is. See the note on the
> audience below. I've been using Python+Numpy+Scipy+... as a complete replacement
> for matlab for the last two years. I suggested all of my colleagues to do the
> same but they all believe that python is a toy language (!). I think that you
> could give a more authorized opinion on this.

The JIT is a just-in-time compiler that compiles some intermediate
representation (for example python bytecode), to native code (for
example x86 assembler). The only existing JIT for python, psyco
(http://psyco.sourceforge.net) also massively specializes operations,
which means it gives much greater speedups than just getting read of
bytecode dispatch. It also gets read of type dispatching. For simple
loops with integer operations it can give speedups up to non-optimized
C (gcc -O0). PyPy is in some sense a followup project to psyco, which
should give you much larger benefits at some point in the future.

The exact gap that you might be interested in is the difference of
performance between numpy operations (which are rather fast, since
they're calling to years old fortran code) and a situation where you
need to for example iterate over the whole array and do some
computations in python (which is deadly slow).

I cannot really judge how python compares to matlab in terms of
availability of mathematic routines (scipy + numpy), but it's surely
nicer language and if it's fast enough, it could be a real win.

Now regarding pypy, the status is that we don't even have a numpy
bindings. And while we're surely working a lot on JIT these days, it's
still not ready for production use. So speaking about what we could
possibly do with jit & numpy is a bit speculative (but just a bit,
it's rather obvious how it could work, it's just not there yet).

Well, regarding toyness of a language, it's really hard to discuss
with such vague argument. If you provide us a reasoning why python is
a toy language we can try to provide you with some argumentation :)
>From my POV I can say that I wouldn't write a serious project size of
pypy in a toy language.

Maciej Fijalkowski

More information about the Pypy-dev mailing list