[concurrency] Common Concurrent Problems

Pete pfein at pobox.com
Wed Jun 10 05:16:32 CEST 2009

On Jun 9, 2009, at 4:49 PM, Garrett Smith wrote:

> ----- "Aahz" <aahz at pythoncraft.com> wrote:
>> What about a spider?  Feel free to rip this off and rewrite as
>> multiple processes (preferably with credit but I don't really care):

I worry that adding sockets into the mix complicates things (for this  
purpose anyway - sockets aren't all that complicated once you  
understand them).  Also, this needs to be a problem that can be solved  
using arbitrary techniques, not necessarily multiple threads/processes  
(gotta make room for Twisted & friends, after all).

I think the multi-file tail|grep works well here:

  * actually concurrent
  * everyone understands files
  * amenable to a variety of solutions
  * allows simplification while still being mostly correct (the  
incomplete line issue)

> What about parallel quick sort? This seems to me almost a "hello  
> world"
> version of a parallel algorithm. No IO though.

Hmm, it seems we've got two types of concurrency:
  * using multiple CPUs simultaneously
  * "concurrent" I/O - let's just interpret this as "not grinding to a  
halt while waiting for input"

Do we need two different problems (ugh)?  At a minimum, a better  
definition of terms for use on the wiki/brain seems desirable.

I'd rather be the consensus taker than the decision maker, so speak  
up. ;-)


More information about the concurrency-sig mailing list