[phobos] std.parallelism: Request for review/comment
Lars Tandle Kyllingstad
lars at kyllingen.net
Tue Aug 31 06:34:18 PDT 2010
I ran my calculation on an 8-core at work, by the way, and it was very enjoyable to see a manyfold speed-up just by changing a few lines of code.
We should definitely get this into Phobos.
-Lars
----- Reply message -----
From: "David Simcha" <dsimcha at gmail.com>
Date: Tue, Aug 31, 2010 14:13
Subject: [phobos] std.parallelism: Request for review/comment
To: "Discuss the phobos library for D" <phobos at puremagic.com>
On 8/31/2010 6:22 AM, Lars Tandle Kyllingstad wrote:
> Point (3) is pretty cool. I just used your module for my current
> project at work, and the ability to get the index made the code a lot
> nicer.
>
> Another question: Why have you chosen the default number of work units
> to be just two units per thread? In my experience, it's not uncommon
> that calculations are harder on some parts of the range than others, and
> then there is a risk of some cores running out of work to do. I'd think
> that having more work units, 3-4 per thread, say, would allow for better
> distribution of work between cores.
>
> -Lars
Good point. I should probably change this, as the more I think about it
the more I realize that I never use the default for the reason you
mention. It seemed like a good idea in iteration 1, and then I just
never reconsidered.
_______________________________________________
phobos mailing list
phobos at puremagic.com
http://lists.puremagic.com/mailman/listinfo/phobos
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/phobos/attachments/20100831/66eaafd6/attachment.html>
More information about the phobos
mailing list