CA L3 Central Processing Unit
CA L3 Central Processing Unit
Functional Units
1. Processor
2. Memory
3. Input/Output
1
Three main units CPU, memory and I/O interconnected
through system bus .
System Bus
Input Output
Device Device
Keyboard Printer
Processor Memory
I/O
Devices
Figure 3.1 Functional Units of a simple computer with two I/O devices
2
Processor
4
Components of CPU
• Control Unit
• ALU
• Registers
5
Components of CPU
• Control Unit
Control Unit fetches the instructions
from the main memory and
determines their type.
6
Components of CPU
• ALU
The arithmetic and logic unit (ALU)
performs operations like addition,
subtraction, Boolean AND, OR etc.
that are needed to carry out
instructions.
7
Components of CPU
• Registers
Registers are a very high speed
memory within the CPU that stores
temporary results, data for
computation and certain control
information.
8
Organization of CPU based on
functions it performs
• fetch an instruction
• decode it
• execute it
9
Instruction Implementation
• An instruction cycle (also called fetch-and-
execute cycle, fetch-decode-execute cycle, or
FDX) is the basic operation cycle of a computer
• It is the process by which a computer retrieves a
program instruction from its memory, determines
what actions the instruction requires, and carries
out those actions.
• This cycle is repeated continuously by the CPU,
from bootup to when the computer is shut down.
10
Instruction Implementation
1. Fetch the instruction
• The CPU presents, on the address bus, the
value stored in the Program Counter.
11
Instruction Implementation
12
Instruction Implementation
13
Instruction Implementation cont.
5. Fetch data:
6. Execute instruction:
The CU passes the decoded information as
a sequence of control signals to the
relevant function units of the CPU to
perform the actions required by the
instruction such as reading values from
registers, passing them to the ALU to
perform mathematical or logic functions on
them
15
Instruction Implementation cont.
17