30 pts., due Apr. 18
Each problem is worth eight points. A reminder: Show work.
- Consider a system with 4200 words of main memory using variable partitions.
At some time, the memory is occupied by three blocks of code/data as
Assume that three new blocks with sizes 500, 1200, and 200 (all sizes in
words) are to be loaded in the order listed. For the best-fit and
worst-fit placement strategies, show the memory contents after all three
blocks have been loaded and the total time for loads/moves. If the
placement strategy fails to find a hole for a block, then compact blocks
toward address 0, starting with the block closest to address 0 and stopping
once enough space has been created to place the new block. Assume that it
takes 1 microsecond to load/move a word.
- Below is the listing of a short assembly language program for a computer
with 512-byte pages. The program is located at address 1020 (all addresses
are decimal), and its stack pointer is at 8192 (the stack grows toward 0).
Give the page reference string (i.e., the list of page references)
generated by this program. Each instruction occupies 4 bytes (1 word), and
both instruction and data references count in the reference string.
load word 6144 into register 0
push register 0 onto the stack
call a procedure at 5120, pushing the return address onto the stack
subtract the immediate constant 16 from the stack pointer
compare the actual parameter to the immediate constant 4
jump if equal to 5152
You'll need to make appropriate, valid assumptions. Don't forget to state
- Consider the Intel address translation scheme shown in this figure:
- Describe all the steps taken by the Intel x86 in translating a
logical address to a physical address.
- What are the advantages to the operating system of hardware that
provides such complicated memory translation hardware?
- Are there any disadvantages to this address translation system?
- A group of operating system designers for the Gigasloth Computing Company
are thinking about ways of reducing the amount of swap space needed in
their new, disk-hungry operating system: Tiptoes 00. The head guru has
just suggested not bothering to save the text segment in the swap file at
all, but just swap it in directly from the binary image whenever necessary.
Discuss the advantages and disadvantages of this approach.
Thomas P. Kelliher