CS FundamentalsHardGATE CS
A 1 MB region uses the buddy system. Requests arrive for A = 70 KB, B = 35 KB and C = 80 KB. What is the total internal fragmentation, and what is the largest free block afterwards?
- A. 135 KB, and the largest free block is 704 KB
- B. 320 KB, and the largest free block is 512 KB
- C. 135 KB, and the largest free block is 512 KB
- D. 135 KB, and the largest free block is 256 KB
Correct answer: C. 135 KB, and the largest free block is 512 KB
A gets 128 KB, B 64 KB and C 128 KB: waste 58 + 29 + 48 = 135 KB. Allocation splits only the lower 512 KB (A at 0, B at 128, C at 256), leaving free 64, 128 and the untouched 512 KB half. 704 KB is the total free space, which is not contiguous; 320 KB is the allocated space.
More Operating Systems questions
- Free holes, in address order, are 150, 400, 250, 600 and 300 KB. Requests for 280, 200, 350 and 290 KB arrive in that order. Which…
- A segment table has: segment 0 base 1200, limit 500; segment 1 base 3000, limit 150; segment 2 base 800, limit 300. Which logical address…
- A process with 100 private writable pages calls fork() and the system uses copy-on-write; a page is copied only if it is still shared when…
- Three periodic tasks with deadline = period have (C, T) = (1, 4), (2, 6) and (3, 12), scheduled by rate-monotonic priority. Which…
- A low-priority task L holds a mutex needed by high-priority task H. A medium-priority task M, which does not need the mutex, becomes ready…
- In a monitor with Mesa (signal-and-continue) semantics, why must a consumer check its condition with while (count == 0) wait(notEmpty)…