A thread is a point of control flow in a task. A task
exists to provide resources for the threads it contains. This split is made to provide
for parallelism and resource sharing.
A thread
- is a point of control flow in a task.
- has access to all of the elements of the containing task.
- executes (potentially) in parallel with other threads, even threads within the same task.
- has minimal state information for low overhead.
- is a collection of system resources. These resources, with the exception of the address space, are referenced by ports. These resources may be shared with other tasks if rights to the ports are so distributed.
- provides a large, potentially sparse address space, referenced by virtual address.Portions of this space may be shared through inheritance or external memory management.
- contains some number of threads.
said that “task Y does X,” what is really meant is that “a thread contained within
task Y does X.” ;)
1 comment:
Very interesting, but why would you choose to implement using one technique over the other? That is, if you are designing a new application that you thought might benefit from parallelism, would you implement it using subtasks or threads?
Post a Comment