[理工] 一題OS
Consider a system running ten I/O-bound tasks and one CPU-bound task.
Assume that the I/O-bound tasks issue an I/O operation once for every
millisecond of CPU computing and that each I/O operation takes 10 millisecond
to compute.Also assume that the context-switching overhead is 0.1 millisecond
and that all processes are long-running tasks.
Describe the CPU utilization for a round-robin scheduler when:
(a)The time quantum is 1 millisecond
(b)The time quantum is 10 milliseconds
--
sol:
(a) 1.0/(1.0+0.1) = 1/1.1 = 91%
(b) 20/((10*1.1)+10.1) = 20/21.1 = 94%
--
這題考滿多次的,可是就是沒有很了解怎麼解這題...
可以請高手詳細說明一下嗎?(尤其是(b)小題)
謝謝!!
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 114.39.13.219
※ 編輯: boy5548 來自: 114.39.13.219 (01/28 13:29)
推
01/28 20:09, , 1F
01/28 20:09, 1F
→
01/28 20:11, , 2F
01/28 20:11, 2F
→
01/28 20:12, , 3F
01/28 20:12, 3F
→
01/28 20:12, , 4F
01/28 20:12, 4F
→
01/28 23:26, , 5F
01/28 23:26, 5F
→
01/28 23:27, , 6F
01/28 23:27, 6F
→
01/28 23:34, , 7F
01/28 23:34, 7F
推
01/29 19:26, , 8F
01/29 19:26, 8F
→
01/29 23:27, , 9F
01/29 23:27, 9F
→
01/29 23:28, , 10F
01/29 23:28, 10F
→
01/29 23:28, , 11F
01/29 23:28, 11F
→
01/29 23:29, , 12F
01/29 23:29, 12F
→
09/11 14:11, , 13F
09/11 14:11, 13F
討論串 (同標題文章)