Operating Systems and Systems Integration

Memory Management Tutorial

1. (a) Compare swapping with paging.

(b) Swapping is still used together with paging. Explain why.

(c) Explain the term dirty page in a paging system.

(d) Give one simple example of the use of a read-only memory page.

(e) State one major difference between how a paging system deals with a read-only page compared with how it deals with a read-write page.

2. Referring to figure 1, briefly define the following terms:

(a) page

(b) page table

(c) In figure 1 on the following page, there are additions performed indicated by a circle with a ‘+’ inside. Where and why is this arithmetic performed?

3. A computer system has sixteen kilobyte pages and a 64-bit address bus, and 64-bit virtual addresses. In both the page table, and the page directory, entries are eight bytes in size. The system is shown in figure 1 on the next page. The following five parts of this question refer to this computer system.

Memory Management Tutorial Operating Systems and Systems Integration

2

Figure 1: A method of paging.

(a) Calculate the number of bits required for the offset part of the virtual address, showing your working.

(b) Calculate the number of page table entries that are required.

(c) If the page directory and page table are as nearly the same size as possible, determine the amount of ram required to hold each one.

(d) Briefly list one major problem with the paging scheme shown in figure 1 when used with this computer system.

(e) Explain with the aid of a diagram an alternative paging method that overcomes the problem you listed in the previous part 3d. Show how your design overcomes the problem.

Memory Management Tutorial Operating Systems and Systems Integration

3

4. (a) List TWO important functions of a paging system in an operating system.

Figure 2: A method of paging.

5. A computer system has eight kilobyte pages and a 64-bit address bus. The following three parts of this question refer to this computer system.

(a) Calculate the number of page table entries that are required.

(b) Briefly list one major problem with the paging scheme shown in figure 2.

(c) Explain with the aid of a diagram an alternative paging method that overcomes the problem you listed in the previous part 5b.