edited by
2,383 views
1 votes
1 votes
Consider a machine with byte addressable memory 32 bits virtual addresses, 32 bits physical addresses and 4 KB page size. If a two-level page table system is used where each page table occupies one page and page table entries of 4 B each, then the memory overhead for this machine is ________ KB

please explain.
edited by

3 Answers

2 votes
2 votes
As each page table occupies one page and size of page table entry is $4B$.

Number of entries in page table = $4KB/4B$ = $1024$ . Each entry of first level page table will point to a second level page table.

This means $1024$  $second -level- page -tables$ and $1$ $ first -level- page- table$ Hence total memory overhead is = $1025X4KB$ = $4100KB$
reshown by
0 votes
0 votes

I don't know the meaning of memory overhead. My guess extra space required by the page tables. Please help out if i'm wrong on that. The calculation on my solution is right though.

0 votes
0 votes

It's clearly mentioned in the question that each page table occupies one page.

The usual way of solving is giving us an inner page table of size 4MB > PS. Thus, this approach is not asked in the question.

Hint: 1024 outer page table entries should point to 1024 inner page tables. Thus, outer page table size = 1024 entries * 4B entry size

And inner page table size = (1024 entries * 4B entry size) * 1024 such tables

Thus the overhead is : 1024 * 4B + 1024 * 4B * 1024 = 4 KB + 4096 KB = 4100 KB

 

edited by

Related questions

0 votes
0 votes
3 answers
1
2 votes
2 votes
2 answers
3