Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Consider this sequence of instructions. CC 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19

image text in transcribed

Consider this sequence of instructions. CC 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 1 lw $to, 4 ($sp) 2 lw $t1 8 ($sp) 3 add $t2, $t0, $t1 4 sub $t2, $t2, $t1 5 addi $t2, $t2, 1 6 sw $t2 12 ($sp) (a) Draw a pipeline diagram, similar to the ones in the lecture notes we have been drawing in class, showing the pipeline stages of each instruction as the instruction moves through the pipeline. Assume the only way we have of resolving data hazards is to stall the pipeline by inserting bubbles. (b) What is the average IPC (instructions per clock)? For full credit, show/explain your work. (c) Assume all of these data hazards could be eliminated by redesigning the hardware, so no bubbles would be required. In that case, the average IPC would increase. Calculate the IPC for this sequence of instructions under ideal conditions, i.e., all data hazards are eliminated by clever hardware design. For full credit, show/explain your work. You do not need to include the pipeline diagram in your solution. (d) How many fewer clocks, expressed as a percentage relative to the sequence of (a), does the ideal sequence of (c) take. For example, if clocks_ and clocks_c are the number of clock cycles to execute the sequences of exercises (a) and (c), then the question is to calculate clocks (c), then the question is to calculate | clocks_a - clocks_c|./clocks_a For full credit, show/explain your work. (e) How much faster, expressed as a percentage relative to sequence (a), is the instruction sequence of exercise (c), i.e., the instruction is asking you to calculate |clocks_c - clocks_a|/clocks_c. For full credit, show/explain your work. Consider this sequence of instructions. CC 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 1 lw $to, 4 ($sp) 2 lw $t1 8 ($sp) 3 add $t2, $t0, $t1 4 sub $t2, $t2, $t1 5 addi $t2, $t2, 1 6 sw $t2 12 ($sp) (a) Draw a pipeline diagram, similar to the ones in the lecture notes we have been drawing in class, showing the pipeline stages of each instruction as the instruction moves through the pipeline. Assume the only way we have of resolving data hazards is to stall the pipeline by inserting bubbles. (b) What is the average IPC (instructions per clock)? For full credit, show/explain your work. (c) Assume all of these data hazards could be eliminated by redesigning the hardware, so no bubbles would be required. In that case, the average IPC would increase. Calculate the IPC for this sequence of instructions under ideal conditions, i.e., all data hazards are eliminated by clever hardware design. For full credit, show/explain your work. You do not need to include the pipeline diagram in your solution. (d) How many fewer clocks, expressed as a percentage relative to the sequence of (a), does the ideal sequence of (c) take. For example, if clocks_ and clocks_c are the number of clock cycles to execute the sequences of exercises (a) and (c), then the question is to calculate clocks (c), then the question is to calculate | clocks_a - clocks_c|./clocks_a For full credit, show/explain your work. (e) How much faster, expressed as a percentage relative to sequence (a), is the instruction sequence of exercise (c), i.e., the instruction is asking you to calculate |clocks_c - clocks_a|/clocks_c. For full credit, show/explain your work

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Administration The Complete Guide To Dba Practices And Procedures

Authors: Craig S. Mullins

2nd Edition

0321822943, 978-0321822949

More Books

Students also viewed these Databases questions

Question

Compute the derivative f(x)=(x-a)(x-b)

Answered: 1 week ago

Question

Have ground rules been established for the team?

Answered: 1 week ago

Question

Is how things are said consistent with what is said?

Answered: 1 week ago

Question

Do you currently have a team agreement?

Answered: 1 week ago