On Tue, 2015-09-29 at 03:05 +0000, bitwise via Digitalmars-d-learn wrote: > On Monday, 28 September 2015 at 11:47:38 UTC, Russel Winder wrote: > > I hadn't answered as I do not have answers to the questions you > > ask. My reason: people should not be doing their codes using > > these low-level shared memory techniques. Data parallel things > > should be using the std.parallelism module. Dataflow-style > > things should be using spawn and channels – akin to the way you > > do things in Go. > > > > So to give you an answer I would go back a stage, forget > > threads, mutexes, synchronized, etc. and ask what do you want > > you workers to do? If they are to do something and return a > > result then spawn and channel is exactly the right abstraction > > to use. Think "farmer–worker", the farmer spawns the workers > > and then collects their results. No shared memory anywyere – at > > least not mutable. > > https://www.youtube.com/watch?v=S7pGs7JU7eM > > Bit
What's the tl;dr as text, I very, very rarely watch videos. -- Russel. ============================================================================= Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.win...@ekiga.net 41 Buckmaster Road m: +44 7770 465 077 xmpp: rus...@winder.org.uk London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
signature.asc
Description: This is a digitally signed message part