[pypy-dev] a faster Python not a primary goal of PyPy?

Armin Rigo arigo at tunes.org
Fri Sep 23 17:23:19 CEST 2005


Hi Bengt,

On Thu, Sep 15, 2005 at 06:46:30PM -0700, Bengt Richter wrote:
> 2) ISTM that you guys will be the first to notice what meta-info will be useful
> to pass into the translator(s) to achieve various results, so I wonder what
> analogies to e.g., C's "volatile" declaration you may want, and what vehicle
> you will want for representing and transmitting such information. Pragmas?
> more -*- cookies -*- ? If you come up with something really good, isn't it
> likely regular python will adopt it, as well as vice versa? 
> 
> The same goes for language syntax changes that don't hide behind a '#' --
> IOW, will you guys wind up with some recommendations for language changes?

I don't think either of this is likely.  We are not suggesting language
changes or seeing the need for some.  And for RPython we can mostly deal
with regular Python syntax with a couple of additional specific objects
that don't require any kind of syntax; for example, as in C there is
sometimes a good reason to use signed or unsigned integers but Python
doesn't have the distinction, we have defined a class "r_uint" which
works like an unsigned integer with the same wrap-around semantics as C.
The translator knows that it can be turned into a simple "unsigned int"
in C.  There is no need for more advanced support.

In general we try hard to keep language changes separated from PyPy,
with the exception of new built-in types providing extra features that
are not really possible in CPython, just like Stackless did -- e.g. the
thunk object space.

> 3) I'm wondering how much of pypy translation technology could be factored out
> to apply to any language translation, and whether there could be a family of
> porting tool spinoffs eventually.

A lot of it.  That's part of our goal: making it applicable to different
languages.

If anyone shows up with a Javascript parser, I'm sure we could together
hack (and translate (and later have a JIT from)) a basic Javascript
interpreter within a few weeks :-)


A bientot,

Armin.



More information about the Pypy-dev mailing list