0% found this document useful (0 votes)
30 views19 pages

12th Lecture - Assembler Directives

Uploaded by

rgarg6191
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
30 views19 pages

12th Lecture - Assembler Directives

Uploaded by

rgarg6191
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 19

Assembler Directives

Dr. Manju Khurana


Assistant Professor,
CSED
TIET, Patiala
manju.khurana@thap
ar.edu

1
Assembler Directives
The instructions that will give the
information to assembler for performing
assembling are called Assembler Directives.
These assembler directives are not executed
by microprocessor, so they are also called
dummy or pseudo instructions.

When Assembler performs assembling:

Instructions are translated from assembly


language to the machine language.
Each byte of the instruction code or data is
allotted effective address of one memory
location. 2
1. DB (Define Byte)
The assembler directive creates storage for a
byte or a group of bytes and optionally
assigns starting values.

Examples are:
DB 12H, 23H, 45H, 56H
NEXT DB 12, 34, 45
DB 100 DUP (0)
DB 100 DUP (?)
DB ‘DURG’

3
2. DW (Define Word)
It is used for memory location allotment of
data word (16 bits), i.e. it is allotted two
memory locations for each word.

Examples are:
DW 93H, 0ABCDH, 6745H
NEXT DW 12H, 0AB34H, 4567H
DW 200 DUP (0ABCDH)
DW 100 DUP (?)

4
3. DD (Define Double Word)
It is used for memory location allotment of
data double word (32 bits), it creates storage
for a 32-bit double word variables, with the
option of giving it a starting value.

Example is:
NEXT DD 12345678H, 7890H, 0H

5
4. DQ (Define Quad Word)
It is used for memory location allotment of
data quad word (64 bits), it creates storage
for a 64-bit double word variables, with the
option of giving it a starting value.

Example is:
DURG DQ 123456789ABCDEF0H, 8988H, 515H

6
5. DT (Define Ten Bytes)

7
6. ASSUME

8
7. SEGMENT and ENDS

9
8. ORG (Originate)

10
9. END

11
10. EQU

12
11. LABEL

13
12. LENGTH

14
13. PROC and ENDP

15
13. PROC and ENDP

16
14. EVEN

17
15. OFFSET

18

You might also like