CSE 451
Operating Systems
Spring 1998
Quiz #5
Distributed : 5/12/98 (Tuesday)
Due
: 5/14/98 (Thursday -- in the beginning of the Section)
1. Suppose a system has a virtual address containing
28 bits. Suppose that the page size is 1024 bytes, that physical
addresses contain 24 bits, and that the system uses a segmented-and-paged
scheme with 256 segments and variable segment sizes.
-
Describe the address translation mechanism, using a picture to
show the relevant tables and operations. Don't
worry about a TLB. Be sure to show the exact size of each
table (how many entries, how many bits wide).
-
What is the maximum size of a segment ?
-
What is the maximum number of memory accesses required to access a word
in memory if: (Assume no page faults)
-
the page tables are stored in physical memory ?
-
the user page tables are stored in virtual memory of the kernel and the
kernel page tables are stored in physical memory ?
-
Suppose that a byte of physical memory is to be shared
by two processes. Describe how the tables could be arranged to permit
this.
-
Suppose that a particular segment in this system contains
4800 bytes. How much memory will the segment cause
to be wasted in internal fragmentation? Consider only
the memory allocated to the segment itself; do
not worry about memory used in the mapping tables.
-
Now suppose that the owner of the 4800-byte segment wishes
to expand it by 200 bytes. What must the operating system
do in order to increase its size? Compare this to a system
based on pure segmentation.
-
Suppose that the segment is expanded again, from 5000 bytes
to 5500 bytes. What must the operating system do to accomplish
this?