作者gn00618777 (123)
看板Grad-ProbAsk
標題Re: [理工] [計組]-效能
時間Sat Sep 19 23:33:12 2009
※ 引述《gn00618777 (123)》之銘言:
: A certain machine with a 10ns(10*10^9s) clock period can
: perform jump(1 cycle),branches(3 cycles),arithmetic intruction(2 cycles)
: multiply intructions(5 cycles),and memory intruction(4 cycles).
: A certain program has 10% jumps, 10% branches,50% arithmetic,10%
: multiply. and 20% memory intructions.
: What is the CPI of this program on this machine?
:
Q: A 5-cycle multiply-add instruction is implemented that
combines an arithmetic and multiply instruction. 50%
of the multiplies can be turned into multiply-adds.
what is the new CPI?
感覺解答是錯的,想請教各位
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 218.168.60.249
→ ccler:combine比率是一樣,拿multiply的一半去組成新的multiply-add 09/19 23:56
→ gn00618777:我是把multiply 5%*原來的10%所以 multiply剩下5 09/20 00:21
→ gn00618777:打錯 是50%*原來的10% multiply剩下5 09/20 00:22
→ gn00618777:可是另一個arithmetic要抽多少和到 multiply-adds呢? 09/20 00:22
推 ianwuzack:multiplier 0.1-0.1*0.5=0.05 09/20 00:30
→ ianwuzack:arithmatic 0.5-0.1*0.5=0.45 09/20 00:31
→ ianwuzack:multiply-adds 就是0.1*0.5=0.05了 09/20 00:31
→ gn00618777:可是解答multiply add 佔有率怎麼才5% 都已經各取5了 09/20 00:47
→ gn00618777:應該為10%阿 09/20 00:47
→ ccler:因為題目也沒說,所以你這的想法(mix)跟推文一種全新的指令 09/20 01:41
→ ccler:其實都是可以的 09/20 01:41