betreft:Re: [Stackless] Re: [Python-Dev] Stackless Design Q.

Samuel Smith smithsm at
Tue Feb 26 01:13:28 CET 2002

>p.vrijlandt at wrote:
>>Form: Reply
>>Text: (103 lines follow)
>>Hi all,
>>Could a timeslice function in C leave variables in python-code in 
>>any way undefined?
>I don't think so.
>>I think statements in Python should probably be atomic (especially 
>>if one tasklet can get to variables in another)
>Scheduling occours between opcodes. This is safe, since Python
>also does its real thread switching between opcodes.
>There has not been changed much compared to the old Stackless.
>Switching just has become simpler, since I no longer have

I think you would want to have the option of making the atomicity at 
a courser granularity than an opcode. The old uthreads had atomic 
statements. So you can wrapper a set of statements as being atomic.

>to convince the interpreter in a tricky way to leave its
>frame and restart another one.
>I just call a function that switches the current C stack
>fragment. That resumes another interpreter incarnation
>which simply continues.
>Python doesn't notice what's happening, and I'm not going
>to tell it. :-)
>ciao - chris
>Christian Tismer             :^)   <mailto:tismer at>
>Mission Impossible 5oftware  :     Have a break! Take a ride on Python's
>Kaunstr. 26                  :    *Starship*
>14163 Berlin                 :     PGP key ->
>PGP Fingerprint       E182 71C7 1A9D 66E9 9D15  D3CC D4D7 93E2 1FAE F6DF
>      where do you want to jump today?
>Stackless mailing list
>Stackless at


Samuel M. Smith Ph.D.

360 W. 920 N.
Orem, Utah 84057

801-226-7607 x112 (voice)
801-226-7608 (fax) (web)

Stackless mailing list
Stackless at

More information about the Stackless mailing list