Question: (4) [14 pts] The following MPS code is executed on a 5-stage pipelined processor with full forwarding: lw $t1, -12 ($t3) LOOP: addi $t1, $t1,

 (4) [14 pts] The following MPS code is executed on a

(4) [14 pts] The following MPS code is executed on a 5-stage pipelined processor with full forwarding: lw $t1, -12 ($t3) LOOP: addi $t1, $t1, -2 bne stl, Szero, LOOP sub $t3, $t3, $t1 sw $t4, 0($t 3) Assume that there is no branch prediction and the branch condition is evaluated in the ID stage, the initial data stored in register $t 3 is 0x00000014. The initial data stored in memory is as follows: Memory address Ox0000 000 4 Ox0000 0008 Ox0000 0000 Data Ox0000 0001 Ox0000 0004 Ox0000 0002 (a) [6 pts] Consider inserting minimum number of NOP instructions into the above MIPS code to resolve hazards. You can use "NOP to represent a NOP instruction. Show your new MIPS code sequence according to the two following cases: (1) Assume there is not any forwarding unit and path. (2) Assume there are full forwarding units and paths. (6) [8 pts] Complete the pipeline execution diagram of the new code sequence for the first 17 cycles and indicate the data forwarding. Please indicate the forwarding using the format [cycle mumber][pipeline register name] [cycle number][pipeline stage], e.g. 9EX/MEM-9EX means that the data is forwarded from the EX/MEM pipeline register at cycle 9 to the EX stage at cycle 9. The execution of the first instruction has been given as an example. You do not need to show the execution of NOP instructions. Pipeline execution diagram: Instruction 1 2 3 3 4 | 5 6 8 8 9 10 11 12 13 | 14 15 16 1 17 lw $t1,-125t) IF ID EX NEN WB

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!