Question
Hi, I just want to check if my code follows the instructions for part 3B in assembly language. Thanks. INSTRUCTIONS: CODE: ; TITLE Adding four
Hi, I just want to check if my code follows the instructions for part 3B in assembly language. Thanks.
INSTRUCTIONS:
CODE:
; TITLE Adding four 32-bit Integer Variables (3B.asm) ; Program Description: ; This program will contain four 32-bit integer variables and add these values together, saving the result in a variable The sum should still be in the EAX register when you call the library routine DumpRegs. ; Author: Yen Jiu ; Creation Date: September 20, 2018 ; Status: Completed
INCLUDE Irvine32.inc .data ; declaring hexadecimal variables var1 SDWORD 30050201h var2 SDWORD 60040102h var3 SDWORD 72010103h var4 SDWORD 0B0700105h
.code main PROC MOV EAX, var1 ; moving var1 to EAX register ADD EAX, var2 ; adding var2 to EAX register ADD EAX, var3 ; adding var3 to EAX register ADD EAX, var4 ; adding var4 to EAX register
call dumpregs ; displaying registers call Waitmsg
exit main ENDP END main
OUTPUT:
Assignment 3A - A program that adds and subtracts 32-bit numbers After installing the assembler on the computer, enter the following program, save it, assemble it and run it. Do not forget to add a comment with your name in it You will hand in a listing (e.g., addsum.asm) that should include your name TITLE Add and Subtract (AddSum.asm) This program adds and subtracts 32-bit integers
Step 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