Question: Consider the following MIPS code (including DSP extension D). Assume this was generated from some C code where $a0 is a pointer to a char

 Consider the following MIPS code (including DSP extension D). Assume this

Consider the following MIPS code (including DSP extension D). Assume this was generated from some C code where $a0 is a pointer to a char array c and $a1 is N, C's length. addu $to, $zero, $zero addu $t2, $zero, $zero j cond loop: addu $t1, $a0,$to lw $t1, 8($t1) raddu.w.qb $t1,$t1 addu $t2, $t2, $t1 addiu $t0,$t0, 4 cond: slt $t1, $t0, $al bne $t1, $zero, loop exit: How many instructions are executed in terms of N? You should leave it unsimplified without spaces (e.g., 100+42*N). What is the minimum binary size (in bytes) for this sequence of instructions (i.e., minimum machine code size)? What would the decimal value of $t2 be after the execution of the loop if N=4 and c's values were initialized to 150, 0, 31, 200? Consider the following MIPS code (including DSP extension D). Assume this was generated from some C code where $a0 is a pointer to a char array c and $a1 is N, C's length. addu $to, $zero, $zero addu $t2, $zero, $zero j cond loop: addu $t1, $a0,$to lw $t1, 8($t1) raddu.w.qb $t1,$t1 addu $t2, $t2, $t1 addiu $t0,$t0, 4 cond: slt $t1, $t0, $al bne $t1, $zero, loop exit: How many instructions are executed in terms of N? You should leave it unsimplified without spaces (e.g., 100+42*N). What is the minimum binary size (in bytes) for this sequence of instructions (i.e., minimum machine code size)? What would the decimal value of $t2 be after the execution of the loop if N=4 and c's values were initialized to 150, 0, 31, 200

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!