Question
Ch02.12 Suppose that a new MIPS instruction, called bcp, was designed to copy a block of words from one address to another. Assume that this
Ch02.12 Suppose that a new MIPS instruction, called bcp, was designed to copy a block of words from one address to another. Assume that this instruction requires that the starting address of the source block be in register $t1 and that the destination address be in $t2. The instruction also requires that the number of words to copy be in $t3 (which is > 0). Furthermore, assume that the values of these registers as well as register $t4 can be destroyed in executing this instruction (so that the registers can be used as temporaries to execute the instruction).
li $t1, src
li $t2, dst
li $t3, count
bcp
Do the following: Write the MIPS assembly code to implement a block copy without this bcp instruction. Estimate the total cycles necessary for each realization to copy 100-words on the multicycle machine, assuming each instruction takes 1 cycle.
2.5 Write the code for the following MIPS binary instructions:
a) 0x01098020
b) 0x000DB940
c) 0xAD620004
d) 0x0810000c
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started