Professional Documents
Culture Documents
2020
EDITION
2020
EDITION
2020
EDITION
1|Page
COMPUTER SCIENCE NOTES (ICS_PART-I)
2|Page
COMPUTER SCIENCE NOTES (ICS_PART-I)
• System Bus
• Expansion Bus
System Bus: It is used to connect main components of the computer. System
Bus connects the CPU to the main memory (RAM) on the motherboard. The
system bus is also called the front-side bus, memory bus, local bus, or host bus.
Expansion Bus: It is used to connect various peripheral devices (I/O devices) to
the CPU. It is also called I/O buses or external buses.
Types of System Bus: It is divided into three main categories.
• Control Bus
• Address Bus
• Data Bus
Control Bus: It is a bi-directional bus that carries control signals (Read, Write,
acknowledge) from one component to another. It specifies the type of
operation that is to be performed. The size of control bus is from 8-16 bits.
Address Bus: It is a uni-directional bus that carries addresses not data. It carries
address signal from CPU to read and write data in the memory.
An address is a unique ID of each component connected to the system bus. The
address bus consists of 16, 20, 24, 32 parallel signal lines.
Data Bus: It is a bi-directional bus that carries the actual data from one
component to another. There are 32 or 64 parallel lines of data bus.
The amount of data that a bus can transmit is called bus-width. A 64-line data
bus can transmit 64 bits (8 bytes) at a time.
3|Page
COMPUTER SCIENCE NOTES (ICS_PART-I)
___________________________*****xxxxx*****_______________________________
Base Register (BX): It is used to hold the address of the base storage location
from where the data were stored continuously. Base register value is used to
find the data that is required. It is of 16 bits and is divided into two 8-bit registers
BH and BL.
Bits 15……………………………….............0
16-bit BX Register
8-bit BH Register 8-bit BL Register
4|Page
COMPUTER SCIENCE NOTES (ICS_PART-I)
Special Purpose Registers: It is used to hold the state of a program. These are
used by control unit to control the operations of CPU and by the operating
system to control the execution of the programs. Following are the special
purpose registers.
i. Instruction Register (IR)
ii. Program Counter (PC)
iii. Memory Address Register (MAR)
iv. Memory Buffer Register (MBR)
Instruction Register (IR): Instruction register is used to store or hold the actual
instruction being loaded, decoded or executed currently. After loaded the
instruction from memory, it is decoded and then executed. It’s also called
Current Instruction Register (CIR).
Memory Address Register (MAR): It holds the address of the active memory
location. Suppose CPU wants to store some data in the memory or to read the
data from the memory. It places the address of the required memory location in
the MAR.
Memory Buffer Register (MBR): It holds the contents of data or instruction read
from, or written in memory. It means that this register is used to store
data/instruction coming from the memory or going to the memory.
Program Counter (PC): It holds the address of the next instruction to be fetched
and executed. When instruction is fetched, the value of PC is automatically
incremented by 1 and it points to the address of next instruction. It is also called
Instruction Pointer (IP).
___________________________*****xxxxx*****_______________________________
5|Page
COMPUTER SCIENCE NOTES (ICS_PART-I)
Operand Code: It defines the parameters of the action. It can be data or memory
address.
6|Page
COMPUTER SCIENCE NOTES (ICS_PART-I)
iii. Shift Instructions: These are used for transfer of bits either to the left
of right of an operand.
Examples: Logical Shift Right (SHR), Logical Shift Left (SHL)
Program Control Instructions: These are used to change the flow of a program
or in other words it changes the address value in the Program Counter (PC)
register.
Examples: JMP, LOOP
a) JMP: It is used to jump from one memory location to another memory
location or from one part of a program to another part of the program.
b) LOOP: It is used when number of statements are to be repeated.
___________________________*****xxxxx*****_______________________________
Op-Code
Op-code Operand
7|Page
COMPUTER SCIENCE NOTES (ICS_PART-I)
___________________________*****xxxxx*****_______________________________
8|Page
COMPUTER SCIENCE NOTES (ICS_PART-I)
___________________________*****xxxxx*****_______________________________
9|Page
COMPUTER SCIENCE NOTES (ICS_PART-I)
Memory Unit RISC has no memory unit and CISC has a memory unit to
uses a separate hardware to implement complex
implement instructions instructions
X
AJAB NOOR
Lecturer in Computer Science, GPGC Bannu
10 | P a g e