Question: Consider this MIPS code: loop:lw $4, 0 ($16) lw $7, 4 ($16) add $4, $7, $4 sw $4, 0 ($23) addi $16, $16, 8 addi

Consider this MIPS code: loop:lw $4, 0 ($16) lw $7, 4 ($16) add $4, $7, $4 sw $4, 0 ($23) addi $16, $16, 8 addi $23, $23, 4 bne 16, $2, loop Unroll 3 times the MIPS code (i.e., one unrolled iteration does the work of four original iterations). Make it as efficient as you can. Show timing in the 5-stage MIPS pipeline for one unrolled iteration of the loop. Assume that the number of iterations is always a multiple of four. Consider this MIPS code: loop:lw $4, 0 ($16) lw $7, 4 ($16) add $4, $7, $4 sw $4, 0 ($23) addi $16, $16, 8 addi $23, $23, 4 bne 16, $2, loop Unroll 3 times the MIPS code (i.e., one unrolled iteration does the work of four original iterations). Make it as efficient as you can. Show timing in the 5-stage MIPS pipeline for one unrolled iteration of the loop. Assume that the number of iterations is always a multiple of four
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
