Unit II 8086 SYSTEM Bus Structure: Book
Unit II 8086 SYSTEM Bus Structure: Book
8086 SYSTEM
BUS STRUCTURE
Book :
Yu-Cheng Liu, Glenn A.Gibson, “Microcomputer
Systems: The 8086 / 8088 Family -
Architecture, Programming and Design”,
Second Edition, Prentice Hall of India, 2007.
04/05/2022 1
04/05/2022 2
04/05/2022 3
04/05/2022 4
04/05/2022 5
04/05/2022 6
04/05/2022 7
04/05/2022 8
04/05/2022 9
04/05/2022 10
04/05/2022 11
04/05/2022 12
04/05/2022 13
04/05/2022 14
04/05/2022 15
PIN DEFINITIONS
04/05/2022 16
Basic
configurations
M/ IO RD WR Type of
operation
0 0 1 I/O READ
0 1 0 I/O WRITE
1 0 1 MEMORY
READ
1 1 0 MEMORY
WRITE
Minimum Mode Configuration
Minimum Mode 8086 System
•In this mode, all the control signals are given out by
the microprocessor chip itself. There is a single
microprocessor in the minimum mode system.
To signal that
the address is
ready to be
latched a 1 is
put on pin 25,
the address
latch enable
(ALE) pin.
Minimum mode 8086 system
• • Transreceivers (8286)are the bidirectional buffers and
some times they are called as data amplifiers. They are
required to separate the valid data from the time
multiplexed address/data signals.
• • They are controlled by two signals namely, DEN and
DT/R.
8286 – transceiver(driver/receiver)
The 8286 contains 16
tristate elements, eight
receivers and eight
drivers.
CLK – i/p
synchronizes bus
controller activity
with μP
CEN,IOB AEN –
are for
multiprocessor
systems
In a single
processor
Pin OtherDefinition
pin definitions
INTA Interrupt acknowledgement
IORC I/O read command, instructs the I/O
interface to put data contained in the
addressed port on data bus
Book :
Yu-Cheng Liu, Glenn A.Gibson, “Microcomputer Systems: The 8086 / 8088
Family - Architecture, Programming and Design”, Second Edition, Prentice
Hall of India, 2007.
Typical system bus architecture
Timing Diagrams
Typical sequence of bus cycles
If a HOLD signal is
received by the processor
before T4 or during a T1
state, then the CPU
activates HLDA and the
succeeding bus cycle will
be given to the requesting
master until that master
drops its request.
04/05/2022 73
Multiprocessor
Configuration
UNIT 2
5/4/22 74
MULTIPROCESSOR
• Multiprocessor Systems refer to the use of
multiple processors that executes
instructions simultaneously and
communicate with each other using mail
boxes and Semaphores.
5/4/22 75
Multiprocessor Configurations
5/4/22 76
FEATURES
5/4/22 77
Coprocessor / Closely Coupled
Configuration
5/4/22 78
COPROCESSOR
5/4/22 79
TEST pin of 8086
5/4/22 81
Interaction b/w CPU & COP
• ESC – instruction to be executed by COP is indicated when ESC
appears in PGM sequence
• Only HOST CPU can fetch instn
• Cop receives all instructions ,monitors instn seq of host
• ESC has external op code – tells what a COP has to do
• Esc – decoded by both CPU,COP
5/4/22 82
Interaction b/w CPU & COP
5/4/22 83
ESC INSTRUCTION
5/4/22 84
5/4/22 85
2.Closely Coupled Execution
• Closely Coupled processor – independent
processor
• To mimimize cost,independent processor can be
tied to CPU to form closely coupled system in
which both share same clock and bus control
logic independently
5/4/22 86
Interprocessor communciation
5/4/22 87
5/4/22 88
5/4/22 89
3.Loosely Coupled
Configuration
• has shared system bus, system memory, and
system I/O.
• each processor has its own clock as well as its
own memory (in addition to access to the
system resources).
• Used for medium to large multiprocessor
systems.
5/4/22 90
3.Loosely Coupled
Configuration
• Each module is capable of being
the bus master.
• Any module could be a processor
capable of being a bus master, a
coprocessor configuration or a
closely coupled configuration
5/4/22 91
Loosely Coupled Configuration
• No direct connections between the
modules. Each share the system bus and
communicate through shared
resources.
• Processor in their separate modules can
simultaneously access their private
subsystems through their local busses,
and perform their local data references
and instruction fetches independently. This
results in improved degree of
concurrent processing.
5/4/22 92
Advantages of Multiprocessor
5/4/22 93
Advantages of Multiprocessor
• One can be added or removed without
affecting the others in the system.
• A failure in one module normally does
not affect the breakdown of the entire
system and the faulty module can be
easily detected and replaced
• Each bus master has its own local bus to
access dedicated memory or IO devices.
So a greater degree of parallel
processing can be achieved.
5/4/22 94
Loosely Coupled
Configurations
• In a loosely coupled multiprocessor
system, more than one bus master
module may have access to the
shared system bus.
• Since each master is running
independently, extra bus control logic
must be provided to resolve the bus
arbitration problem
• This extra logic is called bus access logic
and it is its responsibility to make sure
that only one bus master at a time has
control of the bus.
• Simultaneous bus requests are
resolved on a priority basis. There are
three schemes for establishing
priority:
5/4/22 95
5/4/22 96
5/4/22 97
SUMMARY
• In summary, processing modules of different
configurations may be combined to form a complex,
loosely coupled multiprocessor system.Each module in
such a system may be:
Unit II
8086/8088, 80186/80188, 80286,
80386, 80486, Pentium, Pentium Pro Processor,
Pentium Ⅱ, Pentium Ⅲ, Pentium 4
Architecture, Programming,
and Interfacing - 6 Ed. -
Barry B. Brey
100
Intel family of
microprocessor,s bus and
memory sizes
101
80186/80188
• High-Integration CPUs
• schematic diagram for IBM’s original PC
• 8088 microprocessor
• several additional chips are required
• 80186 = 8086 + several additional chips
• added 9 new instructions
• clock generator
• programmable timer
• programmable interrupt controller
• circuitry to select the I/O devices
102
103
80286 (1982)
• some instruction executed : 250ns(4.0MIPS) at 8MHz
• 24-bit address bus : 16M byte memory
• added 16 new instructions
• Real Mode: 1st powered on
• functions exactly like an 8086
• uses only its 20 least significant address lines(1M)
• Protected :
• A “Fatal Flaw” ?
• once switched to Protected mode, should not be able to
switch back to Real mode
• 286 chips are operated in Real mode and thus function only
as fast 8086s
• IBM AT(advanced technology) Computer :1984
104
105
80386
• flexible 32-bit Microprocessor(1986) : data bus, registers
• very large address space : 32-bit address bus(4G byte
physical)
• 64 terabyte virtual
• 4G maximum segment size
• integrated memory management unit
• virtual memory support, optional on-chip paging
• 4 levels of protection
• added 16 new instructions
• Real Mode, Protected mode
• Virtual 8086 mode : in a protected and paged system
• 386SX : 16-bit external data bus, 24-bit address bus
• 386EX : 16-bit external data bus, 26-bit address bus
• 1995, called embedded PC
106
107
80486
108
109
80486
• 486SX :
• for low-end applications that do not require a coprocessor or
internal cache
• clock speed limited 33MHz
• 486DX2 & DX4 :
• internal clock rate is twice or 3 times external clock rate
• 486DX4 100 : internal 100MHz, external 33MHz
• Overdrive Processor:
• 486DX2 or DX4 chips with overdrive socket pin-outs
• to upgrade low-speed 486DX, SX with 486DX2, DX4
110
Pentium
• increasing the complexity of the IC: to scale the chip
down
• if every line could be shrunk in half, same circuit could be
built in one-forth the area
• Superscaler : support 2 instruction pipelines(5 stage)
• ALU, address generation circuit, data cache interface
• actually execute two different instruction simultaneously
• Pentium(1993) : originally labeled P5(80586)
• 60, 66MHz(110MIPS)
• 8K code cache, 8K data cache
• coprocessor : redesign(8-stage instruction pipeline)
• external data bus : 64 bit(higher data transfer rates)
• added 6 new instructions : for used by OS
111
112
113
114
Pentium pro
• codenamed P6 : 1995 ‘basic clock frequency : 150,
166MHz
• two chips in one : two separate silicon die
• processor(large chip), 256K level two cache
• Superscaler processor of degree three(12 stage)
• internal cache :
• level one(L1) : 8K instruction and data cache
• level two(L2) : 256K(or 512K)
• 36-bit address bus : 64G byte memory
• has been optimized to efficiently execute 32-bit code
• bundled with Windows NT : server market
115
PentiumⅡand PentiumⅡXeon Microprocessor
• PentiumⅡmicroprocessor released in 1997
117
Pentium Ⅲ Microprocessor
• 1. used faster core than PentiumⅡ
• is still P6 or Pentium pro processor
• 2. Two version :
• bus speed : 100MHz
• 1. slot 1 version mounted on a plastic cartridge
• 512K cache : one-half the clock speed
• 2. socket 370 version called flip-chip : looks like the
older Pentium package → Intel claim cost less
• 256K cache : clock speed
• 3. clock frequency : 1 GHz
118
Pentium 4 Microprocessor
• release in late 2000 : used Intel P6 architecture
• main difference :
• 1. clock speed : 1.3, 1.4, 1.5 GHz
• 2. support to use RAMBUS memory technology
• DDR(double-data-rate) SDRAM : both edge
• 3. interconnection : from aluminum to copper
• copper : is better conductor → increase clock frequency
• bus speed : from current max. of 133MHz to 200MHz or
higher
119
120
Multiprocessor systems - 8087
A system having two microprocessor will require only lesser time to complete
the task.
121
Multiprocessor Configurations
122
Coprocessor
A computer processor used to supplement the function of
primary processor.
Operation performed :
They are Unable to fetch the code from the memory so they
work under the control of main processor .
124
Intel 8087
Numeric Processor.
Packed in 40 pin ceramic DIP package.
Available in 5 MHz, 8MHz, 10MHz versions compatible with
8086, 8088, 80186, 80188.
It adds 68 new instruction to the instruction set of 8086.
How it works :
126
Two major sections:
1) Control unit
2) Numeric Execution unit
Control Unit :
Function :
It interface the coprocessor to the
microprocessor – system data bus.
Monitors the instruction stream.
If the instruction is an ESCape (coprocessor)
instruction, the coprocessor executes it; if not
the microprocessor executes it.
It receives , decodes instructions, read and
write memory operands and executes the 8087
instruction.
127
Numeric Execution Unit (NEU)
Functions :
Execute all the numeric processor instructions.
It has 8 register (80 bit) stack that holds the operands for
arithmetic instructions & the result.
Programmable shifter :
128
Microcode control unit :
129
Status word of 8087
130
1) B – busy bit
Indicates the coprocessor is busy in executing a
task.
2) C3- C0 (Condition code bits)
Indicates the condition of the coprocessor.
3) TOP ( Top-of-stack (ST))
Indicates the current register addressed as the top-
of-the stack (ST). Normally register 0.
4) ES – error summary
Bit is set if any unmasked error bit (PE,UE,OE, ZE,
DE or IE) is set.
5) PE – precision error
Indicate the result or operand exceed the selected
precision. 131
6) UE – Underflow Error
Indicates a non zero result that is too small to
represent with the current precision selected.
7) OE – Overflow Error
Indicates a result is too large to be represented.
8) ZE – Zero Error
Indicates the divisor was zero while the
dividend is a non-infinity or non zero number.
9) DE – Denormalized error
Indicates that at least one of the operands is
denormalized.
132
Control Word Register of 8087
133
Control register
2) RC – Rounding Control
134
3) PC – Precision Control
Sets the precision of the result.
00 -> Single precision (short)
01 -> Reserved
10 -> Double – precision (long)
11 -> Extended precision (temporary)
4) Exception Masks
Determine whether the error indicated by the
exception affects the error bit in the status flag.
5) Zero Divide
If any non zero finite operand is divided by zero, this
exception is generated.
6) Denormalized Operand
Exception is generated if at least one of the operand
or the result is denormalized.
135
Signal Description
of 8087
136
Pin Diagram of 8087
137
1) AD0 - AD15 :
These are time multiplexed address / data lines.
Lines carry address during T1 and data during T2 T3
Tw &T4 states.
2) A19/S6 – A16/S3 :
These are time multiplexed address/ status lines.
These function in a similar way to the
corresponding pins of 8086.
S6 ,S4 & S3 are permanently high, while the S5 is
permanently low.
3) BHE / S7 :
During t1 the BHE / S7 pin is used to enable data on
to the higher byte of the 8086 data bus.
During T2 ,T3 , Tw and T4 this is a status line S7.
138
4) Qs1 , Qs0 :
139
5) INT
6) BUSY
7) READY
140
8) RESET
Used to abandon the internal activities of the
coprocessor and prepare it for further execution.
9) CLK
It provide the basic timing for the processor
operation.
10) VCC
A +5V supply
11) GND
A return line for the power supply. 141
12) S2 ,S1 and S0
These can be either be 8087 driven (output) or
s2 externally
S1 driven (input)
S0 by theQueue
CPU status
0 X X unused
1 0 0 Unused
1 0 1 Memory read
1 1 0 Memory write
1 1 1 passive
142
13) RQ / GT0
The request / grant pin is used to gain control of the
bus from the host (8086/ 8088) for operand transfer.
The 8087 waits for the grant pulse from the host.
144
Interconnections of 8087 with 8086/ 8088
145
Interconnection of 8087 with CPU :
The pins AD0 – AD15 , RESET , A19 /S6 - A16 /S3 , BHE / S7
are connected to the corresponding pin of 8086/8088.
150
1) Data Transfer Instruction
152
2) FIST/FISTP
The instruction work in exact similar manner as FST/ FSTP
except the fact that the operand are integer operand.
153
Arithmetic Instructions
1. FADD
2. FSUB
3. MUL
4. FDIV
5. FSQRT
6. FABS
154
Transcendental Instructions
FPATAN :
Instruction calculates the inverse tangent
The result is stored on the top of the stack.
The content of ST and ST(1) should follow the inequality.
0<=ST(1) < ST< infinity
F2XMI :
Instruction calculates the expression (2x - 1)
Value of x is stored at the top of the stack.
Result is stored back at the top of the stack.
155
FLY2X
It calculate ST(1) * Log2 ( ST)
Result is stored back at the top of stack.
ST must be in the range of 0 to +infinity.
ST(1) must be in the range of -infinity to +infinity.
FLY2XP1
It calculate ST(1) * log2[ (ST)+1 ]
Result is stored back on the stack top.
|ST| must lie between 0 and (1- 21/2 /2).
Value of ST(1) must lie between –infinity and +
infinity
156
Comparison Instruction
Comparison C3 C0
Stack Top > Source
0 0
Stack Top < Source
0 1
Stack Top = Source
1 0
Not Comparable
1 1
157
1. FCOM
The content of the top of stack is compared either
with the content of a memory location or with the
content of another stack register.
2. FIST
Instruction test if the content of the stack top is
Zero.
158
Constant Operation Instruction
1. FLDZ
Load +0.0 to stack top
2. FLDPI
Load pi(3.14) o stack top
3. FLDLG2
Load the constant Log10 2 to the stack pointer.
159
Coprocessor Control Instruction
I. FINIT
II. FENI
III. FDISI
IV. FLDCW
V. FSTSW
VI. FCLEX
VII. FFREE
VIII. FNOP
IX. FWAIT
160
Coprocessor Control
Instructions
FINIT/FNINIT
• Performs a reset (initialize) operation on the arithmetic
coprocessor.
• The coprocessor operates with a closure of projective
(unsigned infinity), rounds to the nearest or even, and
uses extended-precision when reset or initialized.
• also sets register 0 as the top of the stack
Coprocessor Control
Instructions
FSETPM
• Changes the coprocessor to the protected-addressing
mode.
• used when the microprocessor is protected mode
• Protected mode can only be exited by a hardware reset.
• or in 80386-Pentium 4, with a change to the control register
Coprocessor Control
Instructions
FLDCW
• Loads the control register with the
word addressed by the operand.
FSTCW
• Stores the control register into the
word-sized memory operand.
Coprocessor Control
Instructions
FCLEX
• Clears the error flags in the status register
and also the busy flag.
Coprocessor Control
Instructions
FSAVE
• Writes the entire state of the machine to memory.
FRSTOR
• Restores the state of the machine from memory.
This instruction is used to restore the
information saved by FSAVE.
Figure 14–8 Memory format when the 80X87 registers are saved with the
FSAVE instruction.
Coprocessor Control
Instructions
FSTENV
• Stores the environment of the coprocessor.
• as shown in Figure 14–9
FLDENV
• Reloads the environment saved by FSTENV.
FINCSP
• Increments the stack pointer.
Figure 14–9 Memory format for the FSTENV instruction: (a) real mode
and (b) protected mode.
Coprocessor Control
Instructions
FDECSP
• Decrements the stack pointer.
FFREE
• Frees a register by changing the destination
register’s tag to empty.
– does not affect the contents of the register
Coprocessor Control
Instructions
FNOP
• Floating-point coprocessor NOP.
FWAIT
• Causes the microprocessor to wait for the
coprocessor to finish an operation.
– should be used before the microprocessor accesses
memory data affected by the coprocessor
8089 I/O Processor
Unit 2
The 8089 I/O
Processor
Allows easy interface of
microprocessors with 8 bit or
16 bit peripherals
Functions like an intelligent
DMAC ,removes I/O overhead,
has 2 channels
Operates in parallel with
8086,improves performance in
I/O intensive applications
1.25 Mbps,at 5 MHz
Enhance software
The 8089 I/O
Processor
It is designed to handle the
details involved in I/O
processing
It fetches and execute is own
instructions
Instruction offers
• I/O operations
• Data transfer operations
• Arithmetic and Logical
Operations
• Branching, searching and
8089
Applications
The 8089 I/O Processor
CPU communicates with
memory based control blocks.
CPU performs Control blocks
that describes the task to be
performed.
Channel Program
• The IOP reads the control
blocks to locate a program
sequence called a channel
program which is written in
8089 instruction set.
I/O Handled by Microprocessor
I/O Handled by 8089
Remote Configuration
8089 Block diagram
8089 - pins
Block Diagram of 8089 IOP
IOP Architecture
Two Channels can be operated
independently.
Sharing common control logic and ALU.
Task Pointer = PC
PP –Parameter Pointer stores the
address of the parameter block
PSW which denotes
Source and destination
address widths
Channel activity
Interrupt control and servicing
Bus load limit
Priority
CC format