Week 7 Threads Flashcards
What are some benefits of Threads
Responsiveness, Resource Sharing, Economy, Scalability
What is Parallelism?
It implies a system can perform more than one task simultaneously
There are two types of parallelism. What is Data parallelism?
Distributes subsets of the same data across multiple cores, same operation on each
There are two types of parallelism. What is Task Parallelism?
Distributing threads across cores, each thread performing a unique operation
What is Concurrency?
It supports more than one task making progress.
Single processor/core, scheduler providing concurrency
What are user threads?
Management done by user-level threads library.
There are three primary thread libraries:
- POSIX Pthreads
- Windows Threads
- Java Threads
What are Kernel threads?
Supported by the Kernel Examples include virtually all OS's - Windows - Max OS X - Linux etc.
There are three Multithreading models.
Describe Many - to - One
Multiple user threads mapped to a single kernel
Examples include
- Solaris Green Threads
- GNU Portable Threads
There are three Multithreading models.
Describe One - to - One
One user thread to one kernel
Ex:
- Windows
- Linux
There are three Multithreading models.
Describe Many - to - Many
Multiple kernels to multiple user threads
Ex:
- Solaris pre version 9
- Windows with thread fiber package
What’s a Thread Library?
- It provides the programmer with APU for creating and managing threads