John Belmonte <> changed:

           What    |Removed                     |Added
                 CC|                            |

--- Comment #1 from John Belmonte <> 2012-06-09 20:01:48 PDT ---
Looking at source I see the original version includes TaskPool.join() which has
the desired behavior.  However the method definition is disabled:

In 2011 dsimcha mentioned the join function [1]:

    "One thing Andrei mentioned that I'm really not sure about is what to do 
with TaskPool.join().  My example for it is still terrible, because I 
think it's an evolutionary artifact.  It was useful in earlier designs 
that were never released and didn't have high-level data parallelism 
primitives.  I never use it, don't have any good use cases for it and 
would be inclined to remove it entirely.  Andrei seems to have some good 
use cases in mind, but he has not detailed any that I believe are 
reasonably implementable and I'm not sure whether they could be solved 
better using the higher-level data parallelism primitives."


    "I put TaskPool.join() in a version(none) statement and removed all 
references to it from the documentation.  If anyone has a compelling 
reason why this is useful (preferably with a good, short example), I'll 
add it back.  Otherwise, it's gone, since IMHO it's an evolutionary 
artifact that makes sense in theory but that I can't think of a use for 
anymore in practice."

Well, I have a use case :)  I'm writing a D implementation of luaproc, the Lua
share-nothing message passing framework described in "Exploring Lua for
Concurrent Programming" [2].  The std.parallelism module nicely replaces
several hundred lines of low level multithreading code in the original C
implementation.    The design requires a single queue of tasks serviced by
multiple threads, where the tasks do not yield a return value (they only
optionally schedule more tasks), and any errors within a task are discarded
(i.e. exceptions don't need to be propagated to parent tasks).  The design
specifies a function which blocks on the completion of all tasks, and this is
the only thing std.parallelism is missing.


Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to