Concurrent Programming Paradigms, a Comparison in Scala

Date Added: May 2009
Format: PDF

There is a rapid rise of multi-cores in recent hardware architectures. To exploit computational power of multi-core architectures, software should shift to be as concurrent as possible; and therefore should have concurrency control mechanisms. There are different concurrency programming paradigms such as locking and conditions, non-blocking algorithms, actors and Software Transactional Memory (STM). There is a need to compare these approaches in terms of ease of use and performance. This paper implements three fundamental cases of credit transfer, producer-consumer and token ring with different paradigms in Scala and the quantitative and qualitative results of the experiments are presented. Besides an STM implementation in Scala is presented.