time and thread modules.

Michael Gilfix mgilfix at eecs.tufts.edu
Thu Oct 10 11:37:31 EDT 2002


  Yes. When a thread blocks, it yields control and allows python (or
rather the underlying OS) to give time to other threads). Not sure if
it's relevant, but you can also use the yeild () function if you want
to relinquish control as well.

                         -- Mike

On Thu, Oct 10 @ 10:25, sismex01 at hebmex.com wrote:
> Well, not actually but related.
> 
> Does invoking time.sleep() automagically allow a
> thread switch in Python?
> 
> -gustavo

-- 
Michael Gilfix
mgilfix at eecs.tufts.edu

For my gpg public key:
http://www.eecs.tufts.edu/~mgilfix/contact.html




More information about the Python-list mailing list