Question: Given the following code in MIPS: 1 2 3 MUL R3, R1, R2 ADD R5, R4, R3 ADD R6, R4, R5 MUL R7, R8, R9


Given the following code in MIPS: 1 2 3 MUL R3, R1, R2 ADD R5, R4, R3 ADD R6, R4, R5 MUL R7, R8, R9 MUL R10, R5, R6 5 Calculate the number of cycles it takes to execute the given code on the following models: For all machine models, use the basic instruction cycle as follows: Fetch (one clock cycle) Decode (one clock cycle) Execute (MUL takes 6, ADD takes 4 clock cycles). The multiplier and the adder are not pipelined. Write-back (one clock cycle) For simplicity, we assume that there is no memory stage in the pipeline, i.e. only four stages in the pipeline. Do not forget to list any assumptions you make about the pipeline structure (e.g., how is data forwarding done between pipeline stages) a)[4 marks] A non-pipelined machine. b) [4 marks] A pipelined machine with scoreboarding and five adders and five multipliers without data forwarding. c) [4 marks] A pipelined machine with scoreboarding and five adders and five multipliers with data forwarding. d) [4 marks) A pipelined machine with scoreboarding and one adder and one multiplier without data forwarding. e) [4 marks] A pipelined machine with scoreboarding and one adder and one multiplier with data forwarding
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
