Stackless Python, eventual merge?

Christian Tismer tismer at tismer.com
Sun Sep 15 20:24:54 CEST 2002


Martin v. Löwis wrote:
> "David Abrahams" <david.abrahams at rcn.com> writes:
> 
> 
>>I think it still matters. You don't want people who need stackless'
>>capabilities to have to use a non-standard Python forever, do you?
> 
> 
> Unfortunately, the current implementation is processor-dependent; it
> supports x86, SPARC, and PPC only (not really sure about PPC).

Since today it supports X86, Sparc, PPC and Cygwin.

> It also
> limits extensions: if they call back to Python, they must not keep
> "global" variables on the stack (global in the sense that their
> address is known outside their function).
> 
> These limitations require Stackless users to be more aware of the
> inner workings of Python, or they risk crashes - something that would
> be considered a bug in standard Python.

Yes, but :-)
Stackless is built in a way that by default there is no difference
to the standard. No stack switching occours, all is identical.
If you want stackless behavior, you must switch it on.
And if you want to use task switching, you need to import the
stackless extension (which is now apart).

Therefore I'd claim that putting Stackless into the core trunk
would not do any harm. Users who want to use it can use it,
others may ignore it (and it is very tiny, about 50k).

This could be something like the thread package, which also
does not work on all platforms.

ciao - chris
-- 
Christian Tismer             :^)   <mailto:tismer at tismer.com>
Mission Impossible 5oftware  :     Have a break! Take a ride on Python's
Johannes-Niemeyer-Weg 9a     :    *Starship* http://starship.python.net/
14109 Berlin                 :     PGP key -> http://wwwkeys.pgp.net/
work +49 30 89 09 53 34  home +49 30 802 86 56  pager +49 173 24 18 776
PGP 0x57F3BF04       9064 F4E1 D754 C2FF 1619  305B C09C 5A3B 57F3 BF04
      whom do you want to sponsor today?   http://www.stackless.com/






More information about the Python-list mailing list