Nat Goodspeed wrote:
I think the *right* design would be a concurrent equivalent of generic programming, where the only fundamental building blocks should be a well-designed statically typed SPSC queue, move semantics, a low-level thread launching utility (such as boost::thread) and a concise generic EDSL for the linking of nodes with queues. All further abstractions can be built on top of those ingredients (a bit like the STL is built on top of templates). It should allow me to do something like this:
start(readfile(input) | runlengthenc | huffmanenc | writefile(output));
At some point I want to publish a proposal for a library that does exactly this, but I need to find more time to work on it. The good news is that all necessary ingredients appear to already exist with C++11, Boost.Proto and Boost.Lockfree.
[OT, sorry...] Julian, are you familiar with this pipeline proposal? http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3534.html
No I wasn't! Thanks a lot for making me aware of it. It is almost exactly what I had in mind, except that the authors seem to not have realised the full generality of the approach. This worries me. Has the proposal progressed far towards standardization already? If I want to react to this proposal so that the standards committee knows about it, what should I do? Cheers, Julian