CS FundamentalsEasyGATE CS (PYQ pattern)
A disk delivers 20 MB/s (1 MB = 10^6 bytes) to memory by DMA, 4 bytes per bus cycle. Each word transfer steals one 40 ns memory cycle from the CPU. In addition, one completion interrupt is raised per 4096-byte block and costs the CPU 10 microseconds. What percentage of CPU time is lost in total?
- A. 20.0%
- B. 24.9%
- C. 4.9%
- D. 29.8%
Correct answer: B. 24.9%
Words/s = 5x10^6, so cycle stealing = 5x10^6 x 40 ns = 20%. Blocks/s = 20x10^6/4096 = 4882.8, interrupts cost 4882.8 x 10 us = 4.9%. Total = 24.9%.
More Operating Systems questions
- Three threads each execute x = x + 1; twice on a shared int x that starts at 0 (so six increments in all). Each increment is a separate…
- A process has a 1 MB address space split into 4 segments, each paged separately; the single-level page tables together need one 8-byte…
- A process owns 100 private writable pages. It calls fork() and both processes use copy-on-write. Before either exits, the child writes to…
- A RAID 5 array has 6 disks, each able to do 150 random I/O operations per second. A small RAID 5 write costs 4 disk I/Os (read old data…
- A 512 x 512 matrix of 4-byte integers is stored row-major, starting at a page boundary, with 4 KB pages (so two rows per page). The code…
- With 3 frames, initially empty, the reference string is 4, 2, 1, 5, 2, 1, 3, 2, 4, 3, 1, 3, 2, 2, 5, 4, 5, 1, 3, 2, 4, 4. How many MORE…