36
The Central Processing Unit: What Goes On Inside the Computer

Three Central Processing Unit

  • Upload
    misy

  • View
    9.681

  • Download
    1

Embed Size (px)

DESCRIPTION

 

Citation preview

Page 1: Three   Central Processing Unit

The Central Processing Unit:

What Goes On Inside the Computer

Page 2: Three   Central Processing Unit

CIS105 – Mesa Community College2

Objectives

Identify the components of the central processing unit and explain how they work together and interact with memory

Describe how program instructions are executed by the computer

Explain how data is represented in the computer Describe how the computer finds instructions and

data Describe the components of a microcomputer system

unit’s motherboard List the measures of computer processing speed and

explain the approaches that increase speed

Page 3: Three   Central Processing Unit

CIS105 – Mesa Community College3

Central Processing Unit

Complex set of electronic circuitry

Executes stored program instructions

Two parts Control unit Arithmetic/logic unit

(ALU)

Page 4: Three   Central Processing Unit

CIS105 – Mesa Community College4

The Control Unit Directs & coordinates Machine/Instruction Cycle

Fetching instruction Decoding Executing Storing/Write-back

MIPS (million instructions/sec.)

Must communicate with memory and ALU

Sends data and instructions from secondary storage to memory as needed

The Arithmetic/Logic Unit Arithmetic operations Comparison operations

Logical operations (and/or) Compare numbers, letters, or

special characters Tests for one of three

conditions• Equal-to condition• Less-than condition• Greater-than condition

Page 5: Three   Central Processing Unit

CIS105 – Mesa Community College5

How the CPU Executes Instructions

Four steps performed for each instruction Machine cycle: the amount of time needed

to execute an instruction • Personal computers execute in less than one

millionth of a second• Supercomputers execute in less than one

trillionth of a second

Each CPU has its own instruction set those instructions that CPU can understand

and execute

Page 6: Three   Central Processing Unit

CIS105 – Mesa Community College6

MachineCycle

The time required to retrieve, execute, and store an operation

Components Instruction

time Execution

time

Page 7: Three   Central Processing Unit

CIS105 – Mesa Community College7

Instruction Time

Also called I-timeControl unit gets

instruction from memory and puts it into a register

Control unit decodes instruction and determines the memory location of needed data

Execution Time

Also called E-timeControl unit moves

data from memory to registers in ALU ALU executes

instruction on the data

Control unit stores result of operation in memory or in a register

Page 8: Three   Central Processing Unit

CIS105 – Mesa Community College8

RISC Technology

Reduced Instruction Set Computing Uses a small subset of instructions Fewer instructions increases speed Drawback: complex operations have to be

broken down into a series of smaller instructions

Traditional processors use Complex Instruction Set Computing (CISC)

Page 9: Three   Central Processing Unit

CIS105 – Mesa Community College9

Computer Processing Speeds

Instruction speeds measured in fractions of seconds Millisecond: one thousandth of a second Microsecond: one millionth of a second Nanosecond: one billionth of a second

• Modern computers have reached this speed Picosecond: one trillionth of a second

Page 10: Three   Central Processing Unit

CIS105 – Mesa Community College10

Data Representation

Computers understand two things: on and off

Data represented in binary form Binary (base 2) number

system Contains only two digits,

0 and 1• Corresponds to two states,

on and off

Page 11: Three   Central Processing Unit

CIS105 – Mesa Community College11

The System Unit

Contains:ProcessorControl Unit

Motherboard Memory Module

Expansion Cards/Ports

Connectors

Page 12: Three   Central Processing Unit

CIS105 – Mesa Community College12

Motherboard aka System Board

Memory slots

Conne

ctor

s –CPU

Chi

ps

PCI expansion slots

ISA expansion slot

Page 13: Three   Central Processing Unit

CIS105 – Mesa Community College13

Microprocessor

Central processing unit etched on silicon chip Size: ½ inch or less

Integrated Circuit (IC) Contain tens of millions of tiny transistors Electronic switches/gates

Key components: Central processing unit Registers System clock

Page 14: Three   Central Processing Unit

CIS105 – Mesa Community College14

Types of Chips

Intel makes a family of processors Pentium processors in most PCs Celeron processor sold for low-cost PCs Xeon and Itanium for high-end workstations and

network serversOther processors

Cyrix and AMD make Intel-compatible microprocessors

PowerPC chips used primarily in Macintosh computers

Compaq’s Alpha microprocessor used in high-end servers

Page 15: Three   Central Processing Unit

CIS105 – Mesa Community College15

Data Storage and the CPU

Two types of storage: Primary storage (memory)

• Stores data temporarily• CPU refers to it for both program instructions

and data Secondary storage

• Long-term storage• Stored on external medium, such as a disk

Page 16: Three   Central Processing Unit

CIS105 – Mesa Community College16

Memory

Stored Program ConceptOperating system Application programsData processedBenchmarks

RAM (volatile) Register Dynamic (DRAM) Static (SRAM) Cache

• Frequently used instructions

ROM (non-volatile)CMOS (non-volatile)

Configuration info

Page 17: Three   Central Processing Unit

CIS105 – Mesa Community College17

Memory Addresses

Each memory location has an address A unique number, much

like a mailbox May contain only one

instruction or piece of data When data is written back

to memory, previous contents of that address are destroyed Referred to by number

Programming languages use a symbolic (named) address, such as Hours or Salary

Page 18: Three   Central Processing Unit

CIS105 – Mesa Community College18

Storage Sizes

Kilobyte: 1024 (210) bytes Memory capacity of older personal computers

Megabyte: roughly one million (220) bytes Personal computer memory Portable storage devices (diskette, CD-ROM)

Gigabyte: roughly one billion (230) bytes Storage devices (hard drives) Mainframe and network server memory

Terabyte: roughly one trillion (240) bytes Storage devices on very large systems

Page 19: Three   Central Processing Unit

CIS105 – Mesa Community College19

Registers

High-speed temporary storage areas Storage locations located within the CPU

Work under direction of control unit Accept, hold, and transfer instructions or

data Keep track of where the next instruction to

be executed or needed data is stored

Page 20: Three   Central Processing Unit

CIS105 – Mesa Community College20

Semiconductor Memory

Used by most modern computers Reliable, inexpensive, and compact Volatile: requires continuous electric current

• If the current is interrupted, data is lost CMOS (Complementary Metal Oxide

Semiconductor)• Retains information when power is shut down• Used to store information needed when the

computer boots

Page 21: Three   Central Processing Unit

CIS105 – Mesa Community College21

Random Access Memory

Data can be accessed randomly Memory address 10 can

be accessed as quickly as memory address 10,000,000

Types: Static RAM (SRAM)

Retains its contents with intervention from CPU

Dynamic RAM (DRAM) Must be continuously refreshed by CPU or it loses its contents

Packaged on circuit boards Single in-line memory

modules (SIMMS) Dual in-line memory modules

(DIMMS)Click Projector to Learn How toInstall Memory

Page 22: Three   Central Processing Unit

CIS105 – Mesa Community College22

Dynamic RAM

Must be continuously refreshed by CPU or it loses its contents

Used for personal computer memory Synchronous DRAM (SDRAM): faster type

of DRAM used today Rambus DRAM (RDRAM): faster than

SDRAM, will become more commonly used as price declines

Page 23: Three   Central Processing Unit

CIS105 – Mesa Community College23

Read-Only Memory

Contains programs and data permanently recorded into memory at the factory Cannot be changed by user Not volatile: contents do not disappear

when power is lost

Programmable ROM (PROM) chips Some instructions on chip can be changed

Page 24: Three   Central Processing Unit

CIS105 – Mesa Community College24

Flash Memory

Nonvolatile RAM Used in cellular phones, digital cameras,

and some handheld computers Flash memory chips resemble credit cards Smaller than disk drive and require less

power

Page 25: Three   Central Processing Unit

CIS105 – Mesa Community College25

Storage Devices

Long-term storage of memory Data not lost when computer shut down

Examples include hard drive, diskette, DVD-ROM, USB Flash Drive

Page 26: Three   Central Processing Unit

CIS105 – Mesa Community College26

Buses

• Parallel electrical paths that transport data between the CPU and memory Expansion System

Page 27: Three   Central Processing Unit

CIS105 – Mesa Community College27

Expansion Boards

Connect to expansion slots on motherboard Used to connect peripheral

devicesVideo/graphics card (adapter)Sound cardInternal modemPlug & PlayPC Card

(PCMCIA – Personal Computer Memory Card International Association)

Hot swap

Page 28: Three   Central Processing Unit

CIS105 – Mesa Community College28

Ports

External connectors to plug in peripherals such as printers

Two types of ports Serial: transmit data one bit at a time

• Used for slow devices such as the mouse and keyboard

Parallel: transmit groups of bits together side-by-side

• Used for faster devices such as printers and scanners

Page 29: Three   Central Processing Unit

CIS105 – Mesa Community College29

Cache

A temporary storage area Speeds up data transfer within computer Memory cache

• A small block of high-speed memory– Stores most frequently and most recently used data and

instructions

– Microprocessor looks in cache first (faster); if not there, it retrieves from memory

Processor cache• Internal (Level 1) cache built into microprocessor

– Fastest access, but highest cost

• External (Level 2) cache on separate chip• Incorporated into processor on some current microprocessors

Page 30: Three   Central Processing Unit

CIS105 – Mesa Community College30

Parallel ProcessingUsing multiple processors at

onceControl processor

divides problem into parts Each part sent to separate processor Each processor has its own memory Control processor assembles results

Some computers using parallel processing operate in terms of teraflops: trillions of floating-point instructions per second

Page 31: Three   Central Processing Unit

CIS105 – Mesa Community College31

Pipelining

A variation of traditional serial processingFeeds a new instruction into CPU at each

step of the machine cycle Instruction 2 fetched when instruction 1 is being

decoded, rather than waiting until cycle is complete

Page 32: Three   Central Processing Unit

CIS105 – Mesa Community College32

What is E-time?

What is pipelining?

What is a register?

Execution time Temporary

storage

What is CISC vs RISC?

CISC-ComplexRISC-Reduced Instruction

Set Computer

Page 33: Three   Central Processing Unit

CIS105 – Mesa Community College33

Terms to Know: Central Processing Unit

Arithmetic/logic unit (ALU) ASCII Binary system Cache memory CMOS Control unit CPU EBCDIC E-time Expansion board Flash memory I-time Machine cycle Memory Motherboard Non-volatile memory Parallel processing Pipelining

Plug and Play RAM Register ROM System unit USB Volatile memory

Page 34: Three   Central Processing Unit

CIS105 – Mesa Community College34

Questions?

?

? ???

Page 35: Three   Central Processing Unit

CIS105 – Mesa Community College35

If Asked, Can You….

Identify the components of the central processing unit and explain how they work together and interact with memory

Describe how program instructions are executed by the computer

Explain how data is represented in the computer Describe how the computer finds instructions and

data Describe the components of a microcomputer system

unit’s motherboard List the measures of computer processing speed and

explain the approaches that increase speed

Page 36: Three   Central Processing Unit

CIS105 – Mesa Community College36

Sources

Capron; Computers: Tools for An Information Age, 8th Ed. 2003

Pfaffenberger; Computers in Your Future 2003

Microsoft Clipart Webopedia