On 2/4/14 9:15 AM, Daniel Hackney wrote:
My message was delayed for a few months in the purgatory of moderation,
so the info in the original email is somewhat out of date. I wrote a
summary of my findings in the file "capstone.pdf" here:
https://db.tt/JNcSdrIe
The moral of the story is that I got up to a 2x speedup with around 10
tasks (in Rust 0.8). There is a sequential bottleneck somewhere,
probably when it is collecting the results from the separate tasks into
a single array. I've thought of some ways it might be possible to
parallelize that, but haven't implemented it.
This is very cool. Have you tried using the workqueue [1]? This is a new
feature that we're using throughout Servo that reduces task spawning
overhead for data-parallel operations. It also keeps the number of tasks
down to a minimum, to reduce memory usage.
Eliminating the bottleneck from collecting the results from the separate
tasks into one array might be accomplished by using a concurrent array
data structure. (One doesn't exist for Rust yet, but it'd be an
excellent opportunity to write one.) :)
Patrick
[1]:
https://github.com/mozilla/servo/blob/master/src/components/util/workqueue.rs
_______________________________________________
dev-servo mailing list
dev-servo@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-servo