0% found this document useful (0 votes)
24 views85 pages

Microprocessors (CPU)

Uploaded by

Ghadeer
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views85 pages

Microprocessors (CPU)

Uploaded by

Ghadeer
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 85

Chapter 4

Microprocessors (CPU)

Unitintro: ICT1001 Computer Systems 2009


1
Overview
• In this chapter, you will learn how to:
• Identify the core components of a CPU
• Describe the relationship of CPUs and memory
• Explain the varieties of modern CPUs
• Select and install a CPU
• Troubleshoot CPUs

Unitintro: ICT1001 Computer Systems 2009


2
CPU Core Components
• The central processing unit (CPU) works as a
very powerful calculator.
• The CPU’s processing speed makes it look
intelligent.

Unitintro: ICT1001 Computer Systems 2009


3
The Man in the Box
• Visualize the CPU as a man in a box.
• He will gladly perform anything you want him to
do, but he can't see or hear anything outside the
box.
• How can you communicate with him?

Figure 4.1 Imagine the CPU as a man in a box.


Unitintro: ICT1001 Computer Systems 2009
4
The Man in the Box (continued)

Figure 4.2 How do we talk to the Man in the Box?

Unitintro: ICT1001 Computer Systems 2009


5
Talking to the Man
• Imagine 16 lights
• 8 on the inside and 8 on the outside
• When an inside light is on, the corresponding
outside light is on.
• Lights may be switched on or off from either side.
• Communication device is called the external data
bus (EDB).
Figure 4.3 Cutaway of the external
data bus—note that one light bulb pair
is on.
Unitintro: ICT1001 Computer Systems 2009
6
Talking to the Man (continued)
• Voltage applied to a little wire “flips the
switch.”

Figure 4.4 Close-up of the underside of a CPU

Unitintro: ICT1001 Computer Systems 2009


7
Talking to the Man (continued)
• In reality, there are no bulbs, only little wires
• Voltage is applied or not
• Rather than “on-off-on-off-on-on-off-off,”
represented as “10101100”

Figure 4.5 Here "1" means on, "0" means off.


Unitintro: ICT1001 Computer Systems 2009
8
Talking to the Man (continued)
• The CPU communicates with the outside world
using the external data bus (EDB)
• Uses binary (1 is on, and 0 is off) to communicate
• Data lines on the bus can be switched (turned on or
off) from inside or outside.

Unitintro: ICT1001 Computer Systems 2009


9
Registers
• Inside the box are registers
• Represented as worktables for the Man in the Box
• The four general-purpose registers found in all
CPUs are AX, BX, CX, and DX.

Figure 4.6 The four general-purposeUnitintro:


registers ICT1001 Computer Systems 2009
10
Codebook
• The Man in the Box needs one more tool: the
codebook or instruction set.
• The commands are called
machine language.
• One command is a line
of code.
• The complete set of
commands for a processor
is its instruction set.
Figure 4.7 CPU codebook
Unitintro: ICT1001 Computer Systems 2009
11
Machine Language for the Intel 8088
10111010 The next line of code is a number. Put that
number into the DX register.

01000001 Add 1 to the number already in the CX


register.

00111100 Compare the value in the AX register with the


next line of code.

Unitintro: ICT1001 Computer Systems 2009


12
The CPU So Far

Figure 4.8 The CPU so far

Unitintro: ICT1001 Computer Systems 2009


13
Clock
• The CPU does no work until told to—even
though data may be on the EDB.
• You need a bell to alert the Man in the Box.
• This is referred to as a clock wire (CLK wire)
• A charge on the CLK wire tells the CPU it is time to
work.

Figure 4.10 The CPU often needs more


Figure 4.9 The CPU does nothing than one clock cycle to get a result.
until activated by the clock. Unitintro: ICT1001 Computer Systems 2009
14
Clock (continued)
• A clock cycle is the time it takes for the CLK
wire to charge.
• A cycle is one complete up-and-down segment of
the sine wave.
• Every command requires at least two clock cycles.

Unitintro: ICT1001 Computer Systems 2009


15
Clock Speed
• Clock speed is the maximum number of clock
cycles the CPU can handle in a given time
period.
• Clock speed is measured in hertz
• One cycle per second = 1 hertz (Hz)
1 million cycles per second = 1 megahertz (MHz)
1 billion cycles per second = 1 gigahertz (GHz)
• Intel 8088 ran at 4.77 MHz
• Modern CPUs run at 3+ GHz
Unitintro: ICT1001 Computer Systems 2009
16
Clock Speed (continued)

Unitintro: ICT1001 Computer Systems 2009


17speed?
Figure 4.11 Where is the clock
System Crystal
• System crystal
governs CPU
running speed
• Modern CPUs tell
the motherboard
the clock speed it
needs, and the clock
chip automatically
adjusts. Figure 4.12 One of many types of system crystals
Unitintro: ICT1001 Computer Systems 2009
18
System Crystal (continued)
• Crystal can clock a CPU with a rated speed
higher than the crystal, but the CPU will
operate at the slower speed of the crystal.
• A 1 GHz crystal can clock a 2 GHz CPU, but the CPU
will operate only as fast as the crystal clock—1 GHz.
• Underclocking means running a CPU slower than its
rated clock speed—it does not take advantage of all
the power of the CPU.
• Overclocking means to run a CPU faster than its
maximum clock speed—it can overheat the CPU.
Unitintro: ICT1001 Computer Systems 2009
19
Back to the External Data Bus

Figure l4.13 Diagram of an Intel 8088 showing


the external data bus and clock wires
Unitintro: ICT1001 Computer Systems 2009
20
Memory
• A program is stored on the hard drive.
• Hard drives can’t give the CPU data at a fast
enough speed, so something that stores the
program and gives it to the CPU rapidly is
needed.
• Devices that hold ones and zeros that the CPU
accesses are called memory.
• Each line of memory has an address
• Used to locate the data Unitintro: ICT1001 Computer Systems 2009
21
Memory and RAM
• Random access memory (RAM) is organized like
a spreadsheet, with each row holding eight bits
(one byte).
• A bit is a one or a zero
• RAM transfers and stores data to and from the
CPU in byte-sized chunks
• Number of bytes of RAM varies from PC to PC,
with today's PCs holding billions of bytes of
RAM Unitintro: ICT1001 Computer Systems 2009
22
RAM as a Spreadsheet

Figure 4.14 RAM as a spreadsheet


Unitintro: ICT1001 Computer Systems 2009
23
DRAM
• Computers use dynamic RAM (DRAM) for main
memory
• Dynamic rather than static
• Circuits need constant electrical charge and to be
refreshed to maintain data.

Figure 4.15 Typical RAM


Unitintro: ICT1001 Computer Systems 2009
24
Address Bus
• CPU and RAM need a method to communicate,
so they use the EDB.
• The CPU needs a helper chip—the memory
controller chip (MCC) to facilitate the flow of
data from RAM to the CPU.

Figure 4.16 Extending the EDB Figure 4.17 The Unitintro:


MCCICT1001grabs a byte of RAM.
Computer Systems 2009
25
Address Bus (continued)
• The address bus is a separate set of wires from
the external data bus.
• Enables the CPU to control the MCC
• CPU tells the MCC which line of code it wants from
RAM

Figure 4.18 Address busICT1001 Computer Systems 2009


Unitintro:
26
Address Bus (continued)
• The number of wires in the address bus
determines the maximum amount of RAM the
CPU can handle.
• An 8088 had 20 wires, which provided 220
(1,048,576) combinations.
• Address space of 1,048,57 bytes or one megabyte
(1 MB)

Unitintro: ICT1001 Computer Systems 2009


27
Bits and Bytes
• Any individual 1 or 0 = a bit
• 4 bits = a nibble
• 8 bits = a byte
• 16 bits = a word
• 32 bits = a double word
• 64 bits = a paragraph or quad word
• Bits are represented as b (e.g., Kb)
• Bytes are represented as B (e.g., KB)
Unitintro: ICT1001 Computer Systems 2009
28
Addressing Rows of RAM
• To determine the location in RAM
• First byte of RAM represented by twenty zeros
(00000000000000000000)
• Last RAM row represented by twenty ones
(11111111111111111111)

Unitintro: ICT1001 Computer Systems 2009


29
Modern CPUs
• Developers
• Intel has dominated the industry with its CPUs and
motherboard support chips.
• Modern Intel processors include Core, Pentium, Celeron,
Atom, and Xeon brands.
• AMD has kept competition in the CPU market.
• While Intel holds the most market share, AMD provides
quality CPUs at competitive prices.

Unitintro: ICT1001 Computer Systems 2009


30
Modern CPUs (continued)
• Early Intel and AMD CPUs were identical; but
they are no longer interchangeable.

Figure 4.19 Identical Intel and AMD 486 CPUs from the early 1990s

Unitintro: ICT1001 Computer Systems 2009


31
Model Names
• Intel and AMD differentiate product lines by
using different product names, based on the
target market.
Table 4.1 Current Intel and AMD Product Lines and Names
Market Intel AMD
Mainstream and Core i7/i5/i3 A-Series, FX
enthusiast desktop
Budget desktop Pentium, Celeron Sempron, Athlon
Portable/Mobile Core i7/i5/i3 (mobile), A-Series
Core M, Atom
Server Xeon Opteron
Unitintro: ICT1001 Computer Systems 2009
32
Code Names
• Both companies use code names to keep track
of different variations within models.
• CPUs labeled as the same model may have CPUs
inside that are very different from earlier versions
of that model.

Figure 4.20 Same branding,


different capabilities

Unitintro: ICT1001 Computer Systems 2009


33
Desktop Versus Mobile
• Mobile devices need to consume as little
electricity as possible.
• Less electricity consumption extends the
battery charge and creates less heat.
• Both manufactures have created both mobile
and desktop versions of their CPUs.

Unitintro: ICT1001 Computer Systems 2009


34
Desktop Versus Mobile (continued)
• Saving energy by making the CPU run more
slowly when demand is light is called throttling.

Figure 4.21 Desktop vs. mobile, fight!

Unitintro: ICT1001 Computer Systems 2009


35
Technology
• Ways CPUs have been improved
• Clock multipliers
• 64-bit processing
• Virtualization support
• Parallel execution
• Multicore processing
• Integrated memory controller (IMC)
• Integrated graphics processing unit (GPU)
• Security Unitintro: ICT1001 Computer Systems 2009
36
Clock Multipliers
• All modern CPUs run at some multiple of the
system clock speed.
• In early computers, the CPU ran at the same
speed as the bus.
• Designers discovered that the CPU could run faster
than other chips on the motherboard.
• Technicians had to set jumpers or dual in-line
package (DIP) switches on older motherboards to
configure the multiplier.
Unitintro: ICT1001 Computer Systems 2009
• Now the motherboard is automatically
37 configured
Clock Multipliers (continued)

Figure 4.22 CPU-Z showing the clock speed, multiplier,


and bus speed of a Core i7 processor hardly breaking a sweat

Unitintro: ICT1001 Computer Systems 2009


38
Clock Multipliers (continued)

Figure 4.23 DIP switches on a motherboard


Unitintro: ICT1001 Computer Systems 2009
39
64-Bit Processing
• EDB and address-bus size increased in size.
• New technologies such as multimedia
extensions (MMX) and Streaming SIMD
Extensions (SSE) were added;
• Caused shift to 64-bit technology
• Most new CPUs support 64-bit processing
• Can run a compatible 64-bit operating system, such
as Windows 8.1, and 64-bit applications.
Unitintro: ICT1001 Computer Systems 2009
40
64-Bit Processing (continued)
• CPUs also still support 32-bit processing for
32-bit operating systems, such as Linux, and
32-bit applications.
• Primary benefit to moving to 64-bit
• Supports more than 4 GB of memory – up to 16 EB
(Exabyte)

Unitintro: ICT1001 Computer Systems 2009


41
Virtualization Support
• Modern CPUs have built-in support for running
more than one operating system at a time.
• Enables hardware-based virtualization support
• Makes virtualization easier and more
resource-efficient

Unitintro: ICT1001 Computer Systems 2009


42
Parallel Execution
• Modern CPUs process multiple commands and
parts of commands in parallel execution.
• Older CPUs processed in a linear fashion.
• CPUs accomplish parallelism through:
• Multiple pipelines
• Dedicated cache
• The capability to work with multiple threads or
programs at one time
Unitintro: ICT1001 Computer Systems 2009
43
Pipelining
• Pipelining—CPU takes at least four steps
(stages)
• Fetch: Get the data from the EDB
• Decode: Figure out what type of command needs
to be executed
• Execute: Perform the calculation
• Write: Send the data back onto the EDB

Unitintro: ICT1001 Computer Systems 2009


44
Pipelining (continued)

Figure 4.24 Simple pipeline


Unitintro: ICT1001 Computer Systems 2009
45
Pipelining (continued)
• Current CPUs have many stages in pipeline
• Enables CPU to run more efficiently without
increasing the clock speed
• Current processors use multiple decode stages
to reduce pipeline stalls.
• Current CPUs offer multiple pipelines, allowing
the arithmetic logic unit (ALU) and the floating
point unit (FPU) to work at the same time.
Unitintro: ICT1001 Computer Systems 2009
46
Pipelining (continued)

Figure 4.25 Bored integer unit Figure 4.26 Multiple pipelines

Unitintro: ICT1001 Computer Systems 2009


47
Cache
• A cache reduces wait states by using built-in,
very high-speed RAM called static RAM
(SRAM).
• SRAM preloads as many instructions as possible.
• The cache on the CPU was called the L1 cache
because it was used first by the CPU.
• The cache on the motherboard was called the L2
cache, and used second by the CPU.
• Later added to CPU package
• Most newer CPUs include three
48
caches.
Unitintro: ICT1001 Computer Systems 2009
Cache (continued)
• The address bus and external data bus
(connecting the CPU, MCC, and RAM) were
lumped into a single term called the frontside
bus.
• The connection between the CPU and the L2
cache became known as the backside bus.

Unitintro: ICT1001 Computer Systems 2009


49
Cache (continued)

Figure 4.28 CPU-Z displaying the cache


Figure 4.27 SRAM cache
information for a Core i7 processor
Unitintro: ICT1001 Computer Systems 2009
50
Cache (continued)

Figure 4.29 Frontside and backside buses


Unitintro: ICT1001 Computer Systems 2009
51
Multithreading
• CPU simulates the actions of a second
processor
• Enhances efficiency
• Does not increase processing power
• Running multiple threads at the same time is
also called simultaneous multithreading or
Hyper-Threading.

Unitintro: ICT1001 Computer Systems 2009


52
Multithreading (continued)

Figure 4.30 Windows Task Manager with the Performance tab


displayed for a system running a Hyper-Threaded Pentium 4

Unitintro: ICT1001 Computer Systems 2009


53
Multicore Processing
• Dual-core architecture
• Multiple CPUs (or cores) combined into a single
chip, executing multiple threads at once
• Shared caches and RAM
• Multicore processing
• Multicore CPUs common today
• Cores work independently of the OS
• Differs from Hyper-Threading, in which the OS and
applications have to be written specifically to
Unitintro: ICT1001 Computer Systems 2009
handle multiple threads 54
Multicore Processing (continued)

Unitintro: ICT1001 Computer Systems 2009


55 of a Haswell Core i7
Figure 4.31 CPU-Z showing the cache details
Integrated Memory Controller
• Almost all current microprocessors have an
integrated memory controller (IMC)
• Moved from the motherboard chip into the CPU to
optimize the flow of information into and out from
the CPU
• Causes different CPUs to require different types
and capacities of RAM

Unitintro: ICT1001 Computer Systems 2009


56
Integrated Graphics Processing Unit
• Video processing portion of computer tasks
handled by the graphics processing unit (GPU)
• Can handle certain tasks much more efficiently
than the standard CPU
• Enhances computer’s overall performance
while reducing energy use, size, and cost
• Ideal for mobile devices

Unitintro: ICT1001 Computer Systems 2009


57
Security
• NX bit technology in all modern processors
• Enables CPU to protect certain sections of memory
• Stops malicious attacks from getting to essential
operating system files
• Known by different terms
• Microsoft – Data execution prevention (DEP)
• Intel – XD bit (eXecute Disable)
• AMD – Enhanced Virus Protection
• ARM – XN (eXecute Never)
• CompTIA – Disable execute bit Unitintro: ICT1001 Computer Systems 2009
58
Security (continued)

Unitintro: ICT1001 Computer Systems 2009


Figure 4.32 DEP in Windows 8.1
59
Selecting and Installing CPUs
• Techs face challenges of:
• Selecting the proper CPU
• Installing several types of processors
• Troubleshooting

Unitintro: ICT1001 Computer Systems 2009


60
Selecting a CPU
• Select a CPU the motherboard can support
• Intel or AMD
• If buying a motherboard with a CPU:
• Select CPU appropriate for the intended purpose
• Determine the type of socket on the
motherboard
• Check motherboard documentation or
manufacturer’s web site
• Learn which sockets go with which family of CPU
Unitintro: ICT1001 Computer Systems 2009
61
Selecting a CPU (continued)

Figure 4.33 Supported processors and socket type

Unitintro: ICT1001 Computer Systems 2009


62
Selecting a CPU (continued)

Table 4.2 Intel-based Sockets


Socket CPU
LGA 7751 Pentium 4, Celeron, Pentium 4 Extreme Edition, Core 2
Duo, Core 2 Quad, Xeon, and many others
LGA 11562 Core i3/i5/i7, Pentium, Celeron, Xeon
LGA 11553 Core i3/i5/i7, Pentium, Celeron, Xeon
LGA 13664 Core i7, Xeon, Celeron
LGA 20115 Core i7, Core i7 Extreme Edition, Xeon
LGA 11506 Core i3/i5/i7, Pentium, Celeron, Xeon
LGA 11517 Core i3/i5/i7, Pentium, Celeron, Xeon

Unitintro: ICT1001 Computer Systems 2009


63
Selecting a CPU (continued)

Table 4.3 AMD-based Sockets


Socket Pins CPU
AM31 941 Phenom II, Athlon II, Sempron, Opteron

AM3+ 942 FX

FM1 905 A-Series2

FM2 904 A-Series

FM2+ 906 A-Series

G34 1974 Opteron

C32 1207 Opteron

Unitintro: ICT1001 Computer Systems 2009


64
Installation Issues
• Pay careful attention to:
• CPU pins
• Power supply
• Adequate cooling
• Consider whether to leave CPU at stock settings
or overclock it

Unitintro: ICT1001 Computer Systems 2009


65
Socket Types
• Socket types
• Intel processors use a land grid array (LGA) package
• AMD CPU pins align with socket holes—a pin grid
array (PGA)
• CPUs and sockets keyed to help prevent
misalignment and incorrect insertion
• Zero Insertion Force (ZIF) sockets

Unitintro: ICT1001 Computer Systems 2009


66
Socket Types (continued)

Figure 4.35 AMD-based


socket without pins

Figure 4.34 Intel-based


socket with pins
Figure 4.36 Underside and top of a CPU
Unitintro: ICT1001 Computer Systems 2009
67
Socket Types (continued)

Figure 4.37 Moving the release arm Figure 4.38 Fully opened socket

Unitintro: ICT1001 Computer Systems 2009


68
Cooling
• CPUs heat up due to electrical power
consumption (wattage).
• Most CPUs use a combination of heat sink and
fan assembly to keep them within normal
operating temperatures.
Figure 4.39 Intel stock heat sink
and fan assembly

Unitintro: ICT1001 Computer Systems 2009


69
Cooling (continued)
• OEM CPU coolers
• Heat sink and fan assemblies included with a
retail-boxed CPU
• Specialized CPU coolers
• Third-party heat-sink and fan assemblies for a
variety of CPUs
• Usually exceed the OEM heat sinks in the amount
of heat they dissipate

Unitintro: ICT1001 Computer Systems 2009


70
Cooling (continued)

Figure 4.40 Cool retail heat sink


Unitintro: ICT1001 Computer Systems 2009
71
Cooling (continued)
• Liquid cooling works by running some liquid
(usually water) through a metal block that sits
on top of the CPU, absorbing heat.
• Apply a small amount of thermal paste
(thermal compound, heat dope, or nasty silver
goo) to the CPU before attaching the heat sink.
• Applying too much or too little can cause the CPU
to overheat and fail.
Unitintro: ICT1001 Computer Systems 2009
72
Cooling (continued)

Figure 4.41 Liquid-cooled CPU


Unitintro: ICT1001 Computer Systems 2009
73
Cooling (continued)

Figure 4.42 CPU fan power header on motherboard


Unitintro: ICT1001 Computer Systems 2009
74
Cooling (continued)

Figure 4.43 Applying thermal Figure 4.44 AMD stock heat-sink


paste and fan assembly

Unitintro: ICT1001 Computer Systems 2009


75
Cooling (continued)

Figure 4.45 Heat-sink and fan assembly


mounted to motherboard with screws
Unitintro: ICT1001 Computer Systems 2009
76
Overclocking
• For the CPU to work, the motherboard speed,
multiplier, and voltage must be set properly.
• Motherboard uses the CPUID functions to set these
options automatically.
• Some motherboards enable you to adjust these
settings.
• Some people intentionally run their systems at
clock speeds higher than the CPU was rated, a
process called overclocking, to enhance
Unitintro: ICT1001 Computer Systems 2009
performance. 77
Overclocking (continued)
• Intentional overclocking of a CPU immediately
voids most warranties.
• Can cause system instability, lockups, frequent
reboots, or damage, and may destroy CPU
• Overclocking is done through jumpers, CMOS
settings, or software configuration.
• Usually involves increasing the bus speed for
the system and increasing the voltage going into
the CPU
Unitintro: ICT1001 Computer Systems 2009
78
Overclocking (continued)

Figure 4.46 Manually overriding CPU settings in theUnitintro:


system ICT1001 Computer Systems 2009
setup utility
79
Overclocking (continued)
• In case you need to go back to CMOS defaults,
use the CMOS clear jumper setting from the
motherboard manual.

Unitintro: ICT1001 Computer Systems 2009


80 4.47 CMOS-clear jumper
Figure
Troubleshooting CPUs
• Overheating
• This condition can cause system to not start or to
lockup.
• Newer CPUs will usually shut themselves down
before overheating.
• Most heating problems are due to faulty
installation or environmental issues.
• Catastrophic failure
• Less common than overheating
Unitintro: ICT1001 Computer Systems 2009
81
Symptoms of Overheating
• Problems to address with a faulty installation.
• Too much thermal paste can impede the flow of
heat from the CPU to the heat sink.
• Not enough thermal paste can cause the CPU to
heat up and shut down.
• Failure to connect fan power to the motherboard
can cause CPU to heat up and shut down.
• Environmental heat or lack of adequate
ventilation
Unitintro: ICT1001 Computer Systems 2009
• Can cause CPU to heat up and 82
shut down
Catastrophic Failure
• Displays a proprietary crash screen
• Window’s Blue Screen of Death (Windows Stop
error)
• Spinning pinwheel on Mac OS X
• May cause PC to shut down or go black
• May burn up components

Unitintro: ICT1001 Computer Systems 2009


83
Catastrophic Failure (continued)

Figure 4.48 Blue Screen of Death


Unitintro: ICT1001 Computer Systems 2009
84
Beyond A+
Intel Core M
• Very low power (4.5 watts)
• Compared with mobile version of Core i7 at 57
watts
• Modest processing power – falls between Atom
and mobile Core i3
• Manufacturers can skip the fan
• Running in Apple MacBook

Unitintro: ICT1001 Computer Systems 2009


85

You might also like