Multithreaded C API Python questions
Hendrik van Rooyen
mail at microcorp.co.za
Fri Nov 10 00:33:42 EST 2006
"Svein Seldal" <"svein at seldal dot com">wrote:
8<---------------------------------------------------
> I am dependent upon the ability to have to threads executing in python
> land at the same time. How can this be done?
call time.sleep(0.001) in each, as well as the main thread, to politely give the
rest a chance....
Fiddle with the sleep times in your setup to get the best performance - and
don't be misled into thinking that faster is better - its not always true -
there comes a point where the overhead of swapping a thread consumes the total
resource of the process, and no work gets done.
- HTH
- Hendrik
More information about the Python-list
mailing list