Stackless/microthreads merge news

Christian Tismer tismer at tismer.com
Mon Mar 13 13:47:50 EST 2000


Konrad Hinsen wrote:
> 
> wware at world.std.com (Will Ware) writes:
> 
> > The kind of thing you're looking for would involve interrupting the
> > physical processor rather than the Python VM. Unfortunately, all your
> 
> Indeed. But what then are the applications for which one might
> profitably use microthreads? It has to be Python code with no lengthy
> C code execution nor any potentially blocking I/O. Can you really
> get a measurable performance advantage over the standard OS threading?
> I'd expect that the interpreter overhead should be more important than
> the threading overhead. Or is it memory efficiency that you are aiming
> for?

Memory is one issue. You can have thousands of tiny threads inside
the real ones. Switching speed: At the moment, the switching
involves a couple of Python instructions. After things have settled,
the basic functions will vanish into a C module, probably. Then we
have nothing else but continuations switching. That runs at least
3 times faster than real thread switching on Windows.

ciao - chris

-- 
Christian Tismer             :^)   <mailto:tismer at appliedbiometrics.com>
Applied Biometrics GmbH      :     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
     we're tired of banana software - shipped green, ripens at home




More information about the Python-list mailing list