-
Book Overview & Buying
-
Table Of Contents
-
Feedback & Rating
Parallel Programming with Python
By :
There is a certain confusion when we try to define the main forms of paralleling systems. It is common to find quotations on parallel and concurrent systems as if both meant the same thing. Nevertheless, there are slight differences between them.
Within concurrent programming, we have a scenario in which a program dispatches several workers and these workers dispute to use the CPU to run a task. The stage at which the dispute takes place is controlled by the CPU scheduler, whose function is to define which worker is apt for using the resource at a specific moment. In most cases, the CPU scheduler runs the task of raking processes so fast that we might get the impression of pseudo-parallelism. Therefore, concurrent programming is an abstraction from parallel programming.
Concurrent systems dispute over the same CPU to run tasks.
The following diagram shows a concurrent program scheme:

Concurrent programming scheme.
Parallel programming can be defined as an approach in which program data creates workers to run specific tasks simultaneously in a multicore environment without the need for concurrency amongst them to access a CPU.
Parallel systems run tasks simultaneously.
The following figure shows the concept of parallel systems:

Parallel programming scheme.
Distributed programming aims at the possibility of sharing the processing by exchanging data through messages between machines (nodes) of computing, which are physically separated.
Distributed programming is becoming more and more popular for many reasons; they are explored as follows:
Distributed systems run tasks within physically-separated nodes.
The following figure shows a distributed system scheme:

Distributed programming scheme.
Change the font size
Change margin width
Change background colour