Is Stackless Python DEAD?

Christian Tismer tismer at tismer.com
Fri Feb 15 03:27:03 EST 2002


Cameron Laird wrote:

 > In article <mailman.1009806401.11232.python-list at python.org>,
 > Christian Tismer  <tismer at tismer.com> wrote:
 >
 >>Well, it is a little late to answer this, but...
 >>
 >>Michael Hudson wrote:
 >>
 >>
 >>>Martin von Loewis <loewis at informatik.hu-berlin.de> writes:
 >>>
 >>...
 >>
 >>...
 >>
 >>
 >>>>- It adds a field nesting_level to the thread state, without
 >>>> ever checking its value (it just counts the nesting level)
 >>>>
 >>>>
 >>>I imagine this was just for bragging with :)
 >>>
 >>
 >>Yes. I needed a way to track when and why there are still
 >>recursions. At sme pahse I also had the idea to drive
 >>decisions on this when I'm allowed to switch things, but
 >>later I learned that this is the wrong way.
 >>
 > Along with bragging rights, one of the not-obvious-but-
 > easy-to-explain reasons to introspect on recursion depth
 > is as a defense against denial-of-service (or more un-
 > intentional) security hazards.  If you're executing
 > something dynamic enough to give a user a wedge into the
 > execution stack, it's prudent, however crude it might
 > seem, to impose resource limits.  One engineering discovery
 > is that recursion depth can be a useful resource to limit.


The current working copy of Stackless is already running in
a total of 2 KB of C stack on Intel machines.
This limits the area of memory to be monitored for
attacks reasonably.

 >>I'm at a redesign for Stackless 2.2. I hope to make it simpler,
 >>split apart Stackless and optimization, and continuations are
 >>no longer my primary target, but built-in microthreads.
 >>
 > Cool!


The new solution is cool and uncool at the same time.
All my difficult changes to the core have been abandoned.
All magic about Stackless' implementation is gone (sigh).
It is now orthogonal to the Python engine. The interaction
is down to the bare minimum.
The implementation has become ridiculously small.
Portability has changes substantially.
While Stackless is now much less dependant from
Python, it is now very much platform dependant, since
it involves a couple of assembly instructions.
I think this is an advantage, since Python develops
much more quickly than hardware platforms.

watch out for the soon-to-come release candidate - ciao - chris

-- 
Christian Tismer             :^)   <mailto:tismer at tismer.com>
Mission Impossible 5oftware  :     Have a break! Take a ride on Python's
Kaunstr. 26                  :    *Starship* http://starship.python.net/
14163 Berlin                 :     PGP key -> http://wwwkeys.pgp.net/
PGP Fingerprint       E182 71C7 1A9D 66E9 9D15  D3CC D4D7 93E2 1FAE F6DF
       where do you want to jump today?   http://www.stackless.com/







More information about the Python-list mailing list