News for hackers. Stuff that matters.
Re:Why Not Python - the GIL hinders concurrency by yason on Wednesday July 03, 2013 @02:42PM (#5986640)
The standard Python workaround to the GIL is multiprocessing. Multiprocessing is basically a library which spins up a distributed system running locally - it forks your process, and runs workers in the forks. The parent process then communicates with the child processes via unix pipes, TCP, or some such method, allowing multiple cores to be used.

Multiprocessing is the way to do parallelism. Deviating from that should be an exception -- for example, shared memory maps could be used to transfer select data objects instantaneously between the processes instead of serializing/deserializing over a pipe, and only those while still retaining separate process images. Threads were practically invented as a compensation for systems with heavy process image overhead.

I think Python is very Unix in this regard. And that's not a bad thing per se. Unix and Linux can do multiprocessing very efficiently.

Re:Why Not Python - the GIL hinders concurrency by zbowling on Wednesday July 03, 2013 @03:08PM (#5986831)
> Multiprocessing is the way to do parallelism. Deviating from that should be an exception

Unless you have a language that doesn't break down when you use threads. Threads are unquestionably easier and better to use for multiprocessing when they work without the tools you are using breaking that.

Re:Why Not Python - the GIL hinders concurrency by yummyfajitas on Wednesday July 03, 2013 @03:18PM (#5986905)
Multiprocessing is the way to do parallelism.

Nowadays I use Scala/Akka for concurrent event processing. As far as code organization goes it is a lot like multiprocessing. Just s/actor/process/. But unlike unix style forking/IPC, I don't have to waste memory/cpu cycles serializing/deserializing immutable messages just so another process can have a duplicated copy of it.

Re:Why Not Python - the GIL hinders concurrency by dakimov on Wednesday July 03, 2013 @02:52PM (#5986705)
Orly? If your language is handicapped maybe. In normal languages you have no problems with threads, and the assertion that multiprocessing is the way makes no sense.
Re:Why Not Python - the GIL hinders concurrency by lmm on Wednesday July 03, 2013 @05:21PM (#5987612)
It's basically impossible to reason about the correctness of any nontrivial multithreaded program.
Re:Why Not Python - the GIL hinders concurrency by Nursie on Thursday July 04, 2013 @06:45AM (#5990029)
This is true of all programs not written in Z notation...