看板 Grad-ProbAsk 關於我們 聯絡資訊
Consider a computer has a fully associative mapped 32 bytes cache with block size of 8 bytes. The replacement policy is LRU. A program is run on this machine. The memory access sequence in word address is 0, 1, 2, 5, 6, 7, 3, 1, 2, 3, 4, 5, 6, 7, 20, 21, 22, 23, 0, and 1. What is the cache hit rate for this program fragment? 快取是長成2*4的矩陣 對吧? 當第0行只有0 然後要放1 張凡解答說會hit 可是1放進去之前沒有1 怎麼會hit? 還是說只要tag一樣就是hit? -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 27.105.7.134
s90413k64:一個block有2個word 所以0 1同時在cache 08/08 21:43
我是說一開始放0 可放兩字組的block只有0 可是放1就馬上hit 怎麼會這樣? ※ 編輯: lexa 來自: 27.105.7.134 (08/08 22:11)
s90413k64:0 1 在同一個block 0 miss的時候會把0 1 都讀進來 08/09 16:23