performance difference between OSx and Windows

Avizoa at gmail.com Avizoa at gmail.com
Sun May 21 22:05:21 EDT 2006


> Can I ask why that is, and if there is a way to take advantage
> of all 4 within python?

Sure. All major programming languages handle concurrency in one of two
ways: multithreading or parallel processes. In the standard python
interpreter, there is the Global Interpreter Lock (GIL for short) that
only allows one thread to run at once. So your option for python are
limited to running multiple processes or using a different interpreter.

What you are testing, however, is not easily parallizable since the
slow concat in particular is very dependent on sequential results. If
you want test the quad cores you'll have to run the test multiple times
with many different threads to truly stress them.




More information about the Python-list mailing list