pyvm -- faster python

Andrew Dalke dalke at dalkescientific.com
Thu May 12 11:53:11 EDT 2005


Paul Rubin wrote:
> Yes, there are several Python compilers already
     ...
> It's true that CPython doesn't have a compiler and that's a serious
> deficiency.  A lot of Python language features don't play that well
> with compilation, and that's often unnecessary.  So I hope the baseline
> implementation changes to a compiled one before the language evolves
> too much more.

Years ago, presented at one of the Python conferences, was a
program to generate C code from the byte code.  It would still
make calls to the Python run-time library (just as C does to
its run-time library).

The presenter did some optimizations, like not decref at the
end of one instruction when the next immediately does an incref
to it.  The conclusion I recall was that it wasn't faster -
at best a few percent - and there was a big memory hit because
of all the duplicated code.  One thought was that the cache miss
caused some of the performance problems.

Does that count as a compiler?

				Andrew
				dalke at dalkescientific.com




More information about the Python-list mailing list