Microprocessor & Its Architecture
Microprocessor & Its Architecture
Introduction
This chapter presents the microprocessor as a
programmable device by first looking at its
internal programming model and then how its
memory space is addressed.
The architecture of Intel microprocessors is
presented, as are the ways that the family
members address the memory system.
Addressing modes for this powerful family of
microprocessors are described for the real,
protected, and flat modes of operation.
ELX215: Microprocessor systems. SEGi University College, 2008.
Chapter Objectives
Upon completion of this chapter, you will be able to:
Chapter Objectives
(cont.)
21 INTERNAL MICROPROCESSOR
ARCHITECTURE
Before a program is written or instruction
investigated, internal configuration of the
microprocessor must be known.
In a multiple core microprocessor each core
contains the same programming model.
Each core runs a separate task or thread
simultaneously.
Figure 21 The programming model of the 8086 through the Core2 microprocessor
including the 64-bit extensions.
Multipurpose Registers
RAX - a 64-bit register (RAX), a 32-bit register
(accumulator) (EAX), a 16-bit register (AX),
or as either of two 8-bit registers (AH and AL).
The accumulator is used for instructions such
as multiplication, division, and some of the
adjustment instructions.
Intel plans to expand the address bus to 52
bits to address 4P (peta) bytes of memory.
ELX215: Microprocessor systems. SEGi University College, 2008.
Special-Purpose Registers
Include RIP, RSP, and RFLAGS
segment registers include CS, DS, ES, SS, FS,
and GS
Figure 22 The EFLAG and FLAG register counts for the entire 8086 and Pentium
microprocessor family.
Segment Registers
Generate memory addresses when combined
with other registers in the microprocessor.
Four or six segment registers in various
versions of the microprocessor.
A segment register functions differently in real
mode than in protected mode.
Following is a list of each segment register,
along with its function in the system.
think of segments as
windows that can be
moved over any area
of memory to access
data or code
a program can have
more than four or six
segments,
but only access four or
six segments at a time
a program placed in
memory by DOS is loaded
in the TPA at the first
available area of memory
above drivers and other
TPA programs
area is indicated by a freepointer maintained by DOS
program loading is handled
automatically by the
program loader within DOS
ELX215: Microprocessor systems. SEGi University College, 2008.
Figure 27 The access rights byte for the 80286 through Core2 descriptor.
Figure 29 Using the DS register to select a description from the global descriptor
table. In this example, the DS register accesses memory locations 00100000H
001000FFH as a data segment.
Program-Invisible Registers
Global and local descriptor tables are found
in the memory system.
To access & specify the table addresses,
80286Core2 contain program-invisible
registers.
not directly addressed by software
Each segment register contains a programinvisible portion used in the protected mode.
often called cache memory because cache is
any memory that stores information
ELX215: Microprocessor systems. SEGi University College, 2008.
24 MEMORY PAGING
The memory paging mechanism allows any
physical memory location to be assigned to
any linear address.
Iinear address is defined as the address
generated by a program.
Physical address is the actual memory
location accessed by a program.
With memory paging, the linear address is
invisibly translated to any physical address.
ELX215: Microprocessor systems. SEGi University College, 2008.
Paging Registers
The paging unit is controlled by the contents
of the microprocessors control registers.
Beginning with Pentium, an additional control
register labeled CR4 controls extensions to
the basic architecture.
See Figure 211 for the contents of control
registers CR0 through CR4.
Figure 212 The format for the linear address (a) and a page directory or page table
entry (b).
Figure 213 The paging mechanism in the 80386 through Core2 microprocessors.
Figure 214 The page directory, page table 0, and two memory pages. Note how the
address of page 000C8000000C9000 has been moved to 0011000000110FFF.
SUMMARY
The programming model of the 8086
through 80286 contains 8- and 16-bit
registers.
The programming model of the 80386 and
above contains 8-, 16-, and 32-bit extended
registers as well as two additional 16-bit
segment registers: FS and GS.
SUMMARY
(cont.)
SUMMARY
(cont.)
The 64-bit registers in a Pentium 4 with 64bit extensions are RAX, RBX, RCX, RDX,
RSP, RBP, RDI, RSI, and R8 through R15.
In addition, the microprocessor contains an
instruction pointer (IP/EIP/RIP) and flag
register (FLAGS, EFLAGS, or RFLAGS).
All real mode memory addresses are a
combination of a segment address plus an
offset address.
ELX215: Microprocessor systems. SEGi University College, 2008.
SUMMARY
(cont.)
SUMMARY
(cont.)
SUMMARY
(cont.)
SUMMARY
(cont.)
SUMMARY
(cont.)
SUMMARY
(cont.)
SUMMARY
(cont.)
SUMMARY
(cont.)
SUMMARY
(cont.)
SUMMARY
The flat mode memory contains 1T byte of
memory using a 40-bit address.
In the future, Intel plans to increase the
address width to 52 bits to access 4P bytes
of memory.
The flat mode is only available in the
Pentium 4 and Core2 that have their 64-bit
extensions enabled.