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 R1, R2, R3 b) What values will be in R1 and R2 after this instruction is executed: lw R2, 8(R1) c) What values will be in R2 and R4 after this instruction is executed: addi R2, R4, 0x0020
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 R1, R2, R3
b) What values will be in R1 and R2 after this instruction is executed: lw R2, 8(R1)
c) What values will be in R2 and R4 after this instruction is executed: addi R2, R4, 0x0020
![Register
R1
R2
R3
R4
Value
12
16
20
24
Memory Location
12
16
20
24
Value
12
20
24
40](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F9884f16d-4d16-4c91-b59e-2f0bef0df884%2Fe9185668-d755-4d05-8661-7a749f2229e6%2F2cwq9xp_processed.jpeg&w=3840&q=75)
![](/static/compass_v2/shared-icons/check-mark.png)
a)
Give the values of R1, R2, and R3 after this instruction:
sub R1, R2, R3
R1 = 12
R2 = 16
R3 = 20
sub R1, R2, R3 means R3-R2 will be stored in R1.
So, R3-R2 -> 20-16 = 4
After the instruction, R3 = 20, R2 = 16, R1= 4.
Trending now
This is a popular solution!
Step by step
Solved in 3 steps
![Blurred answer](/static/compass_v2/solution-images/blurred-answer.jpg)
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
![Database System Concepts](https://www.bartleby.com/isbn_cover_images/9780078022159/9780078022159_smallCoverImage.jpg)
![Starting Out with Python (4th Edition)](https://www.bartleby.com/isbn_cover_images/9780134444321/9780134444321_smallCoverImage.gif)
![Digital Fundamentals (11th Edition)](https://www.bartleby.com/isbn_cover_images/9780132737968/9780132737968_smallCoverImage.gif)
![C How to Program (8th Edition)](https://www.bartleby.com/isbn_cover_images/9780133976892/9780133976892_smallCoverImage.gif)
![Database Systems: Design, Implementation, & Manag…](https://www.bartleby.com/isbn_cover_images/9781337627900/9781337627900_smallCoverImage.gif)
![Programmable Logic Controllers](https://www.bartleby.com/isbn_cover_images/9780073373843/9780073373843_smallCoverImage.gif)