有關於解決給定這些數據的AMAT(平均存儲器存取時間)這樣的問題:存儲器存取權限時間分析建模
傳奇:高速緩存級別1 = L1高速緩存級別2 = L2主內存= M
L1, L2 and M's Hit Time are 1, 10 and 100 respectively whilst
L1 Miss Rate is 5%, L2 5% and M 50%.
在時鐘週期中查找AMAT。
試圖解決這個問題之後,這裏是我的解決方案:
AMAT's formula is = Hit Time X Hit Rate + Miss Penalty * Miss Rate
Miss Penalty = AMAT for the next cache(say for example, AMAT of L2)
所以我操縱的公式,結果弄成這個樣子:
AMAT = Hit Time L1 X Hit Rate L1 + AMAT L2 * Miss Rate L1
AMAT L2 = Hit Time L2 X Hit Rate L2 + AMAT M * Miss Rate L2
AMAT M = Hit Time M X Hit Rate M + [???] * Miss Rate M
的說配方提供的數值看起來像這樣:
AMAT = 1 X .95 + AMAT L2 * .05
AMAT L2 = 10 X .95 + AMAT M * .05
AMAT M = 100 X .5 + [???] * .5
所以我的第一個問題是,是米y公式是否正確? 接下來,如何獲得M的Miss Penalty?