Question: MIPS question: .data .half 6, 2 num: .word 7 .globl main .text main: lui $t1, 0x1001 top: lw $t2, -4($t1) beq $s1, $s3, end jal

MIPS question:

.data

.half 6, 2

num: .word 7

.globl main

.text

main:

lui $t1, 0x1001

top:

lw $t2, -4($t1)

beq $s1, $s3, end

jal func

add $s1, $s2, $t1

andi $s1, $0, 0xFFFF

j top

bne $s1, $0, top

end:

func:

sll $v0, $t2, 4

jr $ra

assume (.data starts @ 0x10010000), (.text 0x00400400)

1- find lables values?

2- find the addressing mode of all instructions.

3- convert the program to machine code (hex).

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!