Saturday, November 24, 2007

IS215 - Memory Management Exercises - 2

11. Discuss the factors that may affect the performance of a paging system. For each of the sequence of page requests given below, and assuming a store size of four page frames, give the optimum sequence of page fetches and replacements and also, the sequence which would be generated if the replacement algorithm used is LRU. Do the same for FIFO. Comment on the results obtained.

a) 1, 2, 3, 4, 5, 1, 2, 3, 4, 5, 1, 2, 3, 4, 5, 1, 2, 3
b) 1, 2, 1, 3, 1, 4, 1, 5, 1, 2, 1, 3, 1, 4, 1, 5, 1, 2
c) 1, 2, 3, 4, 5, 4, 3, 2, 1, 2, 3, 4, 5, 4, 3, 2, 1, 2
d) 1, 2, 3, 4, 5, 4, 3, 2, 1, 5, 4, 3, 2, 1, 2, 3, 4, 5

12. With the sequence of page requests given in (11a-11d), give the contents of the memory for each sequence. Assume that the memory is initially empty and the working set is 4 pages at any instant.

13. Outline a possible structure for page and segment tables. Explain how an associative memory may be used to reduce effective access time. Show that if p% of accesses fail to match entries in the associative store then, in a page segmented addressing system, there will be a slow down of p%.

14. Local page replacement policy is prone to thrashing. Argue for or against this statement.

15. Paged segmentation was designed to combine the advantages of paging and segmentation. Hence there are problems present in

a) paging alone; and
b) segmentation alone

which are not in paged segmentation. List all these problems.

16. Demand and anticipatory fetch policies can be combined together. Outline a system that combines these two fetch policies.

17. Discuss how thrashing is avoided when the working set of a process is determined in advance.

18. Consider a swapping system. Measured utilization are:

CPU utilization - 20%
Swapping device (drum) - 99.7%
Other I/O devices - 5%

What will be the effect on CPU utilization if we

a) get a faster CPU
b) get a bigger hard disk for swapping
c) increase the degree of multiprogramming
d) decrease the degree of multiprogramming
e) get faster other I/O devices.

19. Consider a swapping system in which the memory is composed of the following hole sizes (assuming the leftmost hole is the first in the list):

10K, 4K, 20K, 18K, 9K, 12K, 15K

Which hole is taken for successive segment=requests of 12K, 5K, 10K for first-fit? Repeat the question for best-fit and worst-fit.

20. Which of the following programming techniques and structures are ideal for paging. Support your answer.

a) sequential search
b) binary search
c) array operations
d) stack operations

Which is ideal for segmentation?

No comments: