concurrency (computer science)
   HOME

TheInfoList



OR:

Concurrency refers to the ability of a system to execute multiple tasks through simultaneous execution or time-sharing (context switching), sharing resources and managing interactions. Concurrency improves responsiveness, throughput, and scalability in modern computing, including: * Operating systems and embedded systems * Distributed systems,
parallel computing Parallel computing is a type of computing, computation in which many calculations or Process (computing), processes are carried out simultaneously. Large problems can often be divided into smaller ones, which can then be solved at the same time. ...
, and
high-performance computing High-performance computing (HPC) is the use of supercomputers and computer clusters to solve advanced computation problems. Overview HPC integrates systems administration (including network and security knowledge) and parallel programming into ...
* Database systems, web applications, and
cloud computing Cloud computing is "a paradigm for enabling network access to a scalable and elastic pool of shareable physical or virtual resources with self-service provisioning and administration on-demand," according to International Organization for ...


Related concepts

Concurrency is a broader concept that encompasses several related ideas, including: * Parallelism (simultaneous execution on multiple processing units). Parallelism executes tasks independently on multiple CPU cores. Concurrency allows for multiple ''threads of control'' at the program level, which can use parallelism or time-slicing to perform these tasks. Programs may exhibit parallelism only, concurrency only, both parallelism and concurrency, neither. * Multi-threading and multi-processing (shared system resources) *
Synchronization Synchronization is the coordination of events to operate a system in unison. For example, the Conductor (music), conductor of an orchestra keeps the orchestra synchronized or ''in time''. Systems that operate with all parts in synchrony are sa ...
(coordinating access to shared resources) * Coordination (managing interactions between concurrent tasks) *
Concurrency Control In information technology and computer science, especially in the fields of computer programming, operating systems, multiprocessors, and databases, concurrency control ensures that correct results for concurrent operations are generated, whil ...
(ensuring data consistency and integrity) *
Inter-process Communication In computer science, interprocess communication (IPC) is the sharing of data between running Process (computing), processes in a computer system. Mechanisms for IPC may be provided by an operating system. Applications which use IPC are often cat ...
(IPC, facilitating information exchange)


Issues

Because computations in a concurrent system can interact with each other while being executed, the number of possible execution paths in the system can be extremely large, and the resulting outcome can be indeterminate. Concurrent use of shared
resources ''Resource'' refers to all the materials available in our environment which are Technology, technologically accessible, Economics, economically feasible and Culture, culturally Sustainability, sustainable and help us to satisfy our needs and want ...
can be a source of indeterminacy leading to issues such as deadlocks, and
resource starvation In computer science, resource starvation is a problem encountered in concurrent computing where a process is perpetually denied necessary resources ''Resource'' refers to all the materials available in our environment which are Technology, te ...
. Design of concurrent systems often entails finding reliable techniques for coordinating their execution, data exchange, memory allocation, and execution scheduling to minimize response time and maximise throughput.


Theory

Concurrency theory has been an active field of research in
theoretical computer science Theoretical computer science is a subfield of computer science and mathematics that focuses on the Abstraction, abstract and mathematical foundations of computation. It is difficult to circumscribe the theoretical areas precisely. The Associati ...
. One of the first proposals was Carl Adam Petri's seminal work on Petri nets in the early 1960s. In the years since, a wide variety of formalisms have been developed for modeling and reasoning about concurrency.


Models

A number of formalisms for modeling and understanding concurrent systems have been developed, including: * The parallel random-access machine * The actor model * Computational bridging models such as the bulk synchronous parallel (BSP) model * Petri nets * Process calculi ** Calculus of communicating systems (CCS) ** Communicating sequential processes (CSP) model ** π-calculus * Tuple spaces, e.g., Linda * Simple Concurrent Object-Oriented Programming (SCOOP) * Reo Coordination Language * Trace monoids Some of these models of concurrency are primarily intended to support reasoning and specification, while others can be used through the entire development cycle, including design, implementation, proof, testing and simulation of concurrent systems. Some of these are based on
message passing In computer science, message passing is a technique for invoking behavior (i.e., running a program) on a computer. The invoking program sends a message to a process (which may be an actor or object) and relies on that process and its supporting ...
, while others have different mechanisms for concurrency. The proliferation of different models of concurrency has motivated some researchers to develop ways to unify these different theoretical models. For example, Lee and Sangiovanni-Vincentelli have demonstrated that a so-called "tagged-signal" model can be used to provide a common framework for defining the
denotational semantics In computer science, denotational semantics (initially known as mathematical semantics or Scott–Strachey semantics) is an approach of formalizing the meanings of programming languages by constructing mathematical objects (called ''denotations'' ...
of a variety of different models of concurrency, while Nielsen, Sassone, and Winskel have demonstrated that
category theory Category theory is a general theory of mathematical structures and their relations. It was introduced by Samuel Eilenberg and Saunders Mac Lane in the middle of the 20th century in their foundational work on algebraic topology. Category theory ...
can be used to provide a similar unified understanding of different models. The Concurrency Representation Theorem in the actor model provides a fairly general way to represent concurrent systems that are closed in the sense that they do not receive communications from outside. (Other concurrency systems, e.g., process calculi can be modeled in the actor model using a
two-phase commit protocol In transaction processing, databases, and computer networking, the two-phase commit protocol (2PC, ''tupac'') is a type of Atomic commit, atomic commitment protocol (ACP). It is a distributed algorithm that coordinates all the processes that pa ...
.Frederick Knabe. A Distributed Protocol for Channel-Based Communication with Choice PARLE 1992.) The mathematical denotation denoted by a closed system is constructed increasingly better approximations from an initial behavior called using a behavior approximating function to construct a denotation (meaning ) for as follows: :: In this way, can be mathematically characterized in terms of all its possible behaviors.


Logics

Various types of temporal logic can be used to help reason about concurrent systems. Some of these logics, such as linear temporal logic and computation tree logic, allow assertions to be made about the sequences of states that a concurrent system can pass through. Others, such as action computational tree logic, Hennessy–Milner logic, and Lamport's temporal logic of actions, build their assertions from sequences of ''actions'' (changes in state). The principal application of these logics is in writing specifications for concurrent systems.


Practice

Concurrent programming encompasses programming languages and algorithms used to implement concurrent systems. Concurrent programming is usually considered to be more general than
parallel programming Parallel computing is a type of computing, computation in which many calculations or Process (computing), processes are carried out simultaneously. Large problems can often be divided into smaller ones, which can then be solved at the same time. ...
because it can involve arbitrary and dynamic patterns of communication and interaction, whereas parallel systems generally have a predefined and well-structured communications pattern. The base goals of concurrent programming include ''correctness'', ''performance'' and ''robustness''. Concurrent systems such as
Operating system An operating system (OS) is system software that manages computer hardware and software resources, and provides common daemon (computing), services for computer programs. Time-sharing operating systems scheduler (computing), schedule tasks for ...
s and
Database management system In computing, a database is an organized collection of data or a type of data store based on the use of a database management system (DBMS), the software that interacts with end users, applications, and the database itself to capture and an ...
s are generally designed to operate indefinitely, including automatic recovery from failure, and not terminate unexpectedly (see
Concurrency control In information technology and computer science, especially in the fields of computer programming, operating systems, multiprocessors, and databases, concurrency control ensures that correct results for concurrent operations are generated, whil ...
). Some concurrent systems implement a form of transparent concurrency, in which concurrent computational entities may compete for and share a single resource, but the complexities of this competition and sharing are shielded from the programmer. Because they use shared resources, concurrent systems in general require the inclusion of some kind of arbiter somewhere in their implementation (often in the underlying hardware), to control access to those resources. The use of arbiters introduces the possibility of indeterminacy in concurrent computation which has major implications for practice including correctness and performance. For example, arbitration introduces unbounded nondeterminism which raises issues with model checking because it causes explosion in the state space and can even cause models to have an infinite number of states. Some concurrent programming models include coprocesses and deterministic concurrency. In these models, threads of control explicitly yield their timeslices, either to the system or to another process.


See also

* Dining philosophers problem * Chu space * Client–server network nodes *
Clojure Clojure (, like ''closure'') is a dynamic programming language, dynamic and functional programming, functional dialect (computing), dialect of the programming language Lisp (programming language), Lisp on the Java (software platform), Java platfo ...
* Cluster nodes *
Concurrency control In information technology and computer science, especially in the fields of computer programming, operating systems, multiprocessors, and databases, concurrency control ensures that correct results for concurrent operations are generated, whil ...
*
Concurrent computing Concurrent computing is a form of computing in which several computations are executed '' concurrently''—during overlapping time periods—instead of ''sequentially—''with one completing before the next starts. This is a property of a syst ...
* Concurrent object-oriented programming * Concurrency pattern * Construction and Analysis of Distributed Processes (CADP) *
D (programming language) D, also known as dlang, is a multi-paradigm system programming language created by Walter Bright at Digital Mars and released in 2001. Andrei Alexandrescu joined the design and development effort in 2007. Though it originated as a re-engin ...
* Distributed system * Elixir (programming language) * Erlang (programming language) *
Go (programming language) Go is a high-level programming language, high-level general purpose programming language that is static typing, statically typed and compiled language, compiled. It is known for the simplicity of its syntax and the efficiency of development th ...
* Gordon Pask * International Conference on Concurrency Theory (CONCUR) * OpenMP *
Parallel computing Parallel computing is a type of computing, computation in which many calculations or Process (computing), processes are carried out simultaneously. Large problems can often be divided into smaller ones, which can then be solved at the same time. ...
* Partitioned global address space * Pony (programming language) * Processes * Ptolemy Project *
Rust (programming language) Rust is a General-purpose programming language, general-purpose programming language emphasizing Computer performance, performance, type safety, and Concurrency (computer science), concurrency. It enforces memory safety, meaning that all Refer ...
* Sheaf (mathematics) * Threads * X10 (programming language) * Structured concurrency


References


Further reading

* * * * * * Distefano, S., & Bruneo, D. (2015). ''Quantitative assessments of distributed systems: Methodologies and techniques'' (1st ed.). Somerset: John Wiley & Sons Inc. * Bhattacharyya, S. S. (2013;2014;). ''Handbook of signal processing systems'' (Second;2;2nd 2013; ed.). New York, NY: Springer.10.1007/978-1-4614-6859-2 * Wolter, K. (2012;2014;). ''Resilience assessment and evaluation of computing systems'' (1. Aufl.;1; ed.). London;Berlin;: Springer.


External links


Process Algebra Diary - Prof. Luca Aceto's blog on Concurrency TheoryConcurrent Systems
a
The WWW Virtual Library
given a
scaleconf
{{Concurrent computing