Question

In: Computer Science

Assume a non-pipelined processor takes 100 ns to process an instruction. The same instruction can be...

Assume a non-pipelined processor takes 100 ns to process an instruction. The same instruction can be executed in a 5-stage pipelined processor, where each stage takes 20 ns.

(i) What is the minimum number of instructions for which the speedup achieved by the pipelined processor compared to the non-pipelined processor is at least 4?

(ii) The instruction takes the same time (100 ns) to execute whether on the pipelined processor or on the non-pipelined processor. So why do we say pipelining speeds up execution?

Solutions

Expert Solution

(i) The target speedup factor >=4.

Time taken for one instruction to be executed in non-pipeline system = 100 ns

Time taken for 'n' number of instructions to be executed in non-pipeline system = (100*n) ns

Time taken for one instruction to be executed in pipeline system = 100 ns

But every instruction after the first instruction will take 20 ns to execute. There will be no difference in execution time for both synchronous and asynchronous pipeline as each stage takes equal time.

Time taken for 'n' number of instructions to be executed in pipeline system = (100 + (n-1)*20) ns

According to the requirement ((100*n) / (100 + (n-1)*20)) >= 4

or, ((100*n) / (80 + 20n)) >= 4

or, 100n >= 320 + 80n

or, n >= 16

So, the number of minimum instructions = 16.

(ii) In the pipeline process there are five stages: fetch, decode, execute, memory and write back. In the non pipeline system every instruction takes the same amount of time. But in the pipeline system when the first instruction is in the decode state, the second instruction can be fetched in pipeline at the same time. Similarly, when the first instruction is in the execute state, the second instruction can be decoded and the third instruction can be fetched in pipeline at the same time. Due to this kind of operation pipeline system speeds up execution process.

Hope this helps.


Related Solutions

How does pipelining a processor affect instruction latency and throughput? Compare a basic 5 stage pipelined...
How does pipelining a processor affect instruction latency and throughput? Compare a basic 5 stage pipelined processor to a non-pipelined processor, show equations if necessary
Cortex-M0+ is the most energy-efficient processor in the Cortex-M family. Suppose a Cortex-M0+ processor takes 100...
Cortex-M0+ is the most energy-efficient processor in the Cortex-M family. Suppose a Cortex-M0+ processor takes 100 HA at running mode, and 50 HA at sleep mode. If the application puts the processor 50% at running mode and 50% at sleep mode, and the processor is powered by two button cell batteries with a total capacity of 600 mAh. How long can the batteries last? (Thumb of rule: Battery Life- Battery Capacity in Milliamps per hour/ Load Current in Mill amps...
Consider two different implementations of the same instruction set architecture. The instructions can be divided into...
Consider two different implementations of the same instruction set architecture. The instructions can be divided into four classes according to their CPI (classes A, B, C, and D). P1 with a clock rate of 2.5 GHz and CPIs of 1, 2, 3, and 3, and P2 with a clock rate of 3 GHz and CPIs of 2, 2, 2, and 2. Given a program with a dynamic instruction count of 1.0E6 instructions divided into classes as follows: 10% class A,...
Micro-processing/ DEBUGGING- Show how the instruction MOV [DI], DX can be assembled into memory address CS:100
Micro-processing/ DEBUGGING- Show how the instruction MOV [DI], DX can be assembled into memory address CS:100
When water freezes in a pipe it can crack the pipe open. I assume this takes...
When water freezes in a pipe it can crack the pipe open. I assume this takes quite a lot of energy as when I try to crack a pipe it can be hard work! I think water freezing is a result of energy (heat) being lost from the water and out of the pipe into the freezing environment around it. So what energy is cracking the pipe and how? When warm and not frozen there is more energy in the...
Consolidated amounts when affiliate's debt is acquired from non-affiliate Assume that a Parent company owns 100...
Consolidated amounts when affiliate's debt is acquired from non-affiliate Assume that a Parent company owns 100 percent of its Subsidiary. On December 31, 2013, the Parent company had a $400,000 (face) bond payable outstanding with a carrying value of $420,000. The bond was originally issued to an unaffiliated company. On that same date, the Subsidiary acquired the bond for $398,000. During 2013, the Parent company reported $180,000 of (pre-consolidation) income from its own operations (i.e., prior to any equity method...
Consolidated amounts when affiliate's debt is acquired from non-affiliate Assume that a Parent company owns 100...
Consolidated amounts when affiliate's debt is acquired from non-affiliate Assume that a Parent company owns 100 percent of its Subsidiary. On December 31, 2013, the Parent company had a $400,000 (face) bond payable outstanding with a carrying value of $420,000. The bond was originally issued to an unaffiliated company. On that same date, the Subsidiary acquired the bond for $399,000. During 2013, the Parent company reported $180,000 of (pre-consolidation) income from its own operations (i.e., prior to any equity method...
Assume the government increases spending by $100. Explain: (1) through the multiplier process, why income Y...
Assume the government increases spending by $100. Explain: (1) through the multiplier process, why income Y will increase; and (2) why the money market (LM Curve) cause investment to fall and thus the increase in GDP to be less than hoped for. I NEED MATH AND GRAPHs please!
Can we transform a non-stationary process into a 1st order weakly stationary or 2nd order weakly...
Can we transform a non-stationary process into a 1st order weakly stationary or 2nd order weakly stationary/covariance-stationary process?
Assume that a COVID-19 test can correctly diagnose 99% of non-infected people and 87% of infected...
Assume that a COVID-19 test can correctly diagnose 99% of non-infected people and 87% of infected people. Suppose that, in a population tested, 5% of people are infected. What is the probability that a person who tested positive is indeed infected?
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT