[Python-Dev] A new JIT compiler for a faster CPython?

Stefan Behnel stefan_ml at behnel.de
Wed Jul 18 08:27:14 CEST 2012


martin at v.loewis.de, 18.07.2012 07:53:
> [Victor Stinner]
>> I don't want to write my own library to generate machine code.
> 
> I plan to use nanojit.

As I said, generating machine code is the uninteresting part of it and
won't give you much of a win. The changes you make to the way the code
works while walking the path from seeing the Python code to generating
machine code is what makes the difference.

You could even skip the machine code generation all together and just go
with triggering pre-implemented high-level patterns from the interpreter.
If you code up the right patterns, your win would be bigger than with a
bare 1:1 mapping from Python code to machine code. Both Cython and WPython
are clear examples for that.

Stefan



More information about the Python-Dev mailing list