; Guide to Assembly Language
; Section 12.9 Complete Program
; Copyright 2019, James T. Streib
.686
.model flat,c
.stack 100h
.data
num1 sdword 3
num2 sdword 5
num3 sdword ?
.code
main proc
inc eax
inc ecx
inc edx
inc ebx
inc esp
inc ebp
inc esi
inc edi
dec eax
dec ecx
dec edx
dec ebx
dec esp
dec ebp
dec esi
dec edi
mov eax,eax
mov eax,ecx
mov eax,edx
mov eax,ebx
mov eax,esp
mov eax,ebp
mov eax,esi
mov eax,edi
mov ecx,eax
mov ecx,ecx
mov ecx,edx
mov ecx,ebx
mov eax,1
mov ecx,10
mov edx,-1
mov ebx,-10
mov eax,num2
mov num3,eax
mov ecx,num2
mov edx,num2
mov ebx,num2
mov num3,ecx
mov num3,edx
mov num3,ebx
add eax,eax
add eax,ecx
add eax,edx
add eax,ebx
sub ecx,eax
sub ecx,ecx
sub ecx,edx
sub ecx,ebx
add eax,num2
add ecx,num2
add edx,num2
add ebx,num2
sub eax,num2
sub ecx,num2
sub edx,num2
sub ebx,num2
mov esi,num2
mov edi,num2
lea esi, num2
lea edi, num2
mov esi, offset num2
mov edi, offset num2
mov esi,4
mov edi,4
jmp around
above: nop
nop
jmp above
around: nop
ret
main endp
end