Question: 3c) Programming Consider the following MIPS assembly language procedure thingy: addi sp, $sp,-4 thingloop: beq $a0, 0(Ssp) $al, s0, thingdone SW addi$to, $t0, 1 thingdo:


3c) Programming Consider the following MIPS assembly language procedure thingy: addi sp, $sp,-4 thingloop: beq $a0, 0(Ssp) $al, s0, thingdone SW addi$to, $t0, 1 thingdo: Sw addi$a0, $a0, 4 addi $al, $a1, -1 thingloop $al, 0(Ssp) $sp, $sp, 4 Sra thingdone: lw addi jr i. What do the first two lines of the assembly language do? ii. What does the last line of the assembly language do? ii. What is the value of Sal when the procedure returns? 3c) Programming Consider the following MIPS assembly language procedure thingy: addi sp, $sp,-4 thingloop: beq $a0, 0(Ssp) $al, s0, thingdone SW addi$to, $t0, 1 thingdo: Sw addi$a0, $a0, 4 addi $al, $a1, -1 thingloop $al, 0(Ssp) $sp, $sp, 4 Sra thingdone: lw addi jr i. What do the first two lines of the assembly language do? ii. What does the last line of the assembly language do? ii. What is the value of Sal when the procedure returns
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
