推 christianSK:好像能夠理解了!! 謝謝~ 09/23 22:49
※ 引述《christianSK (AG)》之銘言:
: 給定三個指令 A B C
: 他們的CPI分別是 a b c
: 如果今天clock rate 增加到150%
: A 的CPI變成1.5倍的a 而 B C 的CPI不變
: 如果說A指令佔 40 %
: 問 ( performance_new / performance_original ) - 1 = ?
: solution:
: ans = 1 / [ (0.4*1.5+0.6)* 1 / 1.5 ] = 1.25 - 1 = 0.25
: 不太能理解解答的做法 為什麼可以直接說 B C 新的CPI = 0.6呢??
: 先謝謝大家了~
By Amadal law,
1/ ((0.4*1.5)/1.5+0.6/1.5) -1 =1/0.8 -1 =1.25 = 0.25.
When clock rate of CPU increases to 1.5 times than the origin,
the instructions of B and C types can also benefit from the improving.
For B and C:
CPU time = Cycle per instuction * Instuction count / Cycle rate.
^^^^^^^^^^
much higher
The reason is cycle rate, not the CPI, and the "0.6" is the percent of B and C
instructions.
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 59.126.187.85
※ 編輯: privatewind 來自: 59.126.187.85 (09/23 18:52)
※ 編輯: privatewind 來自: 59.126.187.85 (09/23 18:52)
※ 編輯: privatewind 來自: 59.126.187.85 (09/23 18:53)