Question
I need help on solving this assembly program. We are using visual studio community and the x86 processor, and they all are 32 bit programs.
I need help on solving this assembly program. We are using visual studio community and the x86 processor, and they all are 32 bit programs.
1) Create a definition of each data type listed below. Initialize each variable to a value that is consistent with its data type. Then move each variable into a register and step through your program to make sure that it works. Note: Make sure that your variable sizes match the register sizes. BYTE, SBYTE, WORD, SWORD, DWORD, SDWORD,REAL4 Variables are in memory. To see them, while paused in debug mode, add a Memory window to your view. You can type on addresses to find values. To find a variable by name, use & in front of it. (e.g. for a variable named bVar, use &bVar).
2) Declare an array of 60 uninitialized unsigned doubleword values. Create another array of 60 unsigned doublewords, initialized to abcd. Look at these arrays in the memory window and note how they are stored. (Intel architecture uses little - endian order).
3) Create a DWORD variable in which the hexadecimal data would be stored internally as 12345678 .
4) Define a symbol for your name as a null-terminated string.
5) Write a sequence of MOV instructions that will exchange the upper and lower words in a doubleword variable named three. ; data segment .data three DWORD 12345678h| 6) a. Implement the "Summing an Integer Array" program from 4.5.4. Make sure that it works. 6) b. Update the "Summing an Integer Array" program using a scale factor with indexed addressing. Tips: . Know when flags are set and cleared. Using hexadecimal will help you keep track of how many bits are in your registers and variables. Using pseudocode will help you solve problems before you begin coding. Note that XCHG cannot swap mem-mem. You can use ESI and EDI to remember the front and the back of arrays. 5) Write a sequence of MOV instructions that will exchange the upper and lower words in a doubleword variable named three. ; data segment .data three DWORD 12345678h| 6) a. Implement the "Summing an Integer Array" program from 4.5.4. Make sure that it works. 6) b. Update the "Summing an Integer Array" program using a scale factor with indexed addressing. Tips: . Know when flags are set and cleared. Using hexadecimal will help you keep track of how many bits are in your registers and variables. Using pseudocode will help you solve problems before you begin coding. Note that XCHG cannot swap mem-mem. You can use ESI and EDI to remember the front and the back of arraysStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started