I am doing some exercises to understand how virtual memory and paging works, my question is this:
Suppose we use paged memory with pages of size 1024 bytes, the virtual address space is 8 pages, but physical memory can contain only 4 frames. Replacement Policy - LRU.
- What is the physical address in main memory corresponding to virtual address 4096? and how do you achieve this result?
- Same as question 1, but with virtual address 1024
- When accessing a word on page 0, a page error occurs, what page frame will be used to get virtual page 0?
Page Image
My test:
What I have received so far for questions 1. and 2. determines the address in the table (attached as an image) for the corresponding pages. So, for example, I will map the virtual address 4096 on page 4 and 1024 on page 1, is that right?
Kenshin
source share