Introduction To Computer Architecture
Introduction To Computer Architecture
Computer Organization-CPU
Computer Architecture-Microprocessor
MEMORY-
WORKING MEMORY-RAM
RELOCATABLE
Process management:
OR
States of Process---
Running----terminating (final
Components of CPU:
1. Control Unit
2. ALU
3. Registers
1. Control Unit:
The control unit is necessary if the CPU is to function efficiently and
information/data is to be transferred between the CPU and other
devices. It does not perform the actual processing of data, but
manages and coordinates the entire computer system, including the
input/output devices. It is the brain of the computer. It is responsible
3. Registers
It is the memory cell used to store intermediate results obtained
during the execution of instructions. There are three types of
registers available with CPU.
a. Accumulator register
b. General Purpose register
c. Special purpose register
a. Accumulator register
It is used for temporarily storing the intermediate result of ALU
part of operation.
A=A+1 i.e. counter variable
S=S+A i.e. accumulator variable
For (A=1;A<=10;A++)
Print A
S=S+A;
Print S
S=0 Accumulator variable
A=1 to 10 Counter variable
AC ALU
S=55 Adder---A=10
S=S+A
Subtract or
Multiplier
Divide
what memory locations the stack is already filled up. In other words,
it indicates from which memory location onward the stack is vacant
for further storage.
iii. Status Register
The status register is also known as condition code or flag register. It
holds 1-bit flag to indicate certain conditions that arise during ALU
operations. Some of the status flag registers shown by computer are
as follows:
Carry-It indicates whether there is overflow or not.
Zero- It indicates whether the result is zero or nonzero.
Sign- It indicates whether the result is positive or negative.
Parity- It indicates whether the result contains odd number of 1s or
even number of 1s.
e.g.
EVEN PARITY: 1 0111000
ODD PARITY: 0 0111000
iv. Instruction Register
It holds an instruction until it is decoded. If there is more than one
CPU, then instruction register is also available as per availability of
CPU.
v. Index Register
Index registers are used for addressing. It is responsible for
generating the effective address of the instruction during execution
of an instruction. The address of an operand is the sum of the
contents of the index register and constant. This constant added to
the contents of index registers to form the effective address, i.e. the
address of the operand. It is automatically incremented or
decremented.
INSTRUCTION: A*B+C
AB*C+
AC ---- A
ALU-MULTIPLIER-B
PCR-holds the address of the next instruction to be
executed inside the system.
int a,b,c,d,e,f,g,h,i,j;
int a(10);
or
dim a(10) as Integer
dim i as Integer
Base Address=Address of FIRST element i.e. a(0)=1000
1000=a(0)=12
1002=a(1)=23
1004=a(2)=34
1006=a(3)=45
1008=a(4)=56
1010=a(5)=21
1012=a(6)=78
1014=a(7)=89
1016=a(8)=98
1018=a(9)=100
Sum=0
for(int i=0;i<10;i++)
scanf(“%d”, &a*i+);
sum=sum+a[i];
printf(“%d”, a*i+);
sum=0
for i=0 to 9
input a(i)
sum=sum+a(i)
next i
print sum
Address of a(1)
=base address+ 2*1
=1000+2*1
=1002
Address of a(5)
=base address+ 2*5
=1000+10
=1010
Microprocessor- Introduction
Microprocessor is an electronic chip that functions as the central
processing unit (CPU) of a computer. Microprocessor-based system
with limited resources is called microcomputer.
Available with almost all consumer electronic devices such as:
Computer printers
Washing machines
Mobile phones
Fax machines
Photocopiers
Advance applications such as radar, satellites, and flights.
1 byte= 8 bits
Volatile means that the contents of the memory are erased when
the power to the chip is disrupted. The access of the individual
memory location can be done randomly.
SRAM: Static Random Access Memory chips keep the data stored in
it as long as power is available. There is no need for refreshing. It is
faster than DRAM.
Input device: The devices that are used for providing data and
instructions to the microprocessor or microcomputer are called input
devices.
Output device: The devices that are used for transferring data out of
the microprocessor or microcomputer are called output devices.
ADDRESS BUS
DATA BUS
CONTROL BUS
BUS: It is set of wires used for transfer the contents
(i.e. data address or control signals) from one location
to another.
Classification of microprocessors
Microprocessors can be classified based on-
1. Size or Specification
2. Application
3. Hardware and Architecture
1. Size or Specification
Based on the size of the data that the microprocessor can
handle, they are classified as-
4-bit, 8-bit, 16-bit, 32-bit, 64-bit and 128-bit
microprocessors.
2. Application
Based on the Application of the processors, they are
classified as follows:
a. General-Purpose Microprocessors
b. Microcontrollers
c. Special-Purpose Microprocessors
a. General-Purpose Microprocessors
Those processors that are used in general computer
system integration and can be used by the programmer for
any application comes under General-Purpose
Microprocessor category. e. g. Intel 8086 and its family.
b. Microcontrollers
It is a microprocessor chips with built-in hardware for the
memory and ports. These chips are programmed by the
user for any generic control application. e.g.
microcontrollers are used in computer keyboards,
monitors, printers, copiers, fax machines, and telephone
systems etc.
c. Special-Purpose Microprocessor
It is designed specifically to handle special functions
required for an application. Digital Signal Processors (DSP)
is example of special-purpose microprocessors. e. g. GPU
(Graphics Processor Unit), FPU (Floating Point Unit) etc.
3. Hardware and Architecture
Based on the hardware and architecture of the processors,
they are classified as follows:
a. RISC (Reduced Instructions Set Computers ) Processors
b. CISC (Complex Instructions Set Computers) Processors
c. VLIW (Very Large Instruction Word) Processors
d. Superscalar Processors
e. EPIC (Explicit Parallel Instruction Computing)
a. RISC Processors
It supports limited machine language instructions and
executes programs faster than CISC processors.
b. CISC Processors
G. By: Amit Kumar Shukla, CIMAGE GROUP OF INSTITUTIONS, PATNA Page 17