Question: Add and Sub Operations for Different Data Sizes Create an assembly language file named A01-AddSub Ops.asm GA Command Prompt In the data segment declare: .data

 Add and Sub Operations for Different Data Sizes Create an assembly

Add and Sub Operations for Different Data Sizes Create an assembly language file named A01-AddSub Ops.asm GA Command Prompt In the data segment declare: .data Dunp of offset 064 bNume1 BYTE 64 70 bNum2 BYTE 32 bNume3 BYTE 16 Dump of offset 064 bSum BYTE ? FO bDiff BYTE ? bResult BYTE ? Dunp of offset 064 1. Add the three predefined numbers together and store in bSum. 60 2. Subtract first number from the sum of the second and third number. Dunp of offset 004 Store the result in bDiff. 3070 bDiff = (bNumO2 + bNum3) - bNumo1 Dunp of offset 004 3. Add bSum and bDiff. Store the result in bResult. FFF Use only the MOV, ADD, and SUB commands to manipulate data. Dump of offset 004 Use register designators in the MOV, ADD, and SUB commands that 8060 match the size of BYTE data (AL). Dunp of offset 004 Call Dump Mem to display contents of bSum, bDiff and bResult BO800070 Repeat this process for similarly-named WORD and DWORD operands: Dump of offset 004 Use w (in place of b) as a prefix for the WORD operands. FFFFFFF0 Use only the MOV, ADD, and SUB commands to manipulate data. Dunp of offset 004 Use register designators in the MOV, ADD, and SUB commands that 90000060 match the size of WORD data (AX). Dunp of offset 004 Use dw as the prefix for the DWORD operands. 08088150 Use only the MOV, ADD, and SUB commands to manipulate data. Use register designators in the MOV, ADD, and SUB commands to match the size of DWORD data (EAX). After displaying the three sets of memory dumps, add bSum, wSum, and dwSum together for an overall total. Move zero to the EAX register to initialize all 32 bits in that register before moving values into EAX to add. Use correct register designations for MOV commands to match the size of data (AL 8 bits, AX 16 bits, EAX 32 bits). Store the overall sum in dwTotal (another declared DWORD). Call Dump Mem to display the content of dwTotal. Call WaitMsg right before the exit instruction to pause output in the command prompt window. The complete assembly program has 19 variables (6 in each set of 3 different data sizes + 1 overall total), three separate memory dumps of_Sum, _Diff, and _Result (one for each data item size - 9 total), plus one memory dump of dw Total, all in a single program. Copy both the A01-AddSubOps.asm and A01-AddSubOps.exe files to a folder C:ICSIS250 you create

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!