12/17 12/11 OS作業 | |
---|---|
名稱 | 12/11 OS作業 |
描述 | 12/11 OS作業 |
日期 | 12/17 |
課程名稱 | 作業系統 |
指導教師 | 劉艾華 |
1. What kind of strategies we can have for using thread pools?
Seperating task to be performed from the machanics of creating the task allows us to use different
strategies such as scheduling strategies and terminating strategies for running the task.
As a new work to do, it creat new thread and delete it when it's no longer useful.
Strategies means what can we do to handle threads.
2. Why the windows uses one to one mapping for the threads while there are many to many available.
Because one-to-one model maps each user thread to a kernel thread, and it will limit the number
of threads so the utility of computing won't be slow down.
Also, one-to-one model can work efficiently on concurrent.
One-to-one model is use for spetial threads while many-to-many model is use for usual threads.
3. Specify the differences between processes and threads.
(1) Thread is smaller than process.
(2) Thread is used to allocate program.
(3) There is no program in thread.
(4) Thread is more common than process.
更新日期:2015/12/17 下午 08:55:32