TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

What is the difference between concurrency and parallelism?

23 pointsby CodeSheikhabout 5 years ago

4 comments

ncmncmabout 5 years ago
Parallelism giveth, and concurrency taketh away.<p>Concurrency, as used by people who think hard about these things, is about what you do to keep a system coherent and balanced with parallel activities going on: the overhead of coordinating parallel activity that prevents you from getting ideal xN performance. This includes stuff you wouldn&#x27;t need to do at all with one thread, and also stalls when coordinating access to shared resources.<p>It doesn&#x27;t include useful work not done in parallel because it&#x27;s inherently serial, or that is thrown away because it was unnecessarily done more than once. That all is the domain of Amdahl&#x27;s law.
1f60cabout 5 years ago
I think a better title would be &quot;What is the difference between concurrency and parallelism?&quot; (that is, the title of the OP), and then leave a comment (on HN) saying &quot;Questions like these on SO should be taught in CS-101&quot;. Just my 2¢.
评论 #22925745 未加载
CodeSheikhabout 5 years ago
Questions like these on SO should be taught in CS-101. There are some amazing answers in there that I would have hard time finding in textbooks.
评论 #22926930 未加载
jamesmunnsabout 5 years ago
It&#x27;s a little overly succinct, but I&#x27;ve heard:<p>Parallelism is for many things working at the same time. Concurrency is for many things waiting at the same time.