政大資科98
Consider the following hardware configuration. Virtual address=32bit
page size = 4kbyte, and a page table entry occupies 4 bytes. How many
pages should the OS allocate for the pages tables of a12Mbyte process
under the following paging mechanisms?
1 one-level paging
2 two-level paging(Assuming that the number of entries in a first-level
page table is the same as that in a second-level
page table)
看了之前人家問的..我還是沒有很清楚
(2) user program有3k個pages,而level-2 page table 可存1K個pages
所以 3k/1k = 3個level-2 page table
page table size = 2^10*2^2*3 + 3*4=(12*2^10+12) bytes
需要(12*2^10+12)/2^12 =4 pages
問題一: 整個page table size有包含level-1 table嗎?
問題二: 3*4是代表什麼..?
問題三: 整個問題是不是在問你建立12MB process的PT需要幾張page?
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 220.138.105.41
※ 編輯: gn00618777 來自: 220.138.105.41 (02/03 14:55)
※ 編輯: gn00618777 來自: 220.138.105.41 (02/03 21:18)