Page Faults - Memory and Virtual Memory A computer has 4 KB of virtual memory, 2
ID: 3772873 • Letter: P
Question
Page Faults - Memory and Virtual Memory
A computer has 4 KB of virtual memory, 2 KB of main memory, page size 512 B.
TLB:
Pg Frame
110 11
101 01
PAge Table:
v Frame #
000 1 10
001 1 00
010 0 --
011 0 --
100 0 --
101 1 01
110 1 11
111 0 --
The questions is 5 part, but I can figure out the two easy ones (lol)
1. How many bits are virtual address? 2^9/8 address in 512 B; 2^9/2 = 2^8 addresses in 4 KB; Therefore the virtual address is 8 bits?
2. How many pages are in virutal memory? 8 (confident)
3. How many bits are physical address? not confidnet, but 2^9/4 = 2^7; virtual address is 7 bits? Probably padded to be 8 bits
4. How many frames are in main memory? (4? don't think this is right)
5. Following virtual addressses are given, find physical addresses and identify page fault
A. C6A hex
B. 05B hex
C. 86A hex
Explanation / Answer
A) C6A hex - 1100 0110 1010
if we change decimal - 3178 then
3178 mod 512 = 104
104 -> 01101000 (binary)
B) 05B hex - 0000 0101 1011
05B -> 91 (decimal)
91 mod 512 = 91
91 -> 01011011 (binary)
C - 86A hex - 1000 0110 1010
86A - 2154(decimal)
2154 mod 512 = 106
106 -> 01101010 (decimal)
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.