You are on page 1of 3

AIM:

The objective of the project is to develop an assembler in which a user can use his
assembly language programming skills to develop useful assembly language programs.

DESCRIPTION:
The project is programmed using C/C++ runtime mechanisms. This project is about
design and implementation of a 2 pass assembler for a working model 0f 8086 µp. The central
theme of this project is the relationship b/w machine architecture and system software.
In this type of assemblers the source code is scanned twice. Hence the name Two Pass
Assemblers
The two passes are :-
• Pass 1 à Prepares the program to be converted.
• Pass 2 à Generates the object Code
The assembler performs the basic assembler functions such as:
1. Convert mnemonic operation codes to their machine language equivalents.
2. Convert symbolic operands to their equivalent machine address.
3. Build the machine instruction in proper format.
4. Convert the data constants specified in the source program into their machine
representation.
5. Write the object program and assembly listing

DATA STRUCTURES:
OPERATION CODE TABLE
 Contains mnemonic operation codes and its machine language equivalents.
 During pass 1, it is used to validate opcodes in the source prgm.
 During pass 2, it translates the opcodes to machine codes.
SYMBOL TABLE
 Contains name and addresses for each label in the source prgm.
 During pass 1, labels and their addresses are entered into the table.
 During pass 2, it acts as a look up table to generate to machine code.
LOCATION COUNTER
 It is a variable.
 Helps in assigning addresses to each stmt in the prgm.
SOFTWARE REQUIREMENTS:
Any linux/unix with gcc complier,or windows with turbo/Borland/visual c/c++ complier

EFFECTS OF EXECUTION:
Assembly language programs will be converted to object code which is ready to be loaded
and executed.

DIAGRAMATIC REPRESENTATION:
PASS-1

PASS-1
1. assign addresses to all statements in program
2. save the values(addresses) assigned to all labels for use in pass2
3. perform some processing of assembler directives

PASS-2

PASS-2
1. Assemble instructions
2. Generate data values defined by BYTE,WORD,etc
3. Perform processing of assembler directives not done during pass 1
4. Write the object program and the assembly listing

PRESENTED BY
HARSHA S (07GAEC3024)
ARUN ANAND DONNI (07GAEC3013)

You might also like