Question: Linux Language Given a=0xA5, b=0xB3, and both a and b are a byte type. Define a word (16 bits) variable wResult with initial value 0.
Linux Language
Given a=0xA5, b=0xB3, and both a and b are a byte type. Define a word (16 bits) variable wResult with initial value 0. Write a program to finish the following tasks: InstructionSet
1. Calculate (a or b), and move the result to al a. Code b. Show result of al
2. Calculate (a and b), and add the result of step 1, then move the result to al a. Code b. Show result of al
3. Logical right shift by 1 bit on a, and subtracts the result of step 2, then move the result to al (result - step2) a. Code b. Show result of al
4. Arithmetic right shift by 2 bits on b, and add the result of step 3, then move the result to al a. Code b. Show result of al
5. Conducting square operation (x*x) on the result in al from step 4, and move the result to the variable wResult a. Code b. Show result of wResult
Submit the source code and the debugging screenshots of each step
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
