Cpu Final Notes
Cpu Final Notes
Cpu Final Notes
Lec. (4)
IMSEC, GHAZIABAD
Dept of MCA
The processor acts as the controller of all actions or services provided by the system.
Processor actions are synchronized to its clock input. A clock signal consists of clock cycles.
The time to complete a clock cycle is called the clock period. Normally, we use the clock
frequency, which is the inverse of the clock period, to specify the clock. The clock frequency
is measured in Hertz, which represents one cycle/second. Hertz is abbreviated as Hz.
Usually, we use mega Hertz (MHz) and giga Hertz (GHz) as in 1.8 GHz Pentium. The
processor can be thought of as executing the following cycle forever:
1. Fetch an instruction from the memory,
2. Decode the instruction (i.e., determine the instruction type),
3. Execute the instruction (i.e., perform the action specified by the instruction).
Registers are small amounts of high-speed memory contained within the CPU. They are
used by the processor to store small amounts of data that are needed during processing,
such as:
the address of the next instruction to be executed
the current instruction being decoded
the results of calculations
Different processors have different numbers of registers for different purposes, but most
have some, or all, of the following:
program counter
memory address register (MAR)
memory data register (MDR)
current instruction register (CIR)
accumulator (ACC)
(The register set differs from one computer architecture to another. It is usually a
combination of general-purpose and special purpose registers. General-purpose registers are
used for any purpose, hence the name general purpose. Special- purpose registers have
specific functions within the CPU. For example, the program counter (PC) is a special-
purpose register that is used to hold the address of the instruction to be executed next.
Another example of special-purpose registers is the instruction register (IR), which is used to
hold the instruction that is currently executed. Figure 1 shows the main components of the
CPU and its interactions with the memory system and the input/output devices.)
Memory System
Instructions Data
Input / Output
Figure 1: Central processing unit main components and interactions with the memory
and I/O.
3) Control Unit
The CU provides several functions: