Answered step by step
Verified Expert Solution
Question
1 Approved Answer
3) 1,2,3, and 4 returned in Svo eturned in Sfo turned in Sfo Spring 2018 and Organization 3. ( 1 8%) The following MIPS Assembly
3) 1,2,3, and 4
returned in Svo eturned in Sfo turned in Sfo Spring 2018 and Organization 3. ( 1 8%) The following MIPS Assembly program contains a loop construct label next). Please answer the following questions: 1) What are the values ofregisters Sao and Sto just before running the loop? (from label loop to data initA: word 20 -30 40-50 10 unitX: word ? (2) What are the values of registers Sa0, Sto0, and Stl after the first iteration of the loop? text globl mairn main: li Sa0, 0 li St0, 20 loop: blez St0, done (3) What are the values of registers $a0, St0, and Stl after the second iteration of the loop? addi lw bltz add Sto, St0,-4 Stl, initA(St0) St1, next Sa0, Sa0, Stl next: b loop done: sw Sa0, unitX($0) (4) What are the values of registers Sa0, $t0, and Stl after the loop is done? li SvO, 10 syscall (5) How many iterations of the loop? What is the value at memory location unitX after the program finishes? 4 (6%) Translate the following arithmetic expression into MIPS assembly instructions. 5. (600) Given the following the data definition, please write a segment of MISP code usin SPIM system call to display the string "Hello Worldn" data .asciiz "Hello Worldm" str: #define a character stringStep 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