[racket] Racket and concurrency

From: Harry Spier (vasishtha.spier at gmail.com)
Date: Wed Jul 4 12:36:30 EDT 2012

Firstly thanks also to Robby, Kevin and Rudiger for the detailed replies.

On Tue, Jul 3, 2012 at 1:56 PM, Robby Findler
<robby at eecs.northwestern.edu> wrote:

> Assuming that you have multiple pages to process and that pages take
> some non-trivial amount of time to process (seconds not milliseconds),
> then making separate places to process pages seems like the right
> starting point.
> If you find you want to get to some lower-level granularity (if you're
> seeing too much work still at the page level (ie only 4 pages on an 8
> core machine), then you can then use futures inside the places to
> break things up on a per-line or per-section of the page granularity.

Lets see if I understand you correctly:
If I have 8 cores and I'm processing 8 pages by using 8 places (one
per page processing function) then thats optimal.  But if I have an 8
core machine but am processing 4 pages in parallel by using 4 places
then I can utilize unused cores by using futures within the places.

Harry Spier

Posted on the users mailing list.