Question: Consider the following MIPS code. Assume the instructions before and after are all NOP ( i . e . no operations ) . The code
Consider the following MIPS code. Assume the instructions before and after are all NOP ie no operations The code is executed in a pipeline where there is NO forwarding and branch outcome is known at the end of EX stage. There is no branch prediction ie the pipeline has to stall for each beq instruction
List all the cycle numbers from least to largest in which an instruction is finished. Separate them by commas.
Specify the instructions in the pipeline at the end of th cycle by showing the instruction number in each stage starting with IF The first instruction has index If the pipeline has been stalled, some stages may have "NOP". Separate the answers with commas. An answer for this part would look like no stallbrachjump or NOP,a stall occured or a branch or jump occured
Separate the two answer parts by a semicolon.
: and $t $t $t
: sw $t$t
: sw $t$t
: sub $t $t $t
: beq $t $t # This branch is taken.
: sw $t$t
: sub $t $t $t
: and $t $t $t
: add $t $t $t
: and $t $t $t
: sw $t$t
: and $t $t $t
: sw $t$t
: slt $t $t $t
: or $t $t $t
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
