Assume register R1 contains an arbitrary integer A, and R2 contains an arbitrary integer B. Which of the following sequences of machine instructions implement the exact condition A < B so that the branch skips the halt instruction? Mark all correct choices. FYI: Be certain; Canvas deducts points for incorrect choices. 0 U U 1001 011 001 1 11111 0001 011 011 1 00001 0001 011 010 0 00 011 0000 001 000011111 1111 0000 0010 0101 0001 011 001 0 00 010 0000 001 000011111 1111 0000 0010 0101 1001 011 001 1 11111 0001 011 011 1 00001 0001 011 010 0 00 011 0000 101 000011111 1111 0000 0010 0101 1001 011 010 1 11111 0001 011 011 1 00001 0001 011 001 0 00 011 0000 010 000011111 1111 0000 0010 0101 1001 011 010 1 11111 0001 011 011 1 00001 0001 011 001 0 00 011 0000 100 000011111 1111 0000 0010 0101 0001 011 001 0 00 010 0000 101 000011111 1111 0000 0010 0101
Assume register R1 contains an arbitrary integer A, and R2 contains an arbitrary integer B. Which of the following sequences of machine instructions implement the exact condition A < B so that the branch skips the halt instruction? Mark all correct choices. FYI: Be certain; Canvas deducts points for incorrect choices. 0 U U 1001 011 001 1 11111 0001 011 011 1 00001 0001 011 010 0 00 011 0000 001 000011111 1111 0000 0010 0101 0001 011 001 0 00 010 0000 001 000011111 1111 0000 0010 0101 1001 011 001 1 11111 0001 011 011 1 00001 0001 011 010 0 00 011 0000 101 000011111 1111 0000 0010 0101 1001 011 010 1 11111 0001 011 011 1 00001 0001 011 001 0 00 011 0000 010 000011111 1111 0000 0010 0101 1001 011 010 1 11111 0001 011 011 1 00001 0001 011 001 0 00 011 0000 100 000011111 1111 0000 0010 0101 0001 011 001 0 00 010 0000 101 000011111 1111 0000 0010 0101
Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
Related questions
Question
Please choose ALL (multiple answers) correct answers) with explanation. Thank you!

Transcribed Image Text:Assume register R1 contains an arbitrary integer A, and R2 contains an arbitrary integer B. Which of the following sequences of machine instructions implement the exact condition A < B so that the branch skips the halt instruction?
Mark all correct choices. FYI: Be certain; Canvas deducts points for incorrect choices.
Option 1:
```
1001 011 001 1 11111
0001 011 011 1 00001
0001 011 010 0 0 011
0000 001 000011111
1111 0000 0010 0101
```
Option 2:
```
0001 011 001 0 00 010
0000 001 000011111
1111 0000 0010 0101
```
Option 3:
```
1001 011 001 1 11111
0001 011 011 1 00001
0001 011 010 0 00 011
0000 010 000011111
1111 0000 0010 0101
```
Option 4:
```
1001 011 010 1 11111
0001 011 011 1 00001
0001 011 001 0 00 011
0000 100 000011111
1111 0000 0010 0101
```
Option 5:
```
0001 011 001 0 00 010
0000 101 000011111
1111 0000 0010 0101
```
![**Table of LC-3 Instructions:**
| Bits (15 to 0) | Instruction | Semantics |
|------------------|-------------|----------------------------------------------------------------------|
| **NOT** | 1001 DST SRC 1 1 1 1 1 1 | R[DST] ← NOT(R[SRC]) |
| **ADD** | 0001 DST SRC1 0 0 0 SRC2 | R[DST] ← R[SRC1] + R[SRC2] |
| **AND** | 0101 DST SRC1 0 0 0 SRC2 | R[DST] ← R[SRC1] & R[SRC2] |
| **ADD (Immediate)** | 0001 DST SRC 1 Immediate (5)| R[DST] ← R[SRC] + SEXT(Immediate5) |
| **AND (Immediate)** | 0101 DST SRC 1 Immediate (5)| R[DST] ← R[SRC] & SEXT(Immediate5) |
| **LDR** | 0110 DST BASE Offset (6) | R[DST] ← M[R[BASE]+SEXT(Offset6)] |
| **STR** | 0111 SRC BASE Offset (6) | M[R[BASE]+SEXT(Offset6)] ← R[SRC] |
| **LD** | 0010 DST PC Offset (9) | R[DST] ← M[inc(PC)+SEXT(PCOffset9)] |
| **ST** | 0011 SRC PC Offset (9) | M[inc(PC)+SEXT(PCOffset9)] ← R[SRC] |
| **LDI** | 1010 DST PC Offset (9) | R[DST] ← M[M[inc(PC)+SEXT(PCOffset9)]] |
| **STI** | 1011 SRC PC Offset (9) | M[M[inc(PC)+SEXT(PCOffset9)]] ← R[SRC] |
| **LEA** | 1110 DST PC Offset (9) | R[DST] ← inc(PC)+SEXT(PCOffset9) |
| **BR** | 0000 N Z P PC Offset (9) | PC](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F582ddd12-f1f2-413d-867c-2f61c510c057%2F1ea41978-fd81-4eb6-afc3-1ca48de68641%2Fakdc8wn_processed.jpeg&w=3840&q=75)
Transcribed Image Text:**Table of LC-3 Instructions:**
| Bits (15 to 0) | Instruction | Semantics |
|------------------|-------------|----------------------------------------------------------------------|
| **NOT** | 1001 DST SRC 1 1 1 1 1 1 | R[DST] ← NOT(R[SRC]) |
| **ADD** | 0001 DST SRC1 0 0 0 SRC2 | R[DST] ← R[SRC1] + R[SRC2] |
| **AND** | 0101 DST SRC1 0 0 0 SRC2 | R[DST] ← R[SRC1] & R[SRC2] |
| **ADD (Immediate)** | 0001 DST SRC 1 Immediate (5)| R[DST] ← R[SRC] + SEXT(Immediate5) |
| **AND (Immediate)** | 0101 DST SRC 1 Immediate (5)| R[DST] ← R[SRC] & SEXT(Immediate5) |
| **LDR** | 0110 DST BASE Offset (6) | R[DST] ← M[R[BASE]+SEXT(Offset6)] |
| **STR** | 0111 SRC BASE Offset (6) | M[R[BASE]+SEXT(Offset6)] ← R[SRC] |
| **LD** | 0010 DST PC Offset (9) | R[DST] ← M[inc(PC)+SEXT(PCOffset9)] |
| **ST** | 0011 SRC PC Offset (9) | M[inc(PC)+SEXT(PCOffset9)] ← R[SRC] |
| **LDI** | 1010 DST PC Offset (9) | R[DST] ← M[M[inc(PC)+SEXT(PCOffset9)]] |
| **STI** | 1011 SRC PC Offset (9) | M[M[inc(PC)+SEXT(PCOffset9)]] ← R[SRC] |
| **LEA** | 1110 DST PC Offset (9) | R[DST] ← inc(PC)+SEXT(PCOffset9) |
| **BR** | 0000 N Z P PC Offset (9) | PC
Expert Solution

This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution!
Trending now
This is a popular solution!
Step by step
Solved in 5 steps

Follow-up Questions
Read through expert solutions to related follow-up questions below.
Follow-up Question
Here, you answered when A = B. But the question asks when A < B. I was wondering if you could please re-phase so when A < B. Thank you!
Solution
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Recommended textbooks for you

Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education

Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON

Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON

Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education

Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON

Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON

C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON

Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning

Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education