Concurrency means that two or more calculations happen within the same time frame, and there is usually some sort of dependency between them. A system is said to be concurrent if it can support two or more actions in progress at the same time.

Concurrency是指在同一个时间段内多个事情并行活动的意思。通常这些并行的事情之间有依赖关系。比如彼此对同一个资源有依赖关系从而无法做到彼此互不干扰地完全独立进行。只要一个系统能支持同一时间段内可以执行多个任务,那么这个系统就是concurrency的。

Concurrency means dealing with multiple tasks at the same time but not necessarily doing at the same time.

Concurrency强调的是多个任务可以在同一个时间段都进行着,但不是说这些任务在同一个时间点同时都执行。

For example: There are two tasks executing concurrently and running in a single core CPU, the CPU will decide to run half a task and half another task to achieve concurrency. It works like this: Task A runs up to a certain time frame, then the CPU stops task A and switches over to task B, works on task B for a while, and then switches back to task A. If the time slices are small enough, from the user's perspective, it sounds like both tasks are being run in parallel, even though they're actually being processed in serial by one single core CPU.

举个例子,单核CPU的电脑是可以支持多个任务同时启动运行的。CPU(事实上是电脑操作系统)决定如何并行运行这些任务。通常是一个任务被分配一个很短的时间片占有CPU,时间片结束后,CPU执行另一个任务,如此往复,从而实现多个任务的并行运行的表象。

英语单词ConcurrencyParallel的区别(英语单词ConcurrencyParallel的区别)(1)

There are various different ways of accomplishing concurrency. One of them is Parallelism.

Concurrency可以有多种具体的实现方式。Parallelism(并行)就是其中一种。

Parallelism means that two or more things happen at the same time. Parallelism does not require two tasks to be existed. Continuing with the example of computer calculation operations, Parallelism can literally physically run parts of a task or multiple tasks at the same time using the multi-core CPU by assigning one core to each task or sub-task.

Parallelism是指多个任务在任何时刻互不干扰地同时独立地运行。

以多核CPU为例,一个任务可以被人为划分成多个互相独立的子模块,然后让不同的CPU内核处理。多个任务的情况下,也可以让不同的CPU内核分别处理一个任务从而实现互不干扰独立执行。

Usually Simultaneous and Parallel can mean the same thing. But, Simultaneously deals more with time whereas in parallel with can refer more to space, so parallel means something more like "side-by-side at the same time.

通常来说,Simultaneous与Parallel可以用来表达同一个意思。但是,simultaneous更多的是指时间的并行,而parallel跟过的是指空间的并行。也就是说parallel更多的适用于表达并肩并排的意思。

,