SlideShare a Scribd company logo
1 of 66
8086 Microprocessor
Architecture of 8086
• The architecture of 8086 includes
– Arithmetic Logic Unit (ALU)
– Flags
– General registers
– Instruction byte queue
– Segment registers
EU & BIU
• The 8086 CPU logic has been partitioned into
two functional units namely Bus Interface Unit
(BIU) and Execution Unit (EU)
• The major reason for this separation is to
increase the processing speed of the processor
• The BIU has to interact with memory and input
and output devices in fetching the instructions
and data required by the EU
• EU is responsible for executing the instructions
of the programs and to carry out the required
processing
EU & BIU
BUS INTERFACE UNIT (BU)
The BIU performs all bus operations for EU .
Fetching instructions
Responsible for executing all external bus
cycles.
Read operands and write result.
EXECUTION UNIT (EU)
Execution unit contains the complete
infrastructure required to execute an instruction
Architecture Diagram
Execution Unit
• The Execution Unit (EU) has
– Control unit
– Instruction decoder
– Arithmetic and Logical Unit (ALU)
– General registers
– Flag register
– Pointers
– Index registers
Execution Unit
• Control unit is responsible for the co-ordination
of all other units of the processor
• ALU performs various arithmetic and logical
operations over the data
• The instruction decoder translates the
instructions fetched from the memory into a
series of actions that are carried out by the EU
Execution Unit - Registers
• General registers are used for temporary storage
and manipulation of data and instructions
• Accumulator register consists of two 8-bit
registers AL and AH, which can be combined
together and used as a 16-bit register AX
• Accumulator can be used for I/O operations and
string manipulation
Execution Unit - Registers
• Base register consists of two 8-bit registers BL
and BH, which can be combined together and
used as a 16-bit register BX
• BX register usually contains a data pointer used
for based, based indexed or register indirect
addressing. Similar to 8085 H-L register.
• Count register consists of two 8-bit registers CL
and CH, which can be combined together and
used as a 16-bit register CX
• Count register can be used as a counter in string
manipulation and shift/rotate instructions
Execution Unit - Registers
• Data register consists of two 8-bit registers DL
and DH, which can be combined together and
used as a 16-bit register DX
• Data register can be used to hold 16 bit result in
16 in 16x16 multiplication.
Execution Unit - Registers
Pointer Registers
Stack pointer and BP are used to access data in
the stack segment.
SP is used as an offset from the current SS during
execution of instructions that involve the stack
segment in external memory.
BP is used in based addressing mode.
Execution Unit - Registers
Index Register
Source index register (SI) and Destination Index
Registers are used in indexed addressing.
Execution Unit - Registers
Execution Unit - Flags
Execution Unit - Flags
• Overflow Flag (OF) - set if the size of the exceeds the
capacity of the destination location.
• Direction Flag (DF) – It is used with string operations.
When set , it causing string instructions to auto –
decrement or to process strings from right to left.
• Interrupt-enable Flag (IF) - setting this bit enables
maskable interrupts . When IF = 0 , all maskable
interrupt are disable.
• Single-step Flag (Trap F) – put 8086 in the single step
mode.
Execution Unit - Flags
• Sign Flag (SF) - set if the most significant bit of the
result is one.
• Zero Flag (ZF) - set if the result is zero.
• Auxiliary carry Flag (AF) - set if there was a carry
from or borrow to bits 0-3 in the AL register.
• Parity Flag (PF) - set if parity (the number of "1" bits)
in the low-order byte of the result is even.
• Carry Flag (CF) - set if there was a carry from or
borrow to the most significant bit during last result
calculation
Execution Unit - Flags
Execution Unit - Pointers
• Stack Pointer (SP) is a 16-bit register pointing to
program stack
• Base Pointer (BP) is a 16-bit register pointing to data
in stack segment. BP register is usually used for based,
based indexed or register indirect addressing.
• Source Index (SI) is a 16-bit register. SI is used for
indexed, based indexed and register indirect
addressing, as well as a source data addresses in string
manipulation instructions.
• Destination Index (DI) is a 16-bit register. DI is used
for indexed, based indexed and register indirect
addressing, as well as a destination data addresses in
string manipulation instructions.
Execution Unit - Pointers
Bus Interface Unit
• The BIU has
– Instruction stream byte queue
– A set of segment registers
– Instruction pointer
BIU – Instruction Byte Queue
• 8086 instructions vary from 1 to 6 bytes
• Therefore fetch and execution are taking place
concurrently in order to improve the
performance of the microprocessor
• The BIU feeds the instruction stream to the
execution unit through a 6 byte prefetch queue
BIU – Instruction Byte Queue
• Execution and decoding of certain instructions do not
require the use of buses
• While such instructions are executed, the BIU fetches up to
six instruction bytes for the following instructions (the
subsequent instructions)
• The BIU store these prefetched bytes in a first-in-first out
register by name instruction byte queue
• When the EU is ready for its next instruction, it simply
reads the instruction byte(s) for the instruction from the
queue in BIU
Segment: Offset Notation
• The total addressable memory size is 1MB
• Most of the processor instructions use 16-bit
pointers the processor can effectively address
only 64 KB of memory
• To access memory outside of 64 KB the CPU
uses special segment registers to specify where
the code, stack and data 64 KB segments are
positioned within 1 MB of memory
Segment: Offset Notation
• A simple scheme would be to order the bytes in a serial
fashion and number them from 0 (or 1) to the end of
memory
• The scheme used in the 8086 is called segmentation
• Every address has two parts, a SEGMENT and an
OFFSET (Segmnet:Offset )
• The segment indicates the starting of a 64 kilobyte
portion of memory, in multiples of 16
• The offset indicates the position within the 64k portion
• Absolute address = (segment * 16) + offset
Segment Registers
• The memory of 8086 is divided into 4 segments
namely
– Code segment (program memory)
– Data segment (data memory)
– Stack memory (stack segment)
– Extra memory (extra segment)
Different Areas in Memory
• Program memory – Program can be located anywhere in
memory
• Data memory – The processor can access data in any one
out of 4 available segments
• Stack memory – A stack is a section of the memory set
aside to store addresses and data while a subprogram
executes
• Extra segment – This segment is also similar to data
memory where additional data may be stored and
maintained
Segment Registers
• Code Segment (CS) register is a 16-bit register containing
address of 64 KB segment with processor instructions
• The processor uses CS segment for all accesses to
instructions referenced by instruction pointer (IP) register
• Stack Segment (SS) register is a 16-bit register containing
address of 64KB segment with program stack
• By default, the processor assumes that all data referenced
by the stack pointer (SP) and base pointer (BP) registers is
located in the stack segment
Segment Registers
• Data Segment (DS) register is a 16-bit register containing
address of 64KB segment with program data
• By default, the processor assumes that all data referenced
by general registers (AX, BX, CX, DX) and index register
(SI, DI) is located in the data segment
• Extra Segment (ES) register is a 16-bit register containing
address of 64KB segment, usually with program data
• By default, the processor assumes that the DI register
references the ES segment in string manipulation
instructions
Segment Registers
If a location 109F0 of Code Segment is to be addressed to fetch
An instruction, the physical address will be calculated as follows
CSR = 010A
IP = F950
Effective Address = 109F0
Minimum-Mode and Maximum-
Mode System
Minimum-Mode and Maximum-
Mode System (cont.)
Signals common to both minimum and maximum mode
Minimum-Mode and Maximum-
Mode System (cont.)
Unique minimum-mode signals
Minimum-Mode and Maximum-
Mode System (cont.)
Unique maximum-mode signals
PIN DESCRIPTION -8086
Pin 1, 20
Ground
Pin 40
Vcc
Pin 19
CLK
Pin 17
INTR
Pin 18
NMI
AD15 –AD0 [ Pin 2- 16 &39]
The signal have dual function as in case of the 8085. They act as bus
during the first part of machine cycle and as data bus in the later part.
A19/S6 –A16/S3 [Pin 35- 38]
Contains address information in the first part and status bits in the
later part. The status bits, when decoded, indicates the type of
operations (eg. Memory access) being performed and the segment
register being used.
S4 S3 SEGMENT REGISTER
0 0 ES
0 1 SS
1 0 CS
1 1 DS
S5 = IF
S6 = 0
(ALWAYS)
BHE/S7 [pin 34]
MN/MX [pin 33]
High – Minimum Mode Operation
Low – Maximum Mode Operation
RD [pin 32]
Read or receive data from M or I/O device
TEST [pin 23]
Relate to wait instruction. The instruction puts the 8086 in
idle state which ends only when the TEST input goes low
READY [Pin 22]
Ready is a signal provided by the memory or I/O devices to the
microprocesssor.When READY = High, the microprocessor
proceeds to process the data in usual manner. When READY =
Low, the micropressor goes into wait state and waits for READY to
become High.
RESET [Pin 21]
Resets the Processor
……….PIN DESCRIPTION
DEN
Data bus Enable. This signal, when low indicates that the
microprocessor address/data bus is to be used as data bus.
HOLD
HLDA
Minimum Mode pin Functions
Pin 24 -31
INTA - Pin 24
ALE - Pin 25
Address Latch Enable. Since data and address are
multiplexed on a single bus. ALE is output high to identify
a valid address.
DEN -Pin 26
Data Bus Enable. This signal, when low indicates that the
microprocessor address/data bus is to be used as data bus.
DT/R - Pin 27
Data transmission/ Receive
M/ IO – Pin 28
WR – Pin 29
HOLD – Pin 30
HLDA - Pin 31
Addressing Modes
• Implied Addressing – The data value/data address is
implicitly associated with the instruction
• Register Addressing – The data is specified by referring
the register or the register pair in which the data is present
• Immediate Addressing – The data itself is provided in the
instruction
• Direct Addressing – The instruction operand specifies the
memory address where data is located
Addressing Modes
• Register indirect addressing – The instruction specifies a
register containing an address, where data is located
• Based - 8-bit or 16-bit instruction operand is added to the
contents of a base register (BX or BP), the resulting value
is a pointer to location where data resides
• Indexed - 8-bit or 16-bit instruction operand is added to the
contents of an index register (SI or DI), the resulting value
is a pointer to location where data resides
Addressing Modes
• Based Indexed - the contents of a base register (BX or BP)
is added to the contents of an index register (SI or DI), the
resulting value is a pointer to location where data resides
• Based Indexed with displacement - 8-bit or 16-bit
instruction operand is added to the contents of a base
register (BX or BP) and index register (SI or DI), the
resulting value is a pointer to location where data resides
Data Transfer Instructions
Data Transfer Instructions
Arithmetic Instructions
Arithmetic Instructions
Number Representation
Logical Instructions
String Instructions
Program Transfer Instructions
Program Transfer Instructions
Processor Control Instructions
Assembler Directives
• Assembler directives give instruction to the assembler
where as other instructions discussed in the above section
give instruction to the 8086 microprocessor
• Assembler directives are specific for a particular assembler
• However all the popular assemblers like the Intel 8086
macro assembler, the turbo assembler and the IBM macro
assembler use common assembler directives
Important Directives
• The ASSUME directive tell the assembler the name of the logical
segment it should use for a specified segment
• The DB directive is used to declare a byte-type variable or to set aside
one or more storage locations of type byte in memory (Define Byte)
• The DD directive is used to declare a variable of type doubleword or to
reserve memory locations which can be accessed as type doubleword
(Define Doubleword)
• The DQ directive is used to tell the assembler to declare a variable 4
words in length or to reverse 4 words of storage in memory (Define
Quadword)
Important Directives
• The ENDS directive is used with the name of a
segment to indicate the end of that logical
segment
• The EQU is used to give a name to some value
or symbol
Assembly Language Program
• Writing assembly language programs for 8086 is slightly
different from that of writing assembly language programs
for 8085
• In addition to the instructions that are meant for solving the
problem, some additional instructions are required to
complete the programs
• The purpose of these additional programs is to initialize
various parts of the system, such as segment registers, flags
and programmable port devices
• Some of the instructions are to handle the stack of the 8086
based system
Assembly Language Program
• Another purpose of these additional instructions is to
handle the programmable peripheral devices such as ports,
timers and controllers
• The programmable peripheral interfaces should be
assigned suitable control words to make them to function
in the way as we expect
• The best way to approach the initialization task is to make
a checklist of all the registers, programmable devices and
flags in the system we are working on
Assembly Language Program
• An 8086 assembly language program has five
columns namely
– Address
– Data or code
– Labels
– Mmnemonics
– Operands
– Comments
Assembly Language Program
• The address column is used for the address or
the offset of a code byte or a data byte
• The actual code bytes or data bytes are put in
the data or code column
• A label is a name which represents an address
referred to in a jump or call instruction
• Labels are put in the labels column
Assembly Language Program
• The operands column contains the registers,
memory locations or data acted upon by the
instructions
• A comments column gives space to describe the
function of the instruction for future reference

More Related Content

What's hot

80486 microprocessor
80486 microprocessor80486 microprocessor
80486 microprocessorMihika Shah
 
8085-microprocessor
8085-microprocessor8085-microprocessor
8085-microprocessorjhcid
 
Programmers model of 8086
Programmers model of 8086Programmers model of 8086
Programmers model of 8086KunalPatel260
 
8086 pin details
8086 pin details8086 pin details
8086 pin detailsAJAL A J
 
Architecture of 8051
Architecture of 8051Architecture of 8051
Architecture of 8051hello_priti
 
LPC 2148 ARM MICROCONTROLLER
LPC 2148 ARM MICROCONTROLLERLPC 2148 ARM MICROCONTROLLER
LPC 2148 ARM MICROCONTROLLERsravannunna24
 
PIC Microcontrollers.ppt
PIC Microcontrollers.pptPIC Microcontrollers.ppt
PIC Microcontrollers.pptDr.YNM
 
ARM7-ARCHITECTURE
ARM7-ARCHITECTURE ARM7-ARCHITECTURE
ARM7-ARCHITECTURE Dr.YNM
 
Microcontoller and Embedded System
Microcontoller and Embedded SystemMicrocontoller and Embedded System
Microcontoller and Embedded SystemKaran Thakkar
 
Difference between 8085 and 8086 microprocessor Architecture
Difference between 8085 and 8086 microprocessor ArchitectureDifference between 8085 and 8086 microprocessor Architecture
Difference between 8085 and 8086 microprocessor ArchitectureVarunGautam40
 
DMA and DMA controller
DMA and DMA controllerDMA and DMA controller
DMA and DMA controllernishant upadhyay
 
Instruction set of 8086
Instruction set of 8086Instruction set of 8086
Instruction set of 80869840596838
 
8051 memory
8051 memory8051 memory
8051 memoryMayank Garg
 
Interfacing memory with 8086 microprocessor
Interfacing memory with 8086 microprocessorInterfacing memory with 8086 microprocessor
Interfacing memory with 8086 microprocessorVikas Gupta
 
Types Of Buses
Types Of BusesTypes Of Buses
Types Of BusesAkhil Ahuja
 
Memory organization in computer architecture
Memory organization in computer architectureMemory organization in computer architecture
Memory organization in computer architectureFaisal Hussain
 
Microprocessor
MicroprocessorMicroprocessor
Microprocessoraaina_katyal
 

What's hot (20)

80486 microprocessor
80486 microprocessor80486 microprocessor
80486 microprocessor
 
8085-microprocessor
8085-microprocessor8085-microprocessor
8085-microprocessor
 
Programmers model of 8086
Programmers model of 8086Programmers model of 8086
Programmers model of 8086
 
8086 pin details
8086 pin details8086 pin details
8086 pin details
 
Architecture of 8051
Architecture of 8051Architecture of 8051
Architecture of 8051
 
LPC 2148 ARM MICROCONTROLLER
LPC 2148 ARM MICROCONTROLLERLPC 2148 ARM MICROCONTROLLER
LPC 2148 ARM MICROCONTROLLER
 
PIC Microcontrollers.ppt
PIC Microcontrollers.pptPIC Microcontrollers.ppt
PIC Microcontrollers.ppt
 
8086
80868086
8086
 
ARM7-ARCHITECTURE
ARM7-ARCHITECTURE ARM7-ARCHITECTURE
ARM7-ARCHITECTURE
 
Microcontoller and Embedded System
Microcontoller and Embedded SystemMicrocontoller and Embedded System
Microcontoller and Embedded System
 
8259 a
8259 a8259 a
8259 a
 
Difference between 8085 and 8086 microprocessor Architecture
Difference between 8085 and 8086 microprocessor ArchitectureDifference between 8085 and 8086 microprocessor Architecture
Difference between 8085 and 8086 microprocessor Architecture
 
DMA and DMA controller
DMA and DMA controllerDMA and DMA controller
DMA and DMA controller
 
Instruction set of 8086
Instruction set of 8086Instruction set of 8086
Instruction set of 8086
 
MICROCONTROLLER 8051
MICROCONTROLLER 8051MICROCONTROLLER 8051
MICROCONTROLLER 8051
 
8051 memory
8051 memory8051 memory
8051 memory
 
Interfacing memory with 8086 microprocessor
Interfacing memory with 8086 microprocessorInterfacing memory with 8086 microprocessor
Interfacing memory with 8086 microprocessor
 
Types Of Buses
Types Of BusesTypes Of Buses
Types Of Buses
 
Memory organization in computer architecture
Memory organization in computer architectureMemory organization in computer architecture
Memory organization in computer architecture
 
Microprocessor
MicroprocessorMicroprocessor
Microprocessor
 

Viewers also liked

8086 class notes-Y.N.M
8086 class notes-Y.N.M8086 class notes-Y.N.M
8086 class notes-Y.N.MDr.YNM
 
Computer organiztion5
Computer organiztion5Computer organiztion5
Computer organiztion5Umang Gupta
 
Basic computer organisation design
Basic computer organisation designBasic computer organisation design
Basic computer organisation designSanjeev Patel
 
8086 microprocessor-architecture
8086 microprocessor-architecture8086 microprocessor-architecture
8086 microprocessor-architectureprasadpawaskar
 
Basic Computer Organization and Design
Basic Computer Organization and DesignBasic Computer Organization and Design
Basic Computer Organization and Designmekind
 
Computer Architecture and organization
Computer Architecture and organizationComputer Architecture and organization
Computer Architecture and organizationBadrinath Kadam
 

Viewers also liked (7)

8086 class notes-Y.N.M
8086 class notes-Y.N.M8086 class notes-Y.N.M
8086 class notes-Y.N.M
 
Computer organiztion5
Computer organiztion5Computer organiztion5
Computer organiztion5
 
Basic computer organisation design
Basic computer organisation designBasic computer organisation design
Basic computer organisation design
 
8086 microprocessor-architecture
8086 microprocessor-architecture8086 microprocessor-architecture
8086 microprocessor-architecture
 
Basic Computer Organization and Design
Basic Computer Organization and DesignBasic Computer Organization and Design
Basic Computer Organization and Design
 
Computer Architecture and organization
Computer Architecture and organizationComputer Architecture and organization
Computer Architecture and organization
 
Ntroduction to computer architecture and organization
Ntroduction to computer architecture and organizationNtroduction to computer architecture and organization
Ntroduction to computer architecture and organization
 

Similar to The Intel 8086 microprocessor

8086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp018086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp01jemimajerome
 
intel 8086 introduction
intel 8086 introductionintel 8086 introduction
intel 8086 introductionHomoud Alsohaibi
 
8086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp018086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp01destaw belay
 
8086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp018086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp01Siva Raman
 
INTEL 8086 MICROPROCESSOR
INTEL 8086 MICROPROCESSORINTEL 8086 MICROPROCESSOR
INTEL 8086 MICROPROCESSORSagar Kuntumal
 
8086-microprocessor-architecture.ppt
8086-microprocessor-architecture.ppt8086-microprocessor-architecture.ppt
8086-microprocessor-architecture.pptMadhan7771
 
26677766 8086-microprocessor-architecture-110905125037-phpapp02
26677766 8086-microprocessor-architecture-110905125037-phpapp0226677766 8086-microprocessor-architecture-110905125037-phpapp02
26677766 8086-microprocessor-architecture-110905125037-phpapp02Avijeet Negel
 
Intel 8086
Intel 8086 Intel 8086
Intel 8086 Manoj VNV
 
8086 archi notes final
8086 archi notes final8086 archi notes final
8086 archi notes finalHarshitParkar6677
 
8086 archi notes final
8086 archi notes final8086 archi notes final
8086 archi notes finalHarshitParkar6677
 
8086 Architecture ppt.pdf
8086 Architecture ppt.pdf8086 Architecture ppt.pdf
8086 Architecture ppt.pdfUmamaheswariV4
 
8086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp028086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp02raone1989
 
8086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp028086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp02raone1989
 
8086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp028086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp02Murad Mondol
 
8086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp028086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp02raone1989
 
8086 architecture By Er. Swapnil Kaware
8086 architecture By Er. Swapnil Kaware8086 architecture By Er. Swapnil Kaware
8086 architecture By Er. Swapnil KawareProf. Swapnil V. Kaware
 

Similar to The Intel 8086 microprocessor (20)

Amp
AmpAmp
Amp
 
8086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp018086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp01
 
intel 8086 introduction
intel 8086 introductionintel 8086 introduction
intel 8086 introduction
 
8086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp018086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp01
 
8086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp018086 microprocessor-architecture-120207111857-phpapp01
8086 microprocessor-architecture-120207111857-phpapp01
 
INTEL 8086 MICROPROCESSOR
INTEL 8086 MICROPROCESSORINTEL 8086 MICROPROCESSOR
INTEL 8086 MICROPROCESSOR
 
8086-microprocessor-architecture.ppt
8086-microprocessor-architecture.ppt8086-microprocessor-architecture.ppt
8086-microprocessor-architecture.ppt
 
Microprocessors
MicroprocessorsMicroprocessors
Microprocessors
 
26677766 8086-microprocessor-architecture-110905125037-phpapp02
26677766 8086-microprocessor-architecture-110905125037-phpapp0226677766 8086-microprocessor-architecture-110905125037-phpapp02
26677766 8086-microprocessor-architecture-110905125037-phpapp02
 
Intel 8086
Intel 8086 Intel 8086
Intel 8086
 
8086 archi notes final
8086 archi notes final8086 archi notes final
8086 archi notes final
 
8086 archi notes final
8086 archi notes final8086 archi notes final
8086 archi notes final
 
8086 architecture
8086 architecture8086 architecture
8086 architecture
 
8086 Architecture ppt.pdf
8086 Architecture ppt.pdf8086 Architecture ppt.pdf
8086 Architecture ppt.pdf
 
8086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp028086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp02
 
8086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp028086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp02
 
8086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp028086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp02
 
8086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp028086microprocessor 130821100244-phpapp02
8086microprocessor 130821100244-phpapp02
 
8086 architecture By Er. Swapnil Kaware
8086 architecture By Er. Swapnil Kaware8086 architecture By Er. Swapnil Kaware
8086 architecture By Er. Swapnil Kaware
 
Mpmc
MpmcMpmc
Mpmc
 

More from George Thomas

FULL ADDER (VIDEO LINK IN DESCRIPTION)
FULL ADDER (VIDEO  LINK IN DESCRIPTION)FULL ADDER (VIDEO  LINK IN DESCRIPTION)
FULL ADDER (VIDEO LINK IN DESCRIPTION)George Thomas
 
INTRODUCTION TO DIGITAL ELECTRONICS & HALF ADDER (LINK TO VIDEO IN DESCRIPTI...
INTRODUCTION TO DIGITAL ELECTRONICS & HALF ADDER (LINK TO  VIDEO IN DESCRIPTI...INTRODUCTION TO DIGITAL ELECTRONICS & HALF ADDER (LINK TO  VIDEO IN DESCRIPTI...
INTRODUCTION TO DIGITAL ELECTRONICS & HALF ADDER (LINK TO VIDEO IN DESCRIPTI...George Thomas
 
MICROPROCESSOR INPUT OUTPUT OPERATIONS
MICROPROCESSOR INPUT OUTPUT OPERATIONSMICROPROCESSOR INPUT OUTPUT OPERATIONS
MICROPROCESSOR INPUT OUTPUT OPERATIONSGeorge Thomas
 
Renewable and Non- renewable energy Sources
Renewable and Non- renewable energy SourcesRenewable and Non- renewable energy Sources
Renewable and Non- renewable energy SourcesGeorge Thomas
 
Renewable energy - Wind energy
Renewable energy - Wind energyRenewable energy - Wind energy
Renewable energy - Wind energyGeorge Thomas
 

More from George Thomas (7)

FULL ADDER (VIDEO LINK IN DESCRIPTION)
FULL ADDER (VIDEO  LINK IN DESCRIPTION)FULL ADDER (VIDEO  LINK IN DESCRIPTION)
FULL ADDER (VIDEO LINK IN DESCRIPTION)
 
INTRODUCTION TO DIGITAL ELECTRONICS & HALF ADDER (LINK TO VIDEO IN DESCRIPTI...
INTRODUCTION TO DIGITAL ELECTRONICS & HALF ADDER (LINK TO  VIDEO IN DESCRIPTI...INTRODUCTION TO DIGITAL ELECTRONICS & HALF ADDER (LINK TO  VIDEO IN DESCRIPTI...
INTRODUCTION TO DIGITAL ELECTRONICS & HALF ADDER (LINK TO VIDEO IN DESCRIPTI...
 
Cache memory
Cache memoryCache memory
Cache memory
 
MICROPROCESSOR INPUT OUTPUT OPERATIONS
MICROPROCESSOR INPUT OUTPUT OPERATIONSMICROPROCESSOR INPUT OUTPUT OPERATIONS
MICROPROCESSOR INPUT OUTPUT OPERATIONS
 
Renewable and Non- renewable energy Sources
Renewable and Non- renewable energy SourcesRenewable and Non- renewable energy Sources
Renewable and Non- renewable energy Sources
 
Tidal energy
Tidal energyTidal energy
Tidal energy
 
Renewable energy - Wind energy
Renewable energy - Wind energyRenewable energy - Wind energy
Renewable energy - Wind energy
 

Recently uploaded

1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdfQucHHunhnh
 
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...Pooja Nehwal
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3JemimahLaneBuaron
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...fonyou31
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxShobhayan Kirtania
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesFatimaKhan178732
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajanpragatimahajan3
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13Steve Thomason
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingTechSoup
 

Recently uploaded (20)

1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptx
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and Actinides
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajan
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 

The Intel 8086 microprocessor

  • 2. Architecture of 8086 • The architecture of 8086 includes – Arithmetic Logic Unit (ALU) – Flags – General registers – Instruction byte queue – Segment registers
  • 3. EU & BIU • The 8086 CPU logic has been partitioned into two functional units namely Bus Interface Unit (BIU) and Execution Unit (EU) • The major reason for this separation is to increase the processing speed of the processor • The BIU has to interact with memory and input and output devices in fetching the instructions and data required by the EU • EU is responsible for executing the instructions of the programs and to carry out the required processing
  • 5. BUS INTERFACE UNIT (BU) The BIU performs all bus operations for EU . Fetching instructions Responsible for executing all external bus cycles. Read operands and write result. EXECUTION UNIT (EU) Execution unit contains the complete infrastructure required to execute an instruction
  • 7. Execution Unit • The Execution Unit (EU) has – Control unit – Instruction decoder – Arithmetic and Logical Unit (ALU) – General registers – Flag register – Pointers – Index registers
  • 8. Execution Unit • Control unit is responsible for the co-ordination of all other units of the processor • ALU performs various arithmetic and logical operations over the data • The instruction decoder translates the instructions fetched from the memory into a series of actions that are carried out by the EU
  • 9. Execution Unit - Registers • General registers are used for temporary storage and manipulation of data and instructions • Accumulator register consists of two 8-bit registers AL and AH, which can be combined together and used as a 16-bit register AX • Accumulator can be used for I/O operations and string manipulation
  • 10. Execution Unit - Registers • Base register consists of two 8-bit registers BL and BH, which can be combined together and used as a 16-bit register BX • BX register usually contains a data pointer used for based, based indexed or register indirect addressing. Similar to 8085 H-L register. • Count register consists of two 8-bit registers CL and CH, which can be combined together and used as a 16-bit register CX • Count register can be used as a counter in string manipulation and shift/rotate instructions
  • 11. Execution Unit - Registers • Data register consists of two 8-bit registers DL and DH, which can be combined together and used as a 16-bit register DX • Data register can be used to hold 16 bit result in 16 in 16x16 multiplication.
  • 12. Execution Unit - Registers Pointer Registers Stack pointer and BP are used to access data in the stack segment. SP is used as an offset from the current SS during execution of instructions that involve the stack segment in external memory. BP is used in based addressing mode.
  • 13. Execution Unit - Registers Index Register Source index register (SI) and Destination Index Registers are used in indexed addressing.
  • 14. Execution Unit - Registers
  • 16. Execution Unit - Flags • Overflow Flag (OF) - set if the size of the exceeds the capacity of the destination location. • Direction Flag (DF) – It is used with string operations. When set , it causing string instructions to auto – decrement or to process strings from right to left. • Interrupt-enable Flag (IF) - setting this bit enables maskable interrupts . When IF = 0 , all maskable interrupt are disable. • Single-step Flag (Trap F) – put 8086 in the single step mode.
  • 17. Execution Unit - Flags • Sign Flag (SF) - set if the most significant bit of the result is one. • Zero Flag (ZF) - set if the result is zero. • Auxiliary carry Flag (AF) - set if there was a carry from or borrow to bits 0-3 in the AL register. • Parity Flag (PF) - set if parity (the number of "1" bits) in the low-order byte of the result is even. • Carry Flag (CF) - set if there was a carry from or borrow to the most significant bit during last result calculation
  • 19. Execution Unit - Pointers • Stack Pointer (SP) is a 16-bit register pointing to program stack • Base Pointer (BP) is a 16-bit register pointing to data in stack segment. BP register is usually used for based, based indexed or register indirect addressing. • Source Index (SI) is a 16-bit register. SI is used for indexed, based indexed and register indirect addressing, as well as a source data addresses in string manipulation instructions. • Destination Index (DI) is a 16-bit register. DI is used for indexed, based indexed and register indirect addressing, as well as a destination data addresses in string manipulation instructions.
  • 20. Execution Unit - Pointers
  • 21. Bus Interface Unit • The BIU has – Instruction stream byte queue – A set of segment registers – Instruction pointer
  • 22. BIU – Instruction Byte Queue • 8086 instructions vary from 1 to 6 bytes • Therefore fetch and execution are taking place concurrently in order to improve the performance of the microprocessor • The BIU feeds the instruction stream to the execution unit through a 6 byte prefetch queue
  • 23. BIU – Instruction Byte Queue • Execution and decoding of certain instructions do not require the use of buses • While such instructions are executed, the BIU fetches up to six instruction bytes for the following instructions (the subsequent instructions) • The BIU store these prefetched bytes in a first-in-first out register by name instruction byte queue • When the EU is ready for its next instruction, it simply reads the instruction byte(s) for the instruction from the queue in BIU
  • 24. Segment: Offset Notation • The total addressable memory size is 1MB • Most of the processor instructions use 16-bit pointers the processor can effectively address only 64 KB of memory • To access memory outside of 64 KB the CPU uses special segment registers to specify where the code, stack and data 64 KB segments are positioned within 1 MB of memory
  • 25. Segment: Offset Notation • A simple scheme would be to order the bytes in a serial fashion and number them from 0 (or 1) to the end of memory • The scheme used in the 8086 is called segmentation • Every address has two parts, a SEGMENT and an OFFSET (Segmnet:Offset ) • The segment indicates the starting of a 64 kilobyte portion of memory, in multiples of 16 • The offset indicates the position within the 64k portion • Absolute address = (segment * 16) + offset
  • 26. Segment Registers • The memory of 8086 is divided into 4 segments namely – Code segment (program memory) – Data segment (data memory) – Stack memory (stack segment) – Extra memory (extra segment)
  • 27. Different Areas in Memory • Program memory – Program can be located anywhere in memory • Data memory – The processor can access data in any one out of 4 available segments • Stack memory – A stack is a section of the memory set aside to store addresses and data while a subprogram executes • Extra segment – This segment is also similar to data memory where additional data may be stored and maintained
  • 28. Segment Registers • Code Segment (CS) register is a 16-bit register containing address of 64 KB segment with processor instructions • The processor uses CS segment for all accesses to instructions referenced by instruction pointer (IP) register • Stack Segment (SS) register is a 16-bit register containing address of 64KB segment with program stack • By default, the processor assumes that all data referenced by the stack pointer (SP) and base pointer (BP) registers is located in the stack segment
  • 29. Segment Registers • Data Segment (DS) register is a 16-bit register containing address of 64KB segment with program data • By default, the processor assumes that all data referenced by general registers (AX, BX, CX, DX) and index register (SI, DI) is located in the data segment • Extra Segment (ES) register is a 16-bit register containing address of 64KB segment, usually with program data • By default, the processor assumes that the DI register references the ES segment in string manipulation instructions
  • 30. Segment Registers If a location 109F0 of Code Segment is to be addressed to fetch An instruction, the physical address will be calculated as follows CSR = 010A IP = F950 Effective Address = 109F0
  • 31.
  • 32.
  • 33.
  • 34.
  • 36. Minimum-Mode and Maximum- Mode System (cont.) Signals common to both minimum and maximum mode
  • 37. Minimum-Mode and Maximum- Mode System (cont.) Unique minimum-mode signals
  • 38. Minimum-Mode and Maximum- Mode System (cont.) Unique maximum-mode signals
  • 39. PIN DESCRIPTION -8086 Pin 1, 20 Ground Pin 40 Vcc Pin 19 CLK Pin 17 INTR Pin 18 NMI
  • 40. AD15 –AD0 [ Pin 2- 16 &39] The signal have dual function as in case of the 8085. They act as bus during the first part of machine cycle and as data bus in the later part. A19/S6 –A16/S3 [Pin 35- 38] Contains address information in the first part and status bits in the later part. The status bits, when decoded, indicates the type of operations (eg. Memory access) being performed and the segment register being used. S4 S3 SEGMENT REGISTER 0 0 ES 0 1 SS 1 0 CS 1 1 DS S5 = IF S6 = 0 (ALWAYS)
  • 41. BHE/S7 [pin 34] MN/MX [pin 33] High – Minimum Mode Operation Low – Maximum Mode Operation RD [pin 32] Read or receive data from M or I/O device TEST [pin 23] Relate to wait instruction. The instruction puts the 8086 in idle state which ends only when the TEST input goes low
  • 42. READY [Pin 22] Ready is a signal provided by the memory or I/O devices to the microprocesssor.When READY = High, the microprocessor proceeds to process the data in usual manner. When READY = Low, the micropressor goes into wait state and waits for READY to become High. RESET [Pin 21] Resets the Processor
  • 43. ……….PIN DESCRIPTION DEN Data bus Enable. This signal, when low indicates that the microprocessor address/data bus is to be used as data bus. HOLD HLDA
  • 44. Minimum Mode pin Functions Pin 24 -31 INTA - Pin 24 ALE - Pin 25 Address Latch Enable. Since data and address are multiplexed on a single bus. ALE is output high to identify a valid address. DEN -Pin 26 Data Bus Enable. This signal, when low indicates that the microprocessor address/data bus is to be used as data bus.
  • 45. DT/R - Pin 27 Data transmission/ Receive M/ IO – Pin 28 WR – Pin 29 HOLD – Pin 30 HLDA - Pin 31
  • 46. Addressing Modes • Implied Addressing – The data value/data address is implicitly associated with the instruction • Register Addressing – The data is specified by referring the register or the register pair in which the data is present • Immediate Addressing – The data itself is provided in the instruction • Direct Addressing – The instruction operand specifies the memory address where data is located
  • 47. Addressing Modes • Register indirect addressing – The instruction specifies a register containing an address, where data is located • Based - 8-bit or 16-bit instruction operand is added to the contents of a base register (BX or BP), the resulting value is a pointer to location where data resides • Indexed - 8-bit or 16-bit instruction operand is added to the contents of an index register (SI or DI), the resulting value is a pointer to location where data resides
  • 48. Addressing Modes • Based Indexed - the contents of a base register (BX or BP) is added to the contents of an index register (SI or DI), the resulting value is a pointer to location where data resides • Based Indexed with displacement - 8-bit or 16-bit instruction operand is added to the contents of a base register (BX or BP) and index register (SI or DI), the resulting value is a pointer to location where data resides
  • 59. Assembler Directives • Assembler directives give instruction to the assembler where as other instructions discussed in the above section give instruction to the 8086 microprocessor • Assembler directives are specific for a particular assembler • However all the popular assemblers like the Intel 8086 macro assembler, the turbo assembler and the IBM macro assembler use common assembler directives
  • 60. Important Directives • The ASSUME directive tell the assembler the name of the logical segment it should use for a specified segment • The DB directive is used to declare a byte-type variable or to set aside one or more storage locations of type byte in memory (Define Byte) • The DD directive is used to declare a variable of type doubleword or to reserve memory locations which can be accessed as type doubleword (Define Doubleword) • The DQ directive is used to tell the assembler to declare a variable 4 words in length or to reverse 4 words of storage in memory (Define Quadword)
  • 61. Important Directives • The ENDS directive is used with the name of a segment to indicate the end of that logical segment • The EQU is used to give a name to some value or symbol
  • 62. Assembly Language Program • Writing assembly language programs for 8086 is slightly different from that of writing assembly language programs for 8085 • In addition to the instructions that are meant for solving the problem, some additional instructions are required to complete the programs • The purpose of these additional programs is to initialize various parts of the system, such as segment registers, flags and programmable port devices • Some of the instructions are to handle the stack of the 8086 based system
  • 63. Assembly Language Program • Another purpose of these additional instructions is to handle the programmable peripheral devices such as ports, timers and controllers • The programmable peripheral interfaces should be assigned suitable control words to make them to function in the way as we expect • The best way to approach the initialization task is to make a checklist of all the registers, programmable devices and flags in the system we are working on
  • 64. Assembly Language Program • An 8086 assembly language program has five columns namely – Address – Data or code – Labels – Mmnemonics – Operands – Comments
  • 65. Assembly Language Program • The address column is used for the address or the offset of a code byte or a data byte • The actual code bytes or data bytes are put in the data or code column • A label is a name which represents an address referred to in a jump or call instruction • Labels are put in the labels column
  • 66. Assembly Language Program • The operands column contains the registers, memory locations or data acted upon by the instructions • A comments column gives space to describe the function of the instruction for future reference