cpu

28
Central Processing Unit

Upload: muhammad-ramzan

Post on 24-May-2015

4.096 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Cpu

Central Processing Unit

Page 3: Cpu

Introduction, Components,

Function & Operation

Page 4: Cpu

Introduction

CPU is the "brain" of the computer, it reads and executes program instructions, performs calculations and makes decisions.

The CPU is responsible for storing and retrieving information on disks and other media, It controls all internal and external devices, performs arithmetic and logic operations.

Page 5: Cpu

Brief History

CPU history starts in 1971, when Intel, for the first time combined multiple transistors to form a Central Processing Unit (Microprocessor) named Intel 4044.

After the 8 years first Personal Computer was introduced.

Today there are several different manufactures of computer processors. However Intel and AMD are the leaders in the PC market.

Page 6: Cpu

Components

&

Function

Page 7: Cpu

CPU Registers Registers are a group of circuits used for

memory addressing, data operation and processing. Some of the registers are general purpose and some are reserved for certain functions.

Accumulator register is special data register stores the result of the last processing step of the ALU.Program counter (PC): Contains the addresses and status of an instructions. This CPU register always contains the memory address where the next instruction to be performed. Its contents is copied into the MAR before an instruction is fetched from the main memory.

Instruction Register (IR) - A special register that holds sequence of instructions to be performed.

Page 8: Cpu

CPU Registers

Memory Registers are also known as main memory, main store, central memory, immediate access memory.It is part of the CPU registers where data and instructions are held.

Memory Buffer Register (MBR) This register serves as an interface between the CPU and main memory, anything needed by the CPU (instruction or data) is first placed here before it goes to its final destination.

Memory Address Register (MAR) – used when another instruction is needed in the IR, or a value is to be loaded into the Accumulator.

Read Only Memory (ROM) - Data is stored permanently inside this chip. It can't be removed.

Page 9: Cpu

CPU RegistersData registers is basically used to store data. Index register used to store the index of memory address. Condition registers are used to determine whether this instruction should execute or not.

Floating point registers are the type of data register that store floating point numbers. Constant registers are used to store read only values. Special purpose register is used to store the status of the program. It consist of program counter, stack pointer and status registers.Storage register: holds the information on its way to and from the main memory.

Input/output register: communicates with the input/output devices.General purpose register hold the data and addresses.

Page 10: Cpu

Clock Pulses

The CPU is driven by one or more repetitive clock circuits that send a stream (series) of pulses throughout the CPU’s circuitry, The CPU uses these clock pulses to synchronize its operations.

Clock pulses are measured in Hertz, or number of pulses per second. For instance, a 2-gigahertz (2-GHz) processor has 2 billion clock pulses passing through it per second.

Clock pulses are called the speed of a processor.

Page 11: Cpu

Data Width

If the data is 8-bit ALU then it canadd/subtract/multiply/etc. two 8-bit numbers,

while a 32-bit ALU data can manipulate 32-bit numbers. An 8-bit data would have to execute four instructions to add two 32-bit numbers, while a 32-bit ALU can do it in one instruction.

MIPS Stands for "millions of instructions per second" and

is a rough measure of the CPU speed.

Page 12: Cpu

Math coprocessors were additional chips. This additional coprocessors allow the hardware for floating-point math. Math coprocessors will speed your computer's overall processing when utilizing software applications.

MATH CO-PROCESSORS

Page 13: Cpu
Page 14: Cpu

HOW CPU WORKING

Page 15: Cpu

Memory Unit

 The Memory Unit is the part of the computer that holds data and instructions for processing, Although it is closely associated with the CU but is separate from it.

Memory associated with the CPU is also called primary storage, main storage, internal storage and main memory.

When we load software from a floppy disk, hard disk or CD-ROM, it is stored in the Main Memory.

Page 16: Cpu

Memory Unit

 There are two types of computer memory inside the computer, RAM and ROM.

 Random Access Memory (RAM)This is the main store and is the place where the programs and software we load gets stored. When the CPU runs a program, it fetches the program instructions from the RAM and carries them out.

If the CPU needs to store the results of calculations it can store them in RAM.

When we switch a computer off, whatever is stored in the RAM gets erased.

Page 17: Cpu

Memory Unit

 Read Only Memory (ROM)The CPU can only fetch or read instructions from ROM. It comes with instructions permanently stored inside and these instructions cannot be over-written by the computer's CPU.

ROM memory is used for storing special sets of instructions which the computer needs when it starts up.

When we switch the computer off, the contents of the ROM does not become erased but remains stored permanently.   

Page 18: Cpu

Cache Memory

Cache memory is extremely fast memory that is built into a computer’s CPU, or located next to it on a separate chip.

The CPU uses cache memory to store instructions that are repeatedly required to run programs, improving overall system speed.

A cache is a temporary storage area where frequently accessed data can be stored for rapid access.

Page 19: Cpu

 Control Unit

Control Unit (CU) - That part of the computer is designed to decode program instructions held in the main memory using IR, It access instructions in sequence, interprets them and then directs their implementation whatever stored in program instructions register.

The CU must communicate with both the ALU and MU.

The CU handles all peripheral and auxiliary storage devices linked to the computer.  

Page 20: Cpu

Arithmetic Logic Unit

Arithmetic and logic unit (ALU) is the part where actual computations take place. It consists of circuits which perform arithmetic operations (e.g. addition, subtraction, multiplication, division) over data received from memory and capable to compare numbers.

The ALU executes both arithmetic and logical operations. Arithmetic Operations include addition, subtraction, multiplication and division. Logical Operation compare numbers, letters and special characters.

The Accumulator Register is used to accumulate results. It is the place where the answers from many operations are stored temporarily before being put out to the computer's memory.

Page 21: Cpu
Page 22: Cpu

Operation

Page 23: Cpu

CPU as termed computer brain or powerful calculator, is executes a sequence of stored instructions called a program, This program is in the form of numbers which is placed in computer memory.

There are four phases of CPU Operation

1. Fetch instruction

2. Decode instruction

3. Execute instruction

4. Result

CPU Operation

Page 24: Cpu

Fetch instruction :

Fetch is dealing with retrieving an instruction from main memory.

after an instruction is fetched, the PC is incremented in memory locations.

Decode :

Decoder fetches data is broken up into parts which are related to other portions of the CPU, this is termed as opcode, indicates which operation to perform.

CPU Operation

Page 25: Cpu

Execute :

After decode steps, the execute step is performed.

During this step, various portions of the CPU are connected so they can perform the desired operation.

Result :

The final step is returns (writeback) the results of the executed step will be kept in memory registers and then extends to output devices for display

CPU Operation

Page 26: Cpu

Pentium

&

MMX Technology

Page 27: Cpu

Pentium & MMX Technology In October 1996 Intel released the Pentium MMX with the

same basic micro architecture combined with MMX instructions, larger caches, and some other enhancements,

Pentium MMX has New design, adding some enhancements and new capabilities over "classic" Pentium in the same chip.

Difference between the Pentium with MMX and the Pentium Classic is the inclusion of the MMX instruction set extension.

Page 28: Cpu

Pentium & MMX Technology

Running software or multimedia that is designed for MMX on a Pentium MMX will result in a significant increase in performance over the regular Pentium.

Running non-MMX software on the MMX chip results in an improvement of about 20% over a regular Pentium of the same clock speed and enhancements in cache memory.