Can a single core CPU achieve real concurrency?

"If you can feel the computer switching dozens of tasks every few milliseconds, you will certainly agree that the computer seems to perform these tasks at the same time, even if we know that the computer is interleaving various tasks“

>M. Ben ARI, principle of parallel programming, 1982

So on a single core CPU, a single atomic operation cannot be executed simultaneously in the same system?

Solution

Yes, a single core CPU can perform multiple operations at the same time For example, Pentium processors have multiple pipelines running simultaneously One person may be doing an add while another is loading from memory Of course, you can't observe the impact of synchronization

In addition, architectures like Pentium 4 are single core, but can have hyper threads This means that different pipes in a single core can not only execute instructions at the same time, but also these operations can be used for separate threads In other words, the CPU can issue instructions from different threads on the same clock beat

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>