[SOLVED] COMP2660 Assignment1-an ASM program

30.00 $

Category:
Click Category Button to View Your Next Assignment | Homework

You will receive the following solution file(s) instantly after successful payment:

zip file icon a01-5yod3m.zip (1.5 KB)
Assignment Instructions Updated Recently? Submit Below and we will provide new Solution!
Submit New Instructions
đź”’ Securely Powered by:
Secure Checkout
5/5 - (2 votes)

Write an ASM program that evaluates the following expression, using variables:

EDX = (A + B) – (C + D)

Declare and initialize the memory variables A, B, C, and D to 32-bit signed integer values -10, +210, -3456, +43210, respectively. Register EDX contains the result.

  1. Display the string “EDX = (A + B) – (C + D)” alone in a single line.
  2. Display the values of all the variables together in the next line; each separated by 3 spaces and a dash and 3 spaces again.
  3. Display an empty line
  4. Display the result EDX, in binary, then in decimal, and then in hexadecimal; each in a separate line.

Question  #2 (10 points)

Write an ASM program that uses the variable below and MOV instructions to copy the value from bigEndian to littleEndian, reversing the order of the bytes. The number’s 32bit value is understood to be 12345678h.

.data bigEndian  BYTE 12h, 34h, 56h, 78h littleEndian DWORD ?

Display the values of bigEndian and littleEndian.

  • a01-5yod3m.zip