作者yesa315 (XD)
看板Grad-ProbAsk
标题[理工] [OS]-Allocation method
时间Sun Oct 11 12:02:08 2009
Consider a file currently consisting of 100-blocks. Assume that the file
control block( and the index block, in the case of indexed allocation) is
already in memory. Calculate how many disk IO operations are required for
contiguous, linked, and indexed(single-level) allocation strategies, if, for
one block, the following conditions hold. In the contiguous-allocation case,
assume that there is no room to grow in the beginning to be added is stored
in memory.
a. The block is added at the beginning.
b. The block is added in the middle.
c. The block is added in the end.
d. The block is removed from the beginning.
e. The block is removed from the middle.
f. The block is removed from the end.
答案是这样:
Contiguous Linked Indexed
a 201 1 1
b 101 52 1
c 1 3 1
d 198 1 0
e 98 52 0
f 0 100 0
linked 跟 index 不太懂为什麽
可以请高手指导吗 谢谢!
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.127.208.96
※ 编辑: yesa315 来自: 140.127.208.96 (01/26 10:08)