threading priority
alecwy at gmail.com
alecwy at gmail.com
Fri Dec 17 18:49:46 EST 2004
I googled as suggested, and the answer isn't crystal clear. My
impression is that the problem is that a python thread must acquire the
GIL in order to execute, and the strategy for deciding which thread
should get the GIL when multiple threads are waiting for it is not
based on priority. Is that correct?
-Alec
Peter Hansen wrote:
> Joe Wong wrote:
>
> > Hi, Is there any way to increase/decrease a thread priority in
Python?
>
> Not really, and as Python does not use a "free-threading" model,
> it wouldn't work as you'd like anyway.
>
> Search Google for "Python GIL" or "Global Interpreter Lock" and you
> should learn enough to see why this is so.
>
> -Peter
More information about the Python-list
mailing list