Tutorial 9 : Virtual Memory and Processor Part 1 ------------------------------------------------ .. include:: shared/notformark.rst Question 1 ########## Given that your ISA supports a 36-bit address space and your 2GB RAM is broken into 2KB pages, answer the following: a. How many bits are in a virtual page number? and in a physical page number (page frame)? b. If the flags (valid (V), dirty (D), Accessed (A) and Read/Write (R)) take up 12 bits per entry, how many bits does an entire page table, as in the below figure, take up? .. image:: image/virtual_memory.png :align: center Question 2 ########## The datapath for a simple RISC architecture is described in the figure below. Modify this data path so that it supports: a. Pre-Indexing addressing mode. b. Post-Indexing addressing mode. c. For the following two instructions: :code:`LDR R1, [R7, #4]!`, :code:`LDR R1, [R7], #4`, list all the actions in each stage that take place in the modified datpath (similar to the left-side of slide #28 in lecture #6) .. image:: image/data_path.png :align: center