Concurrency and Parallelism in Go (Short Post)

According to Rob Pike’s talk “Concurrency is not Parallelism”, Go is a primarily a concurrent language and the parallelism is a bi-product. He defines concurrency as the composition of independently executing processes and parallelism as the simultaneous execution of multiple “things” ( I presume he means processes in this case). Based on the CSP model defined in C.A.R. Houre’s 1978 paper ‘Communicating Sequential Processes (CACM)’, Go is a language focused around program structure and design. This essentially means that Go excels at solving certain types of parallel problems but is not be suitable for all such problems. This is a key thing to note as the usual hype surrounding  the hottest new language leads to the said language (Go in this case) being misused and/or abused. I would say that Go is designed primarily to handle non-determinism and program complexity (That’s the main advantage of the CSP model employed). If every part of your program is simple and deterministic by nature then you should consider looking at using a different language to handle the task of pure parallelism.

Recommended Read:

This issue is discussed and debated in the yosefk blog and its comments (recommended read) where the author of the blog challenges some of the statements made by the concurrency fan boys.

Golang Concurrency Motto :Do not communicate by sharing memory; instead, share memory by communicating.

The clash between concurrency and parallelism in practice

Comments   

0 #3 Jon Kerridge 2013-12-17 13:31
We discussed how he should undertake his experiments; stressing that he must run the algorithm several times and then take the average time over the several (10) runs, perhaps excluding the longest. He might want to ensure that the system garbage collects beffore each run of the algorithm.
Make sure you use the same framework for each function you test.
Do use powers of 2 for the string size, say starting from 256
Have a justified reason for every decisiion you make and ensure you discyuss it in the methodolgy chapter.

Keep notes of what you do so that writing up is easier.
Quote
0 #2 Jon Kerridge 2013-11-19 13:52
You need to focus on the week 9 report
What you have read, why and what you have learnt from the reading
You need to say what you have done practically so far; how was this influenced by your reading and how will it influence what you do in the future
Write up a plan of things to be done to complete the project; major headings and anticipated time sscales.
Need to write up an evaluation plan so that you can collect the required data during the experimnetal phase
Quote
0 #1 Jon Kerridge 2013-11-11 04:29
Glad to see you are still out there!

What you say is all good stuff for your week 9 report so keep going!
Quote

Add comment


Security code
Refresh