Paging

  1. The operating system extracts the page number, and indexes into the page table to find the frame number.
  2. The physical address will consist of the bits of the frame number followed by the bits of the page offset. That is, since all the pages and all the frames have the same size, the depth at which the address is found on the page is the same depth at which the address is located on the frame.
  3. The operating system uses this newly-constructed address to access main memory.

Page numbers, frame numbers, and frame sizes are determined by the architecture, but are typically powers of two, allowing addresses to be split at a certain number of bits. For example, if the logical address size is 2^m (m bits in each address) and the page size is 2^n (n bits given to the page number,) then the high-order (m - n) bits of a logical address designate the page number and the remaining n bits represent the offset, just as the image on the previous slide illustrates.

The following slide shows an example of using the page table to map pages to frames.