[pypy-dev] Stuff that already exists in Python

RIGO Armin arigo at tunes.org
Thu Jan 16 16:58:33 CET 2003


Hello Christian,

On Mon, Jan 13, 2003 at 04:00:37AM +0100, Christian Tismer wrote:
> This also touches one of my weak points:
> Is it good to replace C code by something
> which is depending on another special module
> like sre?
> This makes sre into something crucial to this
> re-implementation. But I'm not sure if this
> is a good way to go.

As far as performance is concerned, it could be at some stage 
re-implemented in pure Python.  Character handling may be slow but 
it is a good target for Psyco optimization.

> I'm also not sure if it is good to re-implement
> certain modules using the common Python tricks
> and optimizations. To some extent, I have the
> impression that doing it the simple way, basically
> as done in C, would fit the optimizations of
> Psyco better. But that is an open question
> until we get some feedback from Armin Rigo.

That's right; the "simple way" is what Psyco can best work with.  
It does not prevent the definition of abstract classes that
encapsulate the common data structures; on the other hand, these 
classes (with suitable information like types and mutability) are 
quite useful for Psyco, as you already mentionned.


Armin


More information about the Pypy-dev mailing list