Consider the following assembly language programsegment: funca : la $t0 , n lw $
ID: 3609139 • Letter: C
Question
Consider the following assembly language programsegment: funca : la $t0 , n lw $s0 , 0( $t0 ) addi $s2 , $zero , 1 sub $s1 , $s1 , $s1 loop : s l l $t0 , $s2 , 3 1 s l t $t1 , $t0 , $z e ro bne $t1 , $zero , skip add $s1 , $s1 , $s2 skip : addi $s2 , $s2 , 1 beq $s2 , $s0 , done j loop done : addi $v0 , $s1 , 0 j r $ran : .word 11 (a) List instructions that will contribute an entry to therelocation table. Consider the following assembly language programsegment: funca : la $t0 , n lw $s0 , 0( $t0 ) addi $s2 , $zero , 1 sub $s1 , $s1 , $s1 loop : s l l $t0 , $s2 , 3 1 s l t $t1 , $t0 , $z e ro bne $t1 , $zero , skip add $s1 , $s1 , $s2 skip : addi $s2 , $s2 , 1 beq $s2 , $s0 , done j loop done : addi $v0 , $s1 , 0 j r $ra
n : .word 11 (a) List instructions that will contribute an entry to therelocation table.
Explanation / Answer
please rate - thanks Consider the following assembly language programsegment: relocation table will have any addresses needed, so it will beanything that has needs an address funca : la $t0 , n lw $s0 , 0( $t0 ) addi $s2 , $zero , 1 sub $s1 , $s1 , $s1 loop : s l l $t0 , $s2 , 3 1 s l t $t1 , $t0 , $z e ro bne $t1 , $zero , skip add $s1 , $s1 , $s2 skip : addi $s2 , $s2 , 1 beq $s2 , $s0 , done j loop done : addi $v0 , $s1 , 0 j r $ran : .word 11 (a) List instructions that will contribute an entry to therelocation table. Consider the following assembly language programsegment: relocation table will have any addresses needed, so it will beanything that has needs an address funca : la $t0 , n lw $s0 , 0( $t0 ) addi $s2 , $zero , 1 sub $s1 , $s1 , $s1 loop : s l l $t0 , $s2 , 3 1 s l t $t1 , $t0 , $z e ro bne $t1 , $zero , skip add $s1 , $s1 , $s2 skip : addi $s2 , $s2 , 1 beq $s2 , $s0 , done j loop done : addi $v0 , $s1 , 0 j r $ra
n : .word 11 (a) List instructions that will contribute an entry to therelocation table.
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.