作者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
1F:→ ccler:combine比率是一样,拿multiply的一半去组成新的multiply-add 09/19 23:56
2F:→ gn00618777:我是把multiply 5%*原来的10%所以 multiply剩下5 09/20 00:21
3F:→ gn00618777:打错 是50%*原来的10% multiply剩下5 09/20 00:22
4F:→ gn00618777:可是另一个arithmetic要抽多少和到 multiply-adds呢? 09/20 00:22
5F:推 ianwuzack:multiplier 0.1-0.1*0.5=0.05 09/20 00:30
6F:→ ianwuzack:arithmatic 0.5-0.1*0.5=0.45 09/20 00:31
7F:→ ianwuzack:multiply-adds 就是0.1*0.5=0.05了 09/20 00:31
8F:→ gn00618777:可是解答multiply add 占有率怎麽才5% 都已经各取5了 09/20 00:47
9F:→ gn00618777:应该为10%阿 09/20 00:47
10F:→ ccler:因为题目也没说,所以你这的想法(mix)跟推文一种全新的指令 09/20 01:41
11F:→ ccler:其实都是可以的 09/20 01:41