Please enable JavaScript.
Coggle requires JavaScript to display documents.
Concurrency (Concepts (Contexts (Multiple apps, Structured apps, OS…
Concurrency
Concepts
Race condition
A situation in which multiple threads or processes read and write a shared data item and the final result depends on the relative timing of their execution.
Mutual exclusion
The requirement that when one process is in a critical section that accesses shared resources, no other process may be in a critical section that accesses any of those shared resources.
-
Livelock
A situation in which two or more processes continuously change their states in response to changes in the other process(es) without doing any useful work
-
-
Critical section
A section of code within a process that requires access to shared resources and that must not be executed while another process
Race condition
A situation in which multiple threads or processes read and write a shared data item and the final result depends on the relative timing of their execution
Starvation
A function or action implemented as a sequence of one or more instructions that appears to be indivisible
Busy waiting
Technique in which a process can do nothing until it gets permission to enter its critical section but continues to execute an instruction or set of instructions that tests the appropriate variable to gain entrance
-
Spinlock
Mutual exclusion mechanism in which a process executes in an infinite loop waiting for the value of a lock variable to indicate availability.
-
-
Resources
Reusable
Processors, I/O channels, main and secondary memory, devices, and data structures such as files, databases, and semaphores
Consumable
Interrupts, signals, messages, and information in I/O buffers
OS Concerns
-
-
The OS must protect the data and physical resources of each process against unintended interference by other processes
The functioning of a process, and the output it produces, must be independent of the speed at which its execution is carried out relative to the speed of other
concurrent processes
Deadlock
A situation in which two or more processes are unable to proceed because each is waiting for one of the others to do something
-
-
-
-
Monitors
Definition
A programming language construct that encapsulates variables, access procedures, and initialization code within an abstract data type
-
-