Department of Computer Science
Department of Computer Science
1 Lecture # 2
Basic Computer Organization
University of Gujrat
2 Basic Computer Organization
University of Gujrat
I/O
Interconnection between
3
Components
University of Gujrat
4 Interconnection between Components
The processor performs an operation on data, which resides
in memory.
A mechanism is required for the processor to read data
from the memory.
Processor
Memory Data
Operation
University of Gujrat
5
Address, Data and Control Buses
There must be a mechanism to inform memory that we want
to do the read operation
Control Bus
There must be a mechanism to inform memory that we want
to read precisely which element
Address Bus
There must be a mechanism to transfer that data element
from memory to processor
Data Bus
University of Gujrat
6 Bus
The process may be able to communicate with all the devices. The devices are
connected together by communication channel called a BUS.
A bus is composed of a set of communication lines or wires.
It is used to move large amount of bits in form of electrical pulses from a
specified source to a specified destination.
University of Gujrat
7 Control, Address and Data Buses
The group of lines that carry control information from the control unit to the other units is
the Control Bus
The group of lines that carries the address information is the Address Bus
The group of wires or lines that moves data between the different components is the Data
Bus
For e.g.
If the processor wants to read data from the address ‘135Fh’ of memory
135Fh
Address Bus
2
Processor Data Bus
Memory
Read
University of Gujrat Control Bus
8 Control, Address and Data Buses
Address Bus
Data Bus
Processor Memory
Control Bus
University of Gujrat
9 What do buses look like?
University of Gujrat
11 Memory Byte
Address Contents
Memory circuit element can store one bit of data.
Memory circuits are organized into groups that can
store 8 bits of data called Memory Byte.
Each memory byte is identified a number that is
called its Address. 4 01011011
Contents of Memory Byte are always 8 bits but the
3 11001001
number of bits in an address depends upon the
processor. 2 01011011
1 01000010
For e.g.
0 00011000
Intel 8086 microprocessor assigns a 20-bit address
University of Gujrat
12 Memory Word
University of Gujrat
13 Memory Operations
University of Gujrat
14 RAM and ROM
There are two kinds of memory circuits:
1. Random Access Memory (RAM)
2. Read Only Memory (ROM)
RAM ROM
RAM locations can be Read and Written ROM location can only be Read
Volatile Non-Volatile
Programs instructions and data are Used by manufactures to store system
normally loaded into RAM programs. ROM based programs are
known as Firmware
University of Gujrat
15
CPU Organization
University of Gujrat
16
CPU
Brain of the computer
Controls the computer by executing programs stored in memory
Each instruction executed by it, is a bit string
Instructions performed by a CPU is called the Instruction Set.
Instruction set for each CPU is unique.
There are two functional units:
1. Execution Unit (EU)
2. Bus Interface Unit (BIU)
University of Gujrat
17
Executes instructions
Contains circuits called Arithmetic and Logic Unit
Contains 8 registers for storing data
AX, BX, CX, DX, SI, DI, BP and SP
Contains temporary registers for holding operands for the ALU
FLAG registers whose individual bits reflect the result of a
computation
University of Gujrat
19
Bus Interface Unit (BIU)
University of Gujrat
20
Instruction Execution Cycle
(Fetch-Execute Cycle)
University of Gujrat
21 Fetch-Execute Cycle
Fetch
Execute
University of Gujrat
THE END
22
-------------------------------------------------------------------------------------------------------------------------
University of Gujrat