Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

mDwordWrite a macro named mDWORD that receives one 3 2 - bit memory operand. The macro should use the parameter as the n value representing

mDwordWrite a macro named mDWORD that receives one 32-bit memory operand. The macro should use the parameter as the n value representing the number of dwords (double words).Don't forget about the LOCAL directive for labels inside of macros.Write a program that tests your macro by invoking it multiple times in a loop in main, passing it an argument of different values, including zero. Your assembly language program should echo print the n value of the words and the calculated final values of words, bytes, and bites with appropriate messages. If a non-positive number is entered then an error message should be displayed. Incomplete submissions will receive partial credit. Solutions that prompt the user to enter n and display the correct output will receive more credit. If using a loop in main, do NOT put the macro into the body of loop that iterates more than four (4) times.Upload the asm program file and macro file (if it is separate) and submit them here. If you have a separate file for your macro, you will need to compress (zip) a folder with both files, the macro text file and the .asm file. Canvas exam questions only allow one file to be uploaded, so those of you who use two files will need to upload both by compressing (zipping) them into one folder by selecting both files, right click, Send to, compressed (zipped), name the folder and then upload the file with the zipper to the exam question.Program and macro should be properly documented with heading comments and pseudocode comments to the right of the assembly language.Notes regarding DWORDs to WORDs, BYTEs, and bitesTo calculate the words, bytes and bites of n, multiply a non-negative value of n by 2(n *2) for words. Multiply a non-negative value of n by 4(n*4) for bytes. Multiply a non-negative value of n by 32(n *32) for bites. An entered negative value should display an error message.An entered value of 0 should display a words, bytes and bites value of 0.
1 dword=2 words
1 dword=4 bytes

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions