You are on page 1of 4

EXPERIMENT-3

NAME: Sahithi
ROLL NO : BT22ECE006

AIM:
1. To perform basic arithmetic operations addition, subtraction, multiplication, division
using assembler directives.
2. To use the memory of 8086 for storing the result.

THEORY:
Assembler directives are not instructions that the CPU executes but rather instructions for the
assembler itself. They provide information to the assembler about how to organize and
process the program during the assembly phase.

Here is a brief overview of some common assembler directives in the context of emu8086:

1. ORG (Origin): This directive sets the origin or starting address for the program. It
specifies the memory location where the program's code will be loaded. For
example: ORG 1000H. ORG 1000h
2. DB (Define Byte): This directive reserves space in memory for one or more bytes
and initializes them with specified values. It is often used for defining constants or
data. For example:
DB 65,66,67H.
DB 65, 66, 67 ; Defines three bytes with values 'A', 'B', 'C'
3. DW (Define Word): Similar to DB, but it reserves space for words (two bytes) instead
of bytes. It is commonly used for defining variables or storing data. For example:
DW 1234H.
DW 1234h ; Defines a word with the value 1234h
4. DS (Data Segment): This directive declares the start of the data segment. The data
segment is a section of memory reserved for storing data used by the program. For
example:
DATA_SEG SEGMENT DATA
5. CS (Code Segment): This directive declares the start of the code segment. The code
segment is a section of memory that holds the program's executable code. For
example:
CODE_SEG SEGMENT CODE
6. END: Marks the end of the program. It is used to indicate the end of the source code file
to the assembler. For example:

END
These assembler directives provide essential information for the assembler to generate the
correct machine code and allocate memory appropriately. Understanding and using these
directives correctly is crucial for writing effective and functional assembly programs for the
8086 microprocessor.

1.ADDITION

2.SUBTRACTION
3.MULTIPLICATION

4.DIVISION

5. STORING OF A VALUE FROM ONE LOCATION TO OTHER

RESULT: THE BASIC ARITHMETIC OPERATIONS OF 8 BIT NUMBERS WERE


PERFORMED USING ASSEMBLER DIRECTIVES AND THE RESULTS WERE
VERIFIED.
CONCLUSIONS:
TRANSFER OF DATA WAS DONE FROM ONE LOCATION TO ANOTHER BY
VARIOUS MEANS AND THE RESULT CAME TO BE TRUE IN ALL THE CODES.

You might also like