Using concurrency, parallelism, and multithreading
Since you are already a C++ developer, you might be aware of these terms, which may be used interchangeably. However, there are differences in these terms. Let's revisit these terms here:
- Concurrency is the execution of multiple programs at the same time (concurrent).
- Parallelism is the simultaneous running of a portion of your program in parallel, utilizing the multiple cores in a multi-core processor.
- Multithreading is the capability of a central processing unit (CPU) to run multiple threads for the same program, concurrently supported by the operating system.
For example, you may launch multiple instances of a Portable Document Format (PDF) reader and Qt Creator. Qt Creator can run multiple tools by itself. Your system Task Manager can show you all the processes running simultaneously. This is known as concurrency. It is also commonly known as multitasking.
But if you use parallel computing techniques...