Professional Documents
Culture Documents
N098 - MM - Exp 4
N098 - MM - Exp 4
N098 - MM - Exp 4
EXP . 4
Procedure:
Steps to be followed to execute 8086 program in tasm software
Write Assembly language program in notepad.
Save this program file in tasm /bin folder with .asm extension
Go to window start then select run
Type command cmd (command window will pop up for dos prompt).
Change the directory (cd\)
Select path c:cd tasm/bin
Write command tasm/zi file name .asm
Write command tlink/v file name .obj
Write command td file name .exe
Program Window will appear
Select view tab then select cpu
Press F8 to execute program in single step mode
Select view tab then select variable to see the result.
Program:
A) MOVSB without repeat
data segment
Block1 db 08 dup (98h)
Counter db 08
data ends
extra segment
Block2 db 08 dup (00h)
extra ends
code segment
start: assume ds: data, cs: code, es:extra
mov ax,data
mov ds,ax
mov ax,extra
mov es,ax
lea si,Block1
lea di,Block2
mov cl,counter
CLD
UP:MOVSB
DEC CL
JNZ UP
mov ax,4c00h
int 21h
code ends
end start
cld
rep movsb
mov ax,4c00h
int 21h
code ends
end start
CLD
UP:MOVSW
DEC CL
JNZ UP
mov ax,4c00h
int 21h
code ends
end start
RESULT:
A) MOVSB without repeat