Concurrency: The capability of having more than one computation in progress at the same time. These computations may be on separate cores or they may be sharing a single core by being swapped in and out by the operating system at intervals. — PAGE 266, THE ART OF CONCURRENCY, 2009.
Concurrency: The ability to handle multiple pending tasks, making progress one at a time or in parallel (if possible) so that each of them eventually succeeds or fails. A single- core CPU is capable of concurrency if it runs an OS scheduler that interleaves the execution of the pending tasks. Also known as multitasking. – PAGE 697, Fluent Python.
Parallel: Executing more than one computation at the same time. These computations must be on separate cores to be running in parallel. — PAGE 270, THE ART OF CONCURRENCY, 2009.
Parallelism: The ability to execute multiple computations at the same time. This requires a multicore CPU, multiple CPUs, a GPU, or multiple computers in a cluster. – PAGE 697, Fluent Python.
Asynchronous execution means not at the same time, e.g. at some later time. It may be in parallel. It may be when there are sufficient resources. It may be when there’s time. It may be when we choose to suspend and allow it.
Asynchronous: Separate execution streams that can run concurrently in any order relative to each other are asynchronous. — PAGE 265, THE ART OF CONCURRENCY, 2009.
📂 Python | Последнее изменение: 10.12.2023 13:13