CS3013 Practice Final Exam

  1. What is a relocation register? Give an example and describe how it is used. What additional hardware can you add to the relocation register to enable memory protection? Give an example.

  2. Consider a paging system with the page table stored in memory:

    1. If a paged memory reference takes 150 nanoseconds, how long does a physical memory reference take?
    2. If we add associative registers, and we have a 95 percent hit-ratio what is the effective memory access time? Assume access to the associative registers takes 5 nanoseconds.
    3. What is the worst-case effective memory access time we could have (using the associative registers from (b))? What is the best effective memory access time we could have (again, using the associative registers from (b))?

  3. Fragmentation:

    1. What kind of fragmentation do we have with paging? Given N processes in memory, how much fragmentation do we have on average?
    2. What kind of fragmentation do we have with fixed sized partitions? Given N processes each in size M memory partitions how much fragmentation do we have?
    3. What kind of fragmentation do we have with variable-sized partitions? Given N processes in memory, how much fragmentation do we have?

  4. Consider a system with 1024 bytes (words) of physical memory divided into 8 frames. The logical address space for each process has 32 pages:

    1. How many bits are in the offset?
    2. How many bits are required for the frame number?
    3. How many bits are required for the page number?
    4. How many bits are required for a physical memory address?
    5. How many bits are required for a logical memory address?
    6. How big is the page table (in bits) for each process?

  5. Consider a system with 32 bits for a memory access. Assume a 2 level paging scheme with 8 bits for the outer page table and 12 bits for the inner page table. How big is each page?

  6. Explain how the OPT page replacement algorithm is similar to the SJF process scheduling algorithm. In particular, what are the uses for OPT and SJF?

  7. What is the locality of reference? How does demand paging take advantage of this in terms of a process' working set?

  8. Explain the principles behind the "top half" of an interrupt handler and the "bottom half."

  9. What is the maximum number of disk I/O operations (counting a read and a write as 2 operations) required to add a block to the end of the file for each of: linked-list allocation with index (FAT) and i-nodes. Assume the base file descriptor is currently cached in memory, but nothing else is.

  10. Using the the following pseudo-system calls and statements:

    Show pseudo-code to implement a shared-memory region solution for your pong client. You do not have to show any parameters or additional variable declarations. You may use the functions more than once, as needed.


Return to the CS3013 Home Page