Skip to content
Snippets Groups Projects
Commit 0a73ee46 authored by Le10.Anh@live.uwe.ac.uk's avatar Le10.Anh@live.uwe.ac.uk
Browse files

Update file task1.asm

parent a39f27d3
No related branches found
No related tags found
No related merge requests found
%include "asm_io.inc"
segment .data
integer1 dd 15 ; first int
integer2 dd 6 ; second int
segment .bss
result resd 1 ; result
segment .text
global asm_main
asm_main:
pusha
mov eax, [integer1] ; eax = int1
add eax, [integer2] ; eax = int1 + int2
mov [result], eax ;result = int1 + int2
call print_int ; ; print result
popa
mov eax, 0
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment