Log In
0 votes

Below is an execution trace of a program fragment for a computer with $512-byte$ pages. The program is located at address $1020,$ and its stack pointer is at $8192\:\:($the stack grows toward $0).$ Give the page reference string generated by this program. Each instruction occupies $4$ bytes $(1 \text{word})$ including immediate constants. 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,$ stacking the return address
  • Subtract the immediate constant $16$ from the stack pointer
  • Compare the actual parameter to the immediate constant $4$ 
  • Jump if equal to $5152$
in Operating System 42 views

Please log in or register to answer this question.

Related questions

0 votes
0 answers
A student in a compiler design course proposes to the professor a project of writing a compiler that will produce a list of page references that can be used to implement the optimal page replacement algorithm. Is this possible? Why or why not? Is there anything that could be done to improve paging efficiency at run time?
asked Oct 26, 2019 in Operating System Lakshman Patel RJIT 32 views
1 vote
4 answers
0 votes
0 answers
0 votes
1 answer
A computer whose processes have $1024$ pages in their address spaces keeps its page tables in memory. The overhead required for reading a word from the page table is $5\: nsec.$ To reduce this overhead, the computer has a $TLB,$ which holds $32$ (virtual page, physical page frame) pairs, and can do a lookup in $1\: nsec.$ What hit rate is needed to reduce the mean overhead to $2\: nsec?$
asked Oct 26, 2019 in Operating System Lakshman Patel RJIT 130 views