Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Use the register and memory values in the table below for this question. Assume

ID: 3907591 • Letter: U

Question

Use the register and memory values in the table below for this question. Assume a 32-bit machine. Assume each of the following questions starts from the table values; that is, DO NOT use value changes from one question as propagating into future parts of the question.

a) Give the values of R1, R2, and R3 after this instruction: sub R3, R2, R1

b) What values will be in R1 and R3 after this instruction is executed: load R3, 8(R1)

c) What values will be in the registers after this instruction is executed: addi R2, R3, #8

Register R1 R2 R3 R4 Value 12 16 20 24 Memory Location 12 16 20 24 Value 16 20 24 28

Explanation / Answer

Result after instructions are-

a) sub R3, R2, R1 ; R3 = R2 - R1

R1 = 16, R2 = 20 and R3 = 4

b) load R3, 8(R1) ; R3 = R1+8

R1 = 16 and R3 = 24

c) addi R2, R3, #8 ; R2 = R3 + 8

R1 = 16, R2 = 32, R3 = 24 and R4 = 28

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote