[Python-Dev] Looking for master thesis ideas involving Python

Martin v. Löwis martin at v.loewis.de
Sun Nov 2 14:05:55 EST 2003

Armin Rigo <arigo at tunes.org> writes:

> On Fri, Oct 31, 2003 at 05:08:36PM +0000, Michael Hudson wrote:
> > > be getting a 12-25% decrease in memory use for the base object,
> > > though.
> > 
> > More than that in the good cases.  Something I forgot was that you'd
> > probably have to knock variable length types on the head.
> Why?

Assuming "to knock on the head" means "to put an end to":

If you put all objects of the same type into a pool, you really want
all objects to have the same side, inside a pool. With that
assumption, garbage objects can be reallocated without causing
fragmentation. If objects in a pool have different sizes, it is not
possible to have an efficient reallocation strategy.

Of course, you could try to make a compacting garbage collector, but
that would break the current programming model even more (as object
references would stop being pointers).


More information about the Python-Dev mailing list