The Gateway to Computer Science Excellence
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 by Veteran (58.8k points) | 7 views

Please log in or register to answer this question.

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
50,737 questions
57,291 answers
104,889 users