6) Write assembly language code that takes an 8-bit signed number in a register as its input and sign extends the number to 32-bits. The 8-bit signed input will be stored in the least significant byte of the register. The upper three bytes of the input register might contain any value. You may choose any register as the input and output. Sign extending means that the sign bit (bit 7 of the input) is copied to the upper 24-bits in the answer. Examples: input: Ox1F54 E778, output: 0x0000 0078 input: OXOF39_29E2, output: 0XFFFF FFE2

Systems Architecture
7th Edition
ISBN:9781305080195
Author:Stephen D. Burd
Publisher:Stephen D. Burd
Chapter2: Introduction To Systems Architecture
Section: Chapter Questions
Problem 2VE: A(n) __________ is a storage location implemented in the CPU.
icon
Related questions
Topic Video
Question

just use simple assembly code to do the question. 

6) Write assembly language code that takes an 8-bit signed number in a register as its input and sign extends
the number to 32-bits. The 8-bit signed input will be stored in the least significant byte of the register. The
upper three bytes of the input register might contain any value. You may choose any register as the input and
output.
Sign extending means that the sign bit (bit 7 of the input) is copied to the upper 24-bits in the ansv
Examples:
input: Ox1F54 E778, output: Ox0000_0078
input: OXOF39_29E2, output: 0XFFFF_FFE2
Transcribed Image Text:6) Write assembly language code that takes an 8-bit signed number in a register as its input and sign extends the number to 32-bits. The 8-bit signed input will be stored in the least significant byte of the register. The upper three bytes of the input register might contain any value. You may choose any register as the input and output. Sign extending means that the sign bit (bit 7 of the input) is copied to the upper 24-bits in the ansv Examples: input: Ox1F54 E778, output: Ox0000_0078 input: OXOF39_29E2, output: 0XFFFF_FFE2
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Instruction Format
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.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Systems Architecture
Systems Architecture
Computer Science
ISBN:
9781305080195
Author:
Stephen D. Burd
Publisher:
Cengage Learning