看板 Grad-ProbAsk 關於我們 聯絡資訊
這是恐龍第八版的習題 (ch5 process scheduling) 5.16 Consider a preemptive priority scheduling algorithm based on dynamically changing priority. Larger priority numbers imply higher priority. When a process is waiting for the CPU (in the ready, but not running), its priority changes at rate A; when it is running. its priority changes at a rate B. All processes are given a priority of 0 when they enter the ready queue. The parameter A and B can be set to give many different scheduling algorithm. a. What is the algorithm that result form B > A > 0 (A : FCFS) b. What is the algorithm that result form A < B < 0 (A : LIFO) 另外題庫還有 c. What is the algorithm that result form A > B > 0 (A : LIFO) d. What is the algorithm that result form B < A < 0 (A : FCFS) a和b 沒問題 其他都不太了解為甚麼,像 A > B > 0 剛進入Ready queue的為0,原先在Ready queue和Runing的priority應該都較高 為何答案卻是 LIFO 而 B < A < 0 就更不懂了,煩請大家解惑,感謝 -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 1.168.97.180 ※ 文章網址: http://www.ptt.cc/bbs/Grad-ProbAsk/M.1404038362.A.885.html