Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Please help with the following questions. Show all steps. The following MIPS program computes a function of $9 and $10, and places the result in
Please help with the following questions. Show all steps.
The following MIPS program computes a function of $9 and $10, and places the result in $11. a) Assume that $9 is initially 5, and $10 is initially 12. What value does $11 have after this program is run? b) Write a mathematical equation that describes this function in terms of $9 and $10. $11- 1. addi $3, $0, 3 add $9, $9, $9 addi $3,$3,1 bne $3, SO, loop add $11, $9, $10 loop: Assume that an add/addi takes one cycle and a bne takes two cycles. How many cycles does it take to execute the program in problem 1? Don't forget that the program loops several times. 2. 3. Implement the following using MiIPs instructions. Do not use any pseudolinstructions for this problem. Branch to a label "stage2" if $tO is greater than or equal to $t1. Implement the following using MIPs instructions. Do not use any pseudoinstructions for this problem If $s1 is less than $s2, set $t5 to 4, otherwise set $t5 to 5 4. 5. Implement the following using MIPs instructions. Do not use any pseudoinstructions for this problem. While $t4 is less than 7, increment St4 by 1 (set St4 to 0 before the loop starts)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