Summary: Task parallelism is the concurrent execution of independent tasks in software. Task parallelism allows multiprocessor and multicore computers to achieve performance speed-up by running threads in parallel, which allow better utilization of the computing resources available in the system.
Task parallelism is the concurrent execution of independent tasks in software. Multiprocessor and multicore computer systems benefit from task parallelism by being able to execute two or more things at one time. Consider a single-core processor that is running a Web browser and a word-processing program at the same time. Although these applications are implemented with unique sets of threads, they still ultimately share the same processor. Now consider a second scenario in which the same two programs are running on a dual-core processor. On the dual-core machine, these two applications essentially can run independently of one another. Although they may share some resources that prevent them from running completely independently, the dual-core machine can handle the two parallel tasks more efficiently.
Multitasking is a more common term in computing that is related to task parallelism, where multitasking has a more broad definition of "multiple tasks running at the same time." However, it's important to note that multitasking does not necessarily imply true parallelism in software, it may just mean a computer is switching between tasks fast enough to give off the illusion that things are happening in parallel. On a multicore system, multitasking can occur in a truly parallel fashion.
| Example of Multitasking |
|---|
![]() |
The act of implementing task parallelism in software is referred to as "task decomposition." It is considered one of the simplest methods for implementing parallelism in a specific application, in comparison with other techniques such as data decomposition. An application must be multithreaded so the system can execute the tasks in parallel. As an example, consider a measurement or control application that is composed of different tasks: Data Acquisition, User Interface, Network Communication, and Logging to Disk.
| Example of Multithreading |
|---|
![]() |
In addition, the primary tasks can be decomposed into sub-tasks for even more levels of task parallelism. An example programming language that is well-suited for task parallelism is LabVIEW, which is a graphical dataflow language. The visual representation allows developers to see the parallelism in the code source. For example, the Data Acquisition task can be broken up into two separate tasks (analog and digital), as illustrated below.
| Task Parallelism in the LabVIEW programming language |
|---|
![]() |
More information on parallel programming techniques can be found at the Multicore Programming Fundamentals Whitepaper Series.