Thread imbalance
Peter Hansen
peter at engcorp.com
Sun Feb 5 12:34:26 EST 2006
Ivan Voras wrote:
> Peter Hansen wrote:
>>Ivan, what makes you say that Python is bad for threads? Did the
>>qualifcation "concurrently executing/computing" have some significance
>>that I missed?
>
> Because of the GIL (Giant interpreter lock).
> ...
> Much can be said about "at the same time" part, but at least in one case
> it is unambiguous: in multiprocessor machines.
Okay, I thought that might be what you were talking about.
I agree that in multiprocessor situations the GIL can be a problem.
I'm equally certain that the GIL is not involved in the OP's problem,
unless he's running custom extensions that he's produced without any
awareness of the GIL.
I'm pretty sure that, for the OP's situation, Python threading is
perfectly fine and the problems he's facing are not inherent, but
related to the way he is doing things. I don't see enough information
in his post to help further though.
-Peter
More information about the Python-list
mailing list