[問題] page fault

看板Grad-ProbAsk作者 (Terry)時間17年前 (2009/05/14 23:29), 編輯推噓1(104)
留言5則, 2人參與, 最新討論串1/1
想確認一下..是不是我搞錯了.. 題目是: A computer whose processes have 1024 pages in their address spaces keeps its page tables in memory. The overhead required for reading a word from the page table is 500 nsec. In order to reduce the overhead, the computer has a TLB,which holds 32(virtual page, physical page frame) pairs, and can do a look up in 100 nsec. What hit rate is needed to reduce the mean overhead to 200 nesec? 書上寫: 假設TLB的hit rate 為h,則: 100ns+(1-h)*500ns=200ns h=80% 我的問題是,那為什麼100ns不需要乘上h呢? 謝謝幫忙 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 61.228.100.113

05/15 02:20, , 1F
因為那是去TLB找所花之時間 去找了才知有沒有在TLB中
05/15 02:20, 1F

05/15 02:20, , 2F
沒找到會要再多花500ns去page table找
05/15 02:20, 2F

05/15 02:21, , 3F
我們無法事先預知在TLB中會找到否 所以找到機率與其無關
05/15 02:21, 3F

05/15 02:22, , 4F
必定要在TLB找一次
05/15 02:22, 4F

05/15 02:33, , 5F
點醒我了,大概是我太久沒唸了...謝謝您
05/15 02:33, 5F
文章代碼(AID): #1A33Z0h- (Grad-ProbAsk)