meljun cortes meljun computer organization_lecture_chapter3
TRANSCRIPT
MicroprocessorsChapter 3
MELJUN CORTESMELJUN CORTES
OverviewIn this chapter, you will learn how to
Identify the core components of a CPUDescribe the relationship of CPUs and RAMExplain the varieties of modern CPUsIdentify specialty CPUsInstall and upgrade CPUs
Central Processing Unit (CPU)Core Components
ConceptsThe CPU (Central Processing Unit) works as a
very powerful calculator
CPUs are not very smart…just very fast at manipulating zeroes and ones
Man in the BoxVisualize 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 we communicate with him?
We need some way to talk to the guy inside the box
Is anyone out there?
Talking to the ManImagine 16 lights
8 on the inside and 8 on the outsideWhen an inside light is on, the corresponding
outside light is on. We can switch these lights on and off.
This communication system is like the external data bus
Talking to the ManIn reality, a lot of little wires flash on or off
Voltage is applied or notRepresented not as on, on, off, off…
but as 1, 1, 0, 0…
On
1
Off
0
On
1
Off
0
On
1
Off
0
On
1
On
1
External Data Bus The CPU communicates with the outside world
using the external data bus (EDB)
Instead of light bulbs, the EDB is made up of tiny wires
The state of a wire is expressed in a binary format, with zeroes and ones
Each discrete setting (series of zeroes and ones representing the state of the wires) of the EDB is a line of code in a program
Registers Inside the box are registers (temporary storage
locations)
The four general-purpose registers found in all CPUs are AX, BX, CX, and DX
10000101
00110101
11001001
10100001
CodebookThe man in the box needs one more tool: the
codebook or instruction set Called machine languageOne command is a line of codeThe complete set of commands for a processor
is its instruction set
Place AX on EDBAdd AX to BX & store in AXStore next line in BXStore next line in AXMeaning
1011 0000
1000 00001001 0000
1100 0000
Instruction
Codebook (Instruction Set)
Place AX on EDBAdd AX to BX & store in AXStore next line in BXStore next line in AXMeaning
1011 0000
1000 00001001 0000
1100 0000
Instruction
Place AX on EDB1100 0000Instruction (add AX and BX and place in AX)1011 0000Data (number 2)Instruction (store data in BX)Data (number 1)Instruction (store data in AX)
1001 0000
1000 00000000 0001
0000 0010
ClockThe CPU does no work
until told to—even though data may be on the EDB
You need a buzzer to tell the man in the box to startThis is referred to as a
clockA clock is actually a
stream of pulses
zz
10000101
00110101
Time to work
10000101
00110101
Clock A clock cycle is the time taken by the special
wire to charge upThe CPU needs at least two clock cycles to act
on each commandA cycle is one complete up and down segment
of the sine wave
The maximum number of clock cycles that can be handled by the CPU is called the clock speed
System Crystal The system crystal defines the speed at which
the CPU and the rest of the PC operateQuartz oscillator, usually soldered to the
motherboard
Overheating results from overclocking the CPU (running it faster than its maximum clock speed)
In SummaryThe CPU is like a man in a boxThe external data bus gets data in and out of the
CPURegisters are used as temporary storage inside the
CPUThe instruction set is like a codebook The clock defines the speed of the CPU
10000101
00110101
11001001
10100001
Memory
Memory Memory is a device that holds binary dataMemory was first stored on paper cards and then on
magnetic cards and magnetic tapesProblems
Serial accessSlow
Random access memory (RAM) to the rescue!
RAMRAM is organized similar to a spreadsheet
Data can be read or written to by addressing the RAM location
Typically represented as KB, MB, or GB
Volatile—zeroes outwhen power lost
Memory Controller ChipThe memory controller chip (MCC) is a device
that facilitates the flow of data from the RAM to the CPU
MCC
Address Bus The address bus
enables the CPU to control the MCC
Another set of wires in addition to the external data bus
Used by the CPU to tell the Northbridge which line of code it wants from RAM
MCC
Address Bus 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
combinations (1,048,576 or 1 MB)
Many current CPUs use 36 wires, which provide 236 combinations (68,718,476,736 or 64 GB)
TerminologyBits are represented as b (i.e., Kb)Bytes are represented as B (i.e., KB)
240
230
220
210
1,099,511,627,776 about 1 trillion
1,073,741,824 about 1 billion
1,048,576 about 1 million
1024 about 1000
Tera
Giga
Mega
Kilo
240
230
220
210
G
K
M
T
Decimal Compared to Binary
22 21 20
4 2 1
643 Decimal102 101 100
100 10 1
6 4 3 0 1 1
101 Binary
600 + 40 + 3 643
4 + 0 + 1 + 5 Decimal
Modern CPUs
CompTIA A+Essentials
CPU OverviewSeveral specification are used to describe and
compare CPUs:Make (Intel, AMD) Model (Pentium, Athlon, etc.) Packages, or how it’s mounted (PGA, SEC, SEP)External speed (speed of crystal)Multiplier (applied to crystal)Cache (L1 and L2) Internal speed (speed when crystal multiplied)PipeliningHyper-threading
We’ll cover these in older and newer CPUs
ManufacturersTwo main CPU makers
IntelAMD
CPUs might look similar, but they are not interchangeable
Common CPU Packages
• Pin grid array (PGA)– Most common– Number of pins vary by processor– Plugs into sockets that vary by processor
• Single edge cartridge (SEC)– Single edge processor (SEP) is similar– Processor mounted on board– Board plugs into motherboard
• Zero insertion force (ZIF)– Allows processor to be easily inserted– Arm locks processor in place
Pentium CPU—The Early Years
CPU makers have added a large number of improvements over the yearsLarger external data busesLarger address busesFaster clock speeds
Intel introduced the Pentium CPU in the early 1990s32-bit registersSpeeds up to 300 MHzAbility to run multiple programs at onceAccess super-fast cache RAMProcesses two or more lines of code at the same
time
32-bit AddressingCurrent operating systems are referred to as
32-bit (232)Can directly address 4 GB of memory
Early Pentiums had 32-bit address bus
Newer CPUs have 36-bit address bus236 allows addressing 64 GB of RAMSome 32-bit operating systems address the
extra memory via “extensions”Memory is swapped in and out of the 4 GB base
as needed
PipeliningA pipeline is a series of steps taken by the CPU to
process a command
Pipelining is the process of processing more than one command at a time through the use of separate sets of circuitryWorks like an assembly lineCommands go through the processor on a
“conveyer belt”Enables the processor to work on more than
one thing at a time
CacheCache is separate storage
area used for quick access of data
CPU runs faster than RAM
Using a faster RAM cache close to the CPU helps the CPU run without waiting
L1: close to the CPU and fastest
L2: faster than RAM
1011 0101
1001 00011011 01100001 11011101 11011100 01111001 11111100 1010
RAM Cache
RAM
CPU
L2 Cache L2 was originally on the
motherboardReferred to as external
cacheNot uncommon on
today’s CPUs
Size of the cache varies from 0 to 1 MB
Clock Speed and Multipliers
• The clock is derived from the crystal– Referred to as external
speed
• Clock is multiplied and CPU runs at quicker speed– CPU runs at much quicker
multiplied speed• 66 MHz crystal • Sent through a 2X multiplier • Gives a 132 MHZ CPU
Original clock
Clock with 2x multiplier
Has twice as many cycles for CPU to operate with
CPU Voltages Older CPUs needed 5 volts
CPU voltage was reduced to 3.3 voltsLater improvements reduced voltage even
more with no single standardSmaller size resulted in lower voltage and
smaller chipsVoltage regulator module (VRM) is a small card
that enables a CPU to standardize voltage regulators
CPU reports voltage requirements with CPUID
Older CPUs
High-end systems
RemarksSocket 8Socket 7Socket 4, 5SocketPGAPGAPGAPackage
256 KB, 512 KB, 1 MB
L216 KB1x to 3x60–200 MHz50–66 MHz
Early Pentiums
16 KB1.5x to 2x60–150 MHz50–75 MHz
AMD K5
2.5x to 3xMultiplier
60–66 MHzExt. speed166–200 MHzInt. speed
16 KBL1
Pentium Pro
ImprovementsOut-of-order processing
Enabled processors to predict data that was needed
90% accuracy in pulling the correct data
On-chip L2 cacheOn the same package, but not necessarily on
the same chip
Bus TypesFrontside bus
Address bus and external data bus are combined together between the CPU, MCC, and RAM
Backside busConnection between the CPU and L2 cache
Remember that L2 cache used to be external cache but is now internal to the CPU housing
CPU
L2 CacheRAMMCC
Frontside bus
Backside bus
Older CPUs
AMD & Intel Split
RemarksSocket 7Slot 1Socket 7SocketPGASECPGAPackage0 to 256 KB512 KBL2
32 KB2.5x to 4.5x166–200 MHz66–75 MHz
Later Pentiums
32 KB3.5x to 4.5x233–450 MHz66–100 MHz
Pentium II
3.5x to 5.5xMultiplier
60–100 MHzExt. speed200– 550 MHzInt. speed
32 or 64 KBL1
AMD K6
Pentium Improvements MMX (multimedia extensions)
Designed for graphical applications
Increased clocks and multipliersUp to 4.5x
Pentium IIFaster than Pentium Pro Used SEC
AMD K6Proprietary 3DNow!Requires a Super Socket 7
Older CPUs
Slot A7Slot 1, Socket 370
Slot 1, Socket 370
SocketSECSEC-2, PGASEP, PGAPackage512 KB256–512 KB0 to 128 KBL2
32 KB4x to 10.5x
266–700 MHz66 MHz
Intel Celeron (P II)
32 KB4x to 10x
450 MHz–1.2 GHz
100–133 MHz
Pentium III
5x to 10xMultiplier
100–133 MHzExt. speed500MHz–1GHz
Int. speed
128 KBL1
AMD Athlons
Older CPUs Celeron
Offshoot of Pentium II for the low-end PC
Pentium IIIIntel’s answer to 3DNow!
by AMD
AMD AthlonSEC package used slot A
More Current CPUs
49–10021–5738–75Wattage180 nm180 nm180 nmProcessWillametteThunderbirdCodename
Socket 423 or 478Socket ASocket ASocketPGAPGAPGAPackage256 KB64 KB256 KBL2
128 KB6.5x to 14x
650 MHz–1.4 GHz
100–133 MHz
AMD Athlon
128 KB6.5x to 13.5x
650 MHz–1.8 GHz
100 MHz
AMD Duron
13x to 20xMultiplier
100–133 MHzExt. speed1.3–2 GHzInt. speed
128 KBL1
Pentium 4
IT Technician
Processing and Wattage
CompTIA A+Technician
Processing and WattageWattage is a measure of power
Goal is to consume as little power as possiblewhile still having a powerful CPU
Solution: make it smaller so it takes less voltage;less voltage is less wattage
ProcessingMeasures thickness of wafersSome of today’s processors are 65 nanometers
About as thick as 455 hydrogen atomsOr 1/3077th of the width of a human hair
Hydrogen atom
Pentium CompetitorsAMD Athlon Thunderbird
Double-pumped frontside bus doubled the data rate without increasing the clock speed
Returned to PGA with Socket A
AMD DuronGeneric name given to all lower-end Athlon processorsAMD’s competitor to Intel’s Celeron for the low-end PC
Intel Pentium 4 (Willamette)Completely redesigned core called NetBurstUsed 20-step pipeline Quad-pumped frontside bus
More Current CPUs
49–7060–72Wattage150 nm180 nmProcessThoroughbredPalominoCodename
Socket ASocket ASocketPGAPGAPackage256–512 KB256–512 KBL2
128 KB13x to 16.5x1.3–2.2 GHz133 MHz
AMD Athlon
128 KB13x to 16.5x1.3–2.2 GHz166 MHz
AMD Athlon
Multiplier
Ext. speedInt. speed
L1
More Current CPUs
86~8445–68Wattage65 nm90 nm130 nmProcessCedar MillPrescottNorthwoodCodename
Socket 478 or 775Socket 478 or 775
Socket 478 or 775
SocketPGAPGAPGAPackage256, 512 KB256, 512 KB256, 512 KBL2
128 KB13x to 23x1.3–3.8 GHz100 MHz
Pentium 4
128 KB13x to 23x1.3–3.8 GHz133 MHz
Pentium 4
13x to 23xMultiplier
200 MHzExt. speed1.3–3.8 GHzInt. speed
128 KBL1
Pentium 4
Newer Processors
AMD Athlon XP (Palomino and Thoroughbred)Enhanced version of the Athlon core processor
Intel Pentium 4 (Northwood, Prescott, Cedar Mill)Increased frontside bus to 800 MHzIntroduced hyperthreading
HyperthreadingLooks like two CPUs
to the operating system
More Current CPUs
49–7060–72Wattage150 nm180 nmProcessThoroughbredPalominoCodename
Socket ASocket ASocketPGAPGAPackage256–512 KB256–512 KBL2
128 KB13x to 16.5x1.3–2.2 GHz133 MHz
AMD Athlon XP
128 KB13x to 16.5x1.3–2.2 GHz166 MHz
AMD Athlon
Multiplier
Ext. speedInt. speed
L1
More Current CPUs
2 MBL3
85–11560–70Wattage130, 90 nm130 nmProcessExtreme EditionThorton/BartonCodename
Socket 478 or 775Socket ASocketPGAPGAPackage
512 KB256, 512 KBL2128 KB10x to 16x1.6–2.2 GHz133, 166, 200 MHz
Athlon XP
14x to 17xMultiplier
200, 266 MHzExt. speed3.2–3.7 GHzInt. speed
128 KBL1
Pentium 4
Mobile ProcessorsMobile processors
For laptopsUse less power to overcome problems of heat
and power requirements
Utilize throttlingPreviously called system management mode
(SMM)Allows a CPU to slow down during low demand
timesIntel calls it SpeedStepAMD calls it PowerNow!
More Processors Intel Xeon processors
Series of powerful CPUsMassive L2 cachesXeon is codeword for high-endCan easily be used in symmetric multiprocessing
systems (multiple physical processors)Early Xeon used slotsLater Xeons went back to PGA packages
64-Bit Processors64-bit processing refers to a 64-bit address
busWe already had 64-bit external data buses
Intel Itanium processorsItanium was Intel’s first 64-bit chipItanium II is made for the PC
64-Bit ProcessorsAMD Opteron processor
Runs both 32-bit and 64-bit code
Athlon 64First desktop 64-bit processorBackward-compatible with 32-bit programsTwo main groups (130 nm and 90 nm)
AMD Sempron CPUsLess cache than the Athlon 64Offer a tradeoff between price and performance
Dual-core CPUsDue to practical limit of ~4 GHz in clock
speeds, alternatives were sought
Dual core features two CPUs on same chip
Pentium DAthlon Dual Cores
Dual-core CPUs
89–11095–130Wattage90 nm90, 65 nmProcess
Smtihfield/PreslerCodename
Socket 939 or AM2Socket LGA 775SocketPGA775 LGAPackageTwo 512 KB or 1 MBTwo 1 or 2 MBL2
Two 128 KB14x to 20x2.6–3.6 GHz166, 200 MHz
Pentium D
10x to 12xMultiplier
200 MHzExt. speed2–2.4 GHzInt. speed
128 KBL1
Athlon Dual Core
Intel Core CPUs
89–11095–130Wattage90 nm90, 65 nmProcess
YonahCodename
Socket 939 or AM2Socket LGA 775SocketPGA775 LGAPackageTwo 512 KB or 1 MBTwo 1 or 2 MBL2
Two 128 KB14x to 20x2.6–3.6 GHz166, 200 MHz
Intel Core
10x to 12xMultiplier
200 MHzExt. speed2–2.4 GHzInt. speed
128 KBL1
Intel Core 2
Installing CPUs
Why Replace a CPU?Cost
Chances are you’ll need to replace the motherboard as well as the CPU—is it worth it?
CoolingFaster CPUs will probably need better cooling
PerformanceFaster CPUs may not be the best answer to
speeding up your PCMany times you really need more RAM
The Right CPUConsult your motherboard manual
You need a CPU that will fit in the socket or slot on your motherboard
Buying a CPUMost stores will not accept
returnsRetail-boxed CPUs are genuine and come
with a fanLots of illegal CPUs on the market
CPU Installation Guidelines
Don’t touch the pins (ESD)
Match the notch and dot printed on the corners of the CPU…they must line upIncorrectly installing
your CPU may destroy the CPU and/or motherboard!
CPU Installation Guidelines
Use a heat sink compound
Install a fan on top of the CPU after the CPU has been inserted into the socket
Plugging in the CPU Fan
The Art of CoolingModern CPUs need to be
kept coolOEM fans are included in
retail-boxed CPUs
Specialized fans usually exceed OEM fans
Liquid cooling works by running a liquid (usually water) through a metal block that sits on top of your CPU to absorb heat
OverclockingOverclocking is running a CPU at a speed
higher than ratedVoids the warrantyBlack market exists