SlideShare ist ein Scribd-Unternehmen logo
1 von 28
CHAPTER 1
The
Architecture
of
8086
INTRODUCTION
 Need to know the learning of x86 family of
microprocessors
 Understand the architecture of the 8086
 8086 is a processor catering to 16-bit data (D0 to D15) and
having a 20-bit address (A0 to A19)
 8086 is a 16-bit processor internally & externally
 means its data bus width as well as the bit size of its
internal data registers is 16
 it can even access external source 16 bits
 it also has the capacity to access and work on 8-bit data.
BLOCK DIAGRAM
1.3 BUS INTERFACE UNIT
This unit is responsible for
 Address Calculations
 pre-fetching instructions for the queue and sequencing
instructions one by one.
1.3.1 INSTRUCTION QUEUE
 Instructions are found in memory
 From there it has to be fetched & decoded
whenever needed for execution.
 in 8086, the queue that fetches instructions ahead
of execution time & places them in a 6-byte FIFO
queue
 This pre-fetching is done when buses are free
 Advantage of this is when a particular instruction
needs to be executed, it’s a good chance of
finding in a queue rather than from memory
1.3.2 MEMORY SEGMENTATION
 8086 has a 20-Bit address bus ( As we have not seen any
20- Bit regsters so far)
 general-purpose registers are used as 16 or 8 bit registers
 all address registers also are16-bit
 Segmentation will be used to take care of this situation
 A segment is just an area in memory
 so total memory size can be considered to be divided into
segments of various sizes.
 Idea of dividing memory is called Segmentation
 In memory data is stored as bytes
 Each byte has a specific address
 with 20 address lines, the memory that can be addressed is
220 bytes (1,048,576 Bytes or 1 MB)
 8086 can access a physical memory with address ranging
from 00000 to FFFFFH.
 20-bit physical address is to be placed on the address
bus to access any location in memory.
 Memory as a whole is considered to have four different
types of segments:
1. data segment
2. code segment
3. stack segment
4. extra segment
 Idea of segmentation is to keep data & code separately
 code segment contains code only
 data is stored in the data segment
 extra segment is just another type of data segment
used in special way
 stack segment is an area in memory which functions
and is accessed from the other three segments
1.3.2.1 SEGMENT REGISTERS
 Each segments is addressed by an address stored in
corresponding segment registers
 registers are all 16-bit size
 each register stores base address of the corresponding
segment
 Base address is the starting address of a segment
 since segment registers cannot store 20 bits, they store
only the upper 16 bits
 least significant nibble is implied to zero
 How 20 bit physical address obtained if there are only 16
bit registers?
 20 bit address of a byte is called Physical address
 it is specified as Logical address in the form of two16-bit
numbers in the format base address : offset
 Example: Calculation of a physical address from
the logical address for a data segment
 Consider that a data byte is stored in a data segment, whose
base address is 22220H
 Then data segment register will contain the number 2222H.
 The data at any location within this segment is referred to an
offset with respect to the base address.
 If a data at a location has a logical address specified as
2222H:0016H
 Then the number 0016H is the offset or displacement w.r.t the
base address
 For physical address calculation, the BIU appends the
segment register content with four binary zeros on the right.
 Thus physical address is calculated as:
22220H
+ 0016H
22236H
 Similar in case for the other segments
 offsets are limited to 16Bits
 means that the maximum size possible for a segment is
only 216 or 64KB
 Hence every memory reference by the 8086 will use one of
the segment registers (i.e DS, ES, SS, or CS)
 combined to form an offset to determine the physical
address being accessed.
 Fig that highlights a data byte that has the logical address
of the form DS: Offset.
 Code segment is the area of memory where code alone is
stored.
 offsets in the code segment are referenced by Instruction
Pointer. ( a 16-Bit register)
 IP sequences the instructions and points to the next
instruction to be executed.
 If an instruction byte has to be fetched from memory, the
bus interface unit performs the address calculation using
the contents of CS registers & the IP
 This 20-bit address is then placed on the address bus and
the instruction byte is fetched.
 Hence the logical address for an instruction is of the form
CS:IP
1.3.2.2 CODE SEGMENT & INSTRUCTION POINTER
 Stack is an area in memory and data is generally pushed &
popped out of the stack
 8086 also uses LIFO stack
 There is a 16-Bit register called Stack Pointer, which points
to the top of the stack
 Stack segment is like other segment
 upper 16 bits of its base address is available in the SS
register
 A stack address of the form 4466H: 0122H means that the
SS register contains 4466H
 stack pointer contains the number 0122H
 So the physical address of the top of the stack is
44660H + 0122H = 44782H
1.3.2.3 STACK SEGMENT AND STACK POINTER
 Both segments store data
 Extra segment register to store the upper 16 bits of
the base address of the extra segment.
 offset within the data segment is also termed as ‘
effective address’
 effective address calculations depends on effect of
mode of answering.
 Table shows the segment registers and the
corresponding registers that can be used for offsets
1.3.2.4 DATA SEGMENT AND EXTRA SEGMENT
ADVANTAGES OF SEGMENTATION
 All address registers are only 16 bit long, though the
physical address is 20 bits
 All address are re-locatable
 Memory organization in little-endian format
 In order for computations in assembly language, we need
an Opcode & Operands
 Opcode stands for Operation Code
 Opcode specifies the operation to be performed
 Opcodes operate on data, which are called the Operands
 The way in which operands are specified in an assembly
language is called its “Addressing Mode”.
 Operands can be in registers, in memory or may be in the
instruction itself.
 in case of two operands, one of them can be in memory,
but the other will have to be placed in a register
 data types should match, that is, source, and destination
should both be either bytes or words
1.4 ADDRESSING MODES
 Here both source and destination are registers. No memory
access are involved.
MOV AL, AH ; copy the content of AH to AL
MOV CH, BL ; copy the content of BL to CH
MOV SI, BX ; copy the content of BX to SI
MOV ES,AX ; copy the content of AX to ES
Note that the first two are byte operations, while the other
two are word operations.
MOV AX, BL ; gives error as AX is 16 bit & BL is 8 bit
MOV BL, AX ; gives an error for the same reasons
1.4.1 REGISTER ADDRESSING
 Here source will be a constant data
MOV AL, 45H ; copy 45H to AL
MOV BX, 34E3H ; move the hex number 34E3H to BX
MOV CL.’Q’ ; move the ASCII value of Q to CL
MOV PRICE,40 ; move the hex num 40 to the memory
location with the label PRICE
MOV NUMS, 0FC6H ; move the hex number 0FC6H to
the memory location NUMS
 Segment registers are not allowed to use this mode of
addressing
MOV DS,2300H ; gives an error as DS is a segment
register
1.4.2 IMMEDIATE ADDRESSING
 Here, either the source or the destination will be a memory address
MOV AX, [2345H] ; move word location 2345H to AX
MOV [1089H], AL ; the byte in AL is moved to location 1086H
 MOV AX , PRICE
 MOV COST,AL
PRICE and COST are labels for memory addresses
1.4.3 DIRECT ADDRESSING
1.4.4REGISTER INDIRECT ADDRESSING
 In this mode , the address of the data is held in a register
 Effective address
 EA=EA= { [BX] / [DI] /[SI]}
 MOV AL,[BX] ; move into AL the content of the location
whose address is in BX
 MOV [SI], CL ;move the content of CL to the address
pointed by SI
 MOV [DI],AX ; move the content of AX to the address
pointed by DI
 In third instruction, AX contains two bytes, so the content
of AL will be moved to the address pointed by DI.
 The content of AH will be moved to the address [D+1]
 Show the location of data in memory, after the
execution of each of these instructions , if the
content of registers are as given
DS= 1112H , AX= EE78H and BX=3400H
MOV [0422H], AL
MOV [0424H],AX
MOV [BX] ,AX
EXAMPLE
1.4.5 REGISTER RELATIVE ADDRESSING
 In relative addressing mode , a number or
displacement is part of the effective address
 EA ={[BX] /[DI] /[SI] /[BP]} + 8 bit or 16 bit displacement
 The displacement can be a 16 bit signed/unsigned
number or an 8 bit sign extended number.
 MOV CL ,10[BX] ; move the content of the address
specified by adding the content of BX and 10
 Like
 MOV CL, [BX+10]
 MOV CL, [BX]+10
1.4.6 BASED INDEXED MODE
 In this mode ,an index register and a base register
together carry the effective address .
 The content of these two registers are added and called
the effective address.
 MOV AL,[BX][SI] ; move the content of the effective
address pointed by [BX] and [SI] into AL
 MOV [BX][DI],CX ;move the content of CX to the effective
address pointed by [BX] and [SI]
1.4.7 RELATIVE BASED INDEXED MODE
 The ‘effective address is the sum of the two registers
and a displacement .
 MOV DL ,5[BX][DI]
 MOV 5[BP][SI], AX
 MOV CL ,COST[BX[[SI]
EXAMPLE
 Find the address of physical memory for the
following instructions if the content of the
required registers are as given below
SS =2344 H, DS =4022H ,
BX =0200H,BP=1402H ,SI=4442H
i)MOV CL,1234H[SI]
i)MOV AL,5[SI[[BP]
EFFECTIVE ADDRESS AND REFERRED SEGMENTS
FOR VARIOUS MEMORY BASED ADDRESSING MODES

Weitere ähnliche Inhalte

Was ist angesagt?

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
 
Instruction set of 8086
Instruction set of 8086Instruction set of 8086
Instruction set of 80869840596838
 
Microprocessor 8086 instruction description
Microprocessor 8086 instruction descriptionMicroprocessor 8086 instruction description
Microprocessor 8086 instruction descriptionDheeraj Suri
 
Pin Description and Register Organization of 8086 Microprocessor
Pin Description and Register Organization of 8086 MicroprocessorPin Description and Register Organization of 8086 Microprocessor
Pin Description and Register Organization of 8086 MicroprocessorMuthusamy Arumugam
 
Architecture of 8085
Architecture of 8085Architecture of 8085
Architecture of 8085Sumit Swain
 
Stacks & subroutines 1
Stacks & subroutines 1Stacks & subroutines 1
Stacks & subroutines 1deval patel
 
Introduction to 80386
Introduction to 80386Introduction to 80386
Introduction to 80386Abinaya B
 
8086 microprocessor-architecture
8086 microprocessor-architecture8086 microprocessor-architecture
8086 microprocessor-architectureprasadpawaskar
 
8086 assembly language
8086 assembly language8086 assembly language
8086 assembly languageMir Majid
 
Presentation on 8086 Microprocessor
Presentation  on   8086 MicroprocessorPresentation  on   8086 Microprocessor
Presentation on 8086 MicroprocessorNahian Ahmed
 
8086 memory segmentation
8086 memory segmentation8086 memory segmentation
8086 memory segmentationSridari Iyer
 
8086 instructions
8086 instructions8086 instructions
8086 instructionsRavi Anand
 
Addressing modes of 8086
Addressing modes of 8086Addressing modes of 8086
Addressing modes of 8086Dr. AISHWARYA N
 
Register Organisation of 8086 Microprocessor
Register Organisation of 8086 MicroprocessorRegister Organisation of 8086 Microprocessor
Register Organisation of 8086 MicroprocessorNikhil Kumar
 

Was ist angesagt? (20)

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
 
Instruction set of 8086
Instruction set of 8086Instruction set of 8086
Instruction set of 8086
 
Microprocessor 8086 instruction description
Microprocessor 8086 instruction descriptionMicroprocessor 8086 instruction description
Microprocessor 8086 instruction description
 
Pin Description and Register Organization of 8086 Microprocessor
Pin Description and Register Organization of 8086 MicroprocessorPin Description and Register Organization of 8086 Microprocessor
Pin Description and Register Organization of 8086 Microprocessor
 
Architecture of 8085
Architecture of 8085Architecture of 8085
Architecture of 8085
 
Microprocessor 8086
Microprocessor 8086Microprocessor 8086
Microprocessor 8086
 
Stacks & subroutines 1
Stacks & subroutines 1Stacks & subroutines 1
Stacks & subroutines 1
 
Instruction formats-in-8086
Instruction formats-in-8086Instruction formats-in-8086
Instruction formats-in-8086
 
8086 Architecture
8086 Architecture8086 Architecture
8086 Architecture
 
MicroProcessors
MicroProcessors MicroProcessors
MicroProcessors
 
Introduction to 80386
Introduction to 80386Introduction to 80386
Introduction to 80386
 
8086 microprocessor-architecture
8086 microprocessor-architecture8086 microprocessor-architecture
8086 microprocessor-architecture
 
8086 assembly language
8086 assembly language8086 assembly language
8086 assembly language
 
Presentation on 8086 Microprocessor
Presentation  on   8086 MicroprocessorPresentation  on   8086 Microprocessor
Presentation on 8086 Microprocessor
 
8086 memory segmentation
8086 memory segmentation8086 memory segmentation
8086 memory segmentation
 
8086 instructions
8086 instructions8086 instructions
8086 instructions
 
Addressing modes of 8086
Addressing modes of 8086Addressing modes of 8086
Addressing modes of 8086
 
DAA AND DAS
DAA AND DASDAA AND DAS
DAA AND DAS
 
Register Organisation of 8086 Microprocessor
Register Organisation of 8086 MicroprocessorRegister Organisation of 8086 Microprocessor
Register Organisation of 8086 Microprocessor
 
Register Organization of 80386
Register Organization of 80386Register Organization of 80386
Register Organization of 80386
 

Ähnlich wie Architecture of the 8086 Microprocessor

address5ng modes.pptx IS A GOOD MATERIAL
address5ng  modes.pptx IS A GOOD MATERIALaddress5ng  modes.pptx IS A GOOD MATERIAL
address5ng modes.pptx IS A GOOD MATERIALDrkoteswararaoseelam
 
Lecture 28 , 29 & 30(instruction set & addressing mode of 8086.pptx
Lecture 28 , 29 & 30(instruction set & addressing mode of 8086.pptxLecture 28 , 29 & 30(instruction set & addressing mode of 8086.pptx
Lecture 28 , 29 & 30(instruction set & addressing mode of 8086.pptxVikasMahor3
 
8086 instruction set (with simulator)
8086 instruction set (with simulator)8086 instruction set (with simulator)
8086 instruction set (with simulator)Aswini Dharmaraj
 
Mastering Assembly Language: Programming with 8086
Mastering Assembly Language: Programming with 8086Mastering Assembly Language: Programming with 8086
Mastering Assembly Language: Programming with 8086sravanithonta79
 
Lecture 9 examples (1)
Lecture 9 examples (1)Lecture 9 examples (1)
Lecture 9 examples (1)talhashahid40
 
introduction to Architecture of 8086 and it's application
introduction to Architecture of 8086 and it's applicationintroduction to Architecture of 8086 and it's application
introduction to Architecture of 8086 and it's applicationDrVikasMahor
 
8086 microprocessor pptx JNTUH ece 3rd year
8086 microprocessor pptx JNTUH ece 3rd year8086 microprocessor pptx JNTUH ece 3rd year
8086 microprocessor pptx JNTUH ece 3rd yearBharghavteja1
 
Notes 8086 instruction format
Notes 8086 instruction formatNotes 8086 instruction format
Notes 8086 instruction formatHarshitParkar6677
 
SAURABH MITRA-8086 MICROPROCESSOR
SAURABH MITRA-8086 MICROPROCESSORSAURABH MITRA-8086 MICROPROCESSOR
SAURABH MITRA-8086 MICROPROCESSORSAURABH MITRA
 
Microprocessor.pdf
Microprocessor.pdfMicroprocessor.pdf
Microprocessor.pdfpradipsaha77
 
8086addressingmodes-200319141110.pdf
8086addressingmodes-200319141110.pdf8086addressingmodes-200319141110.pdf
8086addressingmodes-200319141110.pdfTanmoyMondal89
 
31. 8086 addressing modes
31. 8086 addressing modes31. 8086 addressing modes
31. 8086 addressing modessandip das
 
02 Addressing Modes.pptx
02 Addressing Modes.pptx02 Addressing Modes.pptx
02 Addressing Modes.pptxssuser586772
 
8086 Register organization and Architecture details
8086 Register organization and Architecture details8086 Register organization and Architecture details
8086 Register organization and Architecture detailsMahendraMunirathnam1
 
Introduction of 8086 micro processor .
Introduction of 8086 micro processor .Introduction of 8086 micro processor .
Introduction of 8086 micro processor .Siraj Ahmed
 
physical_address segmentation.pdf
physical_address segmentation.pdfphysical_address segmentation.pdf
physical_address segmentation.pdfSwapnil511014
 

Ähnlich wie Architecture of the 8086 Microprocessor (20)

address5ng modes.pptx IS A GOOD MATERIAL
address5ng  modes.pptx IS A GOOD MATERIALaddress5ng  modes.pptx IS A GOOD MATERIAL
address5ng modes.pptx IS A GOOD MATERIAL
 
Lecture 28 , 29 & 30(instruction set & addressing mode of 8086.pptx
Lecture 28 , 29 & 30(instruction set & addressing mode of 8086.pptxLecture 28 , 29 & 30(instruction set & addressing mode of 8086.pptx
Lecture 28 , 29 & 30(instruction set & addressing mode of 8086.pptx
 
8086 instruction set (with simulator)
8086 instruction set (with simulator)8086 instruction set (with simulator)
8086 instruction set (with simulator)
 
Mastering Assembly Language: Programming with 8086
Mastering Assembly Language: Programming with 8086Mastering Assembly Language: Programming with 8086
Mastering Assembly Language: Programming with 8086
 
Lecture 9 examples (1)
Lecture 9 examples (1)Lecture 9 examples (1)
Lecture 9 examples (1)
 
introduction to Architecture of 8086 and it's application
introduction to Architecture of 8086 and it's applicationintroduction to Architecture of 8086 and it's application
introduction to Architecture of 8086 and it's application
 
8086 microprocessor pptx JNTUH ece 3rd year
8086 microprocessor pptx JNTUH ece 3rd year8086 microprocessor pptx JNTUH ece 3rd year
8086 microprocessor pptx JNTUH ece 3rd year
 
Notes 8086 instruction format
Notes 8086 instruction formatNotes 8086 instruction format
Notes 8086 instruction format
 
SAURABH MITRA-8086 MICROPROCESSOR
SAURABH MITRA-8086 MICROPROCESSORSAURABH MITRA-8086 MICROPROCESSOR
SAURABH MITRA-8086 MICROPROCESSOR
 
Microprocessor.pdf
Microprocessor.pdfMicroprocessor.pdf
Microprocessor.pdf
 
8086addressingmodes-200319141110.pdf
8086addressingmodes-200319141110.pdf8086addressingmodes-200319141110.pdf
8086addressingmodes-200319141110.pdf
 
8086 addressing modes
8086 addressing modes8086 addressing modes
8086 addressing modes
 
31. 8086 addressing modes
31. 8086 addressing modes31. 8086 addressing modes
31. 8086 addressing modes
 
02 Addressing Modes.pptx
02 Addressing Modes.pptx02 Addressing Modes.pptx
02 Addressing Modes.pptx
 
8086 Register organization and Architecture details
8086 Register organization and Architecture details8086 Register organization and Architecture details
8086 Register organization and Architecture details
 
Introduction of 8086 micro processor .
Introduction of 8086 micro processor .Introduction of 8086 micro processor .
Introduction of 8086 micro processor .
 
physical_address segmentation.pdf
physical_address segmentation.pdfphysical_address segmentation.pdf
physical_address segmentation.pdf
 
8086
80868086
8086
 
The 8086 microprocessor
The  8086 microprocessorThe  8086 microprocessor
The 8086 microprocessor
 
Chapter 3 programming concepts-ii
Chapter 3  programming concepts-iiChapter 3  programming concepts-ii
Chapter 3 programming concepts-ii
 

Mehr von SHREEHARI WADAWADAGI

Mehr von SHREEHARI WADAWADAGI (16)

Chapter 15 software product metrics
Chapter 15 software product metricsChapter 15 software product metrics
Chapter 15 software product metrics
 
Chapter 14 software testing techniques
Chapter 14 software testing techniquesChapter 14 software testing techniques
Chapter 14 software testing techniques
 
Chapter 13 software testing strategies
Chapter 13 software testing strategiesChapter 13 software testing strategies
Chapter 13 software testing strategies
 
Chapter 12 user interface design
Chapter 12 user interface designChapter 12 user interface design
Chapter 12 user interface design
 
Chapter 21 project management concepts
Chapter 21 project management conceptsChapter 21 project management concepts
Chapter 21 project management concepts
 
Ch 11-component-level-design
Ch 11-component-level-designCh 11-component-level-design
Ch 11-component-level-design
 
Ch 9-design-engineering
Ch 9-design-engineeringCh 9-design-engineering
Ch 9-design-engineering
 
An introduction to software engineering
An introduction to software engineeringAn introduction to software engineering
An introduction to software engineering
 
Architectural design
Architectural designArchitectural design
Architectural design
 
Chapter 5 programming concepts iv
Chapter 5  programming concepts ivChapter 5  programming concepts iv
Chapter 5 programming concepts iv
 
Chapter 4 programming concepts III
Chapter 4  programming concepts IIIChapter 4  programming concepts III
Chapter 4 programming concepts III
 
Brief description of all the interupts
Brief description of all the interuptsBrief description of all the interupts
Brief description of all the interupts
 
Chapter 7 memory & i/o
Chapter 7  memory & i/oChapter 7  memory & i/o
Chapter 7 memory & i/o
 
Chapter 6 hardware structure of 8086
Chapter 6  hardware structure of 8086Chapter 6  hardware structure of 8086
Chapter 6 hardware structure of 8086
 
Arm processor
Arm processorArm processor
Arm processor
 
8086 complete guide
8086 complete guide 8086 complete guide
8086 complete guide
 

Kürzlich hochgeladen

Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Dr.Costas Sachpazis
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxupamatechverse
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxAsutosh Ranjan
 
Microscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxMicroscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxpurnimasatapathy1234
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
Software Development Life Cycle By Team Orange (Dept. of Pharmacy)
Software Development Life Cycle By  Team Orange (Dept. of Pharmacy)Software Development Life Cycle By  Team Orange (Dept. of Pharmacy)
Software Development Life Cycle By Team Orange (Dept. of Pharmacy)Suman Mia
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Call Girls in Nagpur High Profile
 
SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )Tsuyoshi Horigome
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)simmis5
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCall Girls in Nagpur High Profile
 
result management system report for college project
result management system report for college projectresult management system report for college project
result management system report for college projectTonystark477637
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...Soham Mondal
 
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130Suhani Kapoor
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performancesivaprakash250
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINESIVASHANKAR N
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...ranjana rawat
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Christo Ananth
 

Kürzlich hochgeladen (20)

Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINEDJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
DJARUM4D - SLOT GACOR ONLINE | SLOT DEMO ONLINE
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptx
 
Microscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxMicroscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptx
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
 
Software Development Life Cycle By Team Orange (Dept. of Pharmacy)
Software Development Life Cycle By  Team Orange (Dept. of Pharmacy)Software Development Life Cycle By  Team Orange (Dept. of Pharmacy)
Software Development Life Cycle By Team Orange (Dept. of Pharmacy)
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
 
SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )
 
Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)Java Programming :Event Handling(Types of Events)
Java Programming :Event Handling(Types of Events)
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
 
result management system report for college project
result management system report for college projectresult management system report for college project
result management system report for college project
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
 
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
 
Roadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and RoutesRoadmap to Membership of RICS - Pathways and Routes
Roadmap to Membership of RICS - Pathways and Routes
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performance
 
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINEMANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
MANUFACTURING PROCESS-II UNIT-2 LATHE MACHINE
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 

Architecture of the 8086 Microprocessor

  • 2. INTRODUCTION  Need to know the learning of x86 family of microprocessors  Understand the architecture of the 8086  8086 is a processor catering to 16-bit data (D0 to D15) and having a 20-bit address (A0 to A19)  8086 is a 16-bit processor internally & externally  means its data bus width as well as the bit size of its internal data registers is 16  it can even access external source 16 bits  it also has the capacity to access and work on 8-bit data.
  • 4.
  • 5. 1.3 BUS INTERFACE UNIT This unit is responsible for  Address Calculations  pre-fetching instructions for the queue and sequencing instructions one by one.
  • 6. 1.3.1 INSTRUCTION QUEUE  Instructions are found in memory  From there it has to be fetched & decoded whenever needed for execution.  in 8086, the queue that fetches instructions ahead of execution time & places them in a 6-byte FIFO queue  This pre-fetching is done when buses are free  Advantage of this is when a particular instruction needs to be executed, it’s a good chance of finding in a queue rather than from memory
  • 7. 1.3.2 MEMORY SEGMENTATION  8086 has a 20-Bit address bus ( As we have not seen any 20- Bit regsters so far)  general-purpose registers are used as 16 or 8 bit registers  all address registers also are16-bit  Segmentation will be used to take care of this situation  A segment is just an area in memory  so total memory size can be considered to be divided into segments of various sizes.  Idea of dividing memory is called Segmentation  In memory data is stored as bytes  Each byte has a specific address  with 20 address lines, the memory that can be addressed is 220 bytes (1,048,576 Bytes or 1 MB)  8086 can access a physical memory with address ranging from 00000 to FFFFFH.
  • 8.  20-bit physical address is to be placed on the address bus to access any location in memory.  Memory as a whole is considered to have four different types of segments: 1. data segment 2. code segment 3. stack segment 4. extra segment  Idea of segmentation is to keep data & code separately  code segment contains code only  data is stored in the data segment  extra segment is just another type of data segment used in special way  stack segment is an area in memory which functions and is accessed from the other three segments
  • 9. 1.3.2.1 SEGMENT REGISTERS  Each segments is addressed by an address stored in corresponding segment registers  registers are all 16-bit size  each register stores base address of the corresponding segment  Base address is the starting address of a segment  since segment registers cannot store 20 bits, they store only the upper 16 bits  least significant nibble is implied to zero  How 20 bit physical address obtained if there are only 16 bit registers?  20 bit address of a byte is called Physical address  it is specified as Logical address in the form of two16-bit numbers in the format base address : offset
  • 10.  Example: Calculation of a physical address from the logical address for a data segment
  • 11.  Consider that a data byte is stored in a data segment, whose base address is 22220H  Then data segment register will contain the number 2222H.  The data at any location within this segment is referred to an offset with respect to the base address.  If a data at a location has a logical address specified as 2222H:0016H  Then the number 0016H is the offset or displacement w.r.t the base address  For physical address calculation, the BIU appends the segment register content with four binary zeros on the right.  Thus physical address is calculated as: 22220H + 0016H 22236H
  • 12.  Similar in case for the other segments  offsets are limited to 16Bits  means that the maximum size possible for a segment is only 216 or 64KB  Hence every memory reference by the 8086 will use one of the segment registers (i.e DS, ES, SS, or CS)  combined to form an offset to determine the physical address being accessed.  Fig that highlights a data byte that has the logical address of the form DS: Offset.
  • 13.  Code segment is the area of memory where code alone is stored.  offsets in the code segment are referenced by Instruction Pointer. ( a 16-Bit register)  IP sequences the instructions and points to the next instruction to be executed.  If an instruction byte has to be fetched from memory, the bus interface unit performs the address calculation using the contents of CS registers & the IP  This 20-bit address is then placed on the address bus and the instruction byte is fetched.  Hence the logical address for an instruction is of the form CS:IP 1.3.2.2 CODE SEGMENT & INSTRUCTION POINTER
  • 14.  Stack is an area in memory and data is generally pushed & popped out of the stack  8086 also uses LIFO stack  There is a 16-Bit register called Stack Pointer, which points to the top of the stack  Stack segment is like other segment  upper 16 bits of its base address is available in the SS register  A stack address of the form 4466H: 0122H means that the SS register contains 4466H  stack pointer contains the number 0122H  So the physical address of the top of the stack is 44660H + 0122H = 44782H 1.3.2.3 STACK SEGMENT AND STACK POINTER
  • 15.
  • 16.  Both segments store data  Extra segment register to store the upper 16 bits of the base address of the extra segment.  offset within the data segment is also termed as ‘ effective address’  effective address calculations depends on effect of mode of answering.  Table shows the segment registers and the corresponding registers that can be used for offsets 1.3.2.4 DATA SEGMENT AND EXTRA SEGMENT
  • 17. ADVANTAGES OF SEGMENTATION  All address registers are only 16 bit long, though the physical address is 20 bits  All address are re-locatable  Memory organization in little-endian format
  • 18.  In order for computations in assembly language, we need an Opcode & Operands  Opcode stands for Operation Code  Opcode specifies the operation to be performed  Opcodes operate on data, which are called the Operands  The way in which operands are specified in an assembly language is called its “Addressing Mode”.  Operands can be in registers, in memory or may be in the instruction itself.  in case of two operands, one of them can be in memory, but the other will have to be placed in a register  data types should match, that is, source, and destination should both be either bytes or words 1.4 ADDRESSING MODES
  • 19.  Here both source and destination are registers. No memory access are involved. MOV AL, AH ; copy the content of AH to AL MOV CH, BL ; copy the content of BL to CH MOV SI, BX ; copy the content of BX to SI MOV ES,AX ; copy the content of AX to ES Note that the first two are byte operations, while the other two are word operations. MOV AX, BL ; gives error as AX is 16 bit & BL is 8 bit MOV BL, AX ; gives an error for the same reasons 1.4.1 REGISTER ADDRESSING
  • 20.  Here source will be a constant data MOV AL, 45H ; copy 45H to AL MOV BX, 34E3H ; move the hex number 34E3H to BX MOV CL.’Q’ ; move the ASCII value of Q to CL MOV PRICE,40 ; move the hex num 40 to the memory location with the label PRICE MOV NUMS, 0FC6H ; move the hex number 0FC6H to the memory location NUMS  Segment registers are not allowed to use this mode of addressing MOV DS,2300H ; gives an error as DS is a segment register 1.4.2 IMMEDIATE ADDRESSING
  • 21.  Here, either the source or the destination will be a memory address MOV AX, [2345H] ; move word location 2345H to AX MOV [1089H], AL ; the byte in AL is moved to location 1086H  MOV AX , PRICE  MOV COST,AL PRICE and COST are labels for memory addresses 1.4.3 DIRECT ADDRESSING
  • 22. 1.4.4REGISTER INDIRECT ADDRESSING  In this mode , the address of the data is held in a register  Effective address  EA=EA= { [BX] / [DI] /[SI]}  MOV AL,[BX] ; move into AL the content of the location whose address is in BX  MOV [SI], CL ;move the content of CL to the address pointed by SI  MOV [DI],AX ; move the content of AX to the address pointed by DI  In third instruction, AX contains two bytes, so the content of AL will be moved to the address pointed by DI.  The content of AH will be moved to the address [D+1]
  • 23.  Show the location of data in memory, after the execution of each of these instructions , if the content of registers are as given DS= 1112H , AX= EE78H and BX=3400H MOV [0422H], AL MOV [0424H],AX MOV [BX] ,AX EXAMPLE
  • 24. 1.4.5 REGISTER RELATIVE ADDRESSING  In relative addressing mode , a number or displacement is part of the effective address  EA ={[BX] /[DI] /[SI] /[BP]} + 8 bit or 16 bit displacement  The displacement can be a 16 bit signed/unsigned number or an 8 bit sign extended number.  MOV CL ,10[BX] ; move the content of the address specified by adding the content of BX and 10  Like  MOV CL, [BX+10]  MOV CL, [BX]+10
  • 25. 1.4.6 BASED INDEXED MODE  In this mode ,an index register and a base register together carry the effective address .  The content of these two registers are added and called the effective address.  MOV AL,[BX][SI] ; move the content of the effective address pointed by [BX] and [SI] into AL  MOV [BX][DI],CX ;move the content of CX to the effective address pointed by [BX] and [SI]
  • 26. 1.4.7 RELATIVE BASED INDEXED MODE  The ‘effective address is the sum of the two registers and a displacement .  MOV DL ,5[BX][DI]  MOV 5[BP][SI], AX  MOV CL ,COST[BX[[SI]
  • 27. EXAMPLE  Find the address of physical memory for the following instructions if the content of the required registers are as given below SS =2344 H, DS =4022H , BX =0200H,BP=1402H ,SI=4442H i)MOV CL,1234H[SI] i)MOV AL,5[SI[[BP]
  • 28. EFFECTIVE ADDRESS AND REFERRED SEGMENTS FOR VARIOUS MEMORY BASED ADDRESSING MODES