0% found this document useful (0 votes)
67 views

Module1 PartA Dr. Ilavarasi

The document provides an introduction to computer architecture and organization. It discusses how a computer system works, the components of a computer including the CPU, memory, and I/O devices. It also describes how programs are executed through different levels of language from high-level to machine code. The key components of a computer like registers, the ALU, control unit, cache, and main memory are explained. Different types of registers within the CPU and their roles are outlined.

Uploaded by

Sai Silesh
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
67 views

Module1 PartA Dr. Ilavarasi

The document provides an introduction to computer architecture and organization. It discusses how a computer system works, the components of a computer including the CPU, memory, and I/O devices. It also describes how programs are executed through different levels of language from high-level to machine code. The key components of a computer like registers, the ALU, control unit, cache, and main memory are explained. Different types of registers within the CPU and their roles are outlined.

Uploaded by

Sai Silesh
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 36

1

Introduction and Overview of


Computer Architecture
Module 1 Part A
Dr. Ilavarasi A K,
SCOPE, VIT Chennai

Dr. Ilavarasi A K, VIT Chennai


2

Outline
 Introduction to computer systems
 Overview of Organization and Architecture
 Functional components of a computer
 Registers and register files
 Interconnection architecture

Dr. Ilavarasi A K, VIT Chennai


3
Introduction to
computer systems
 A computer system is a electronic device
 Accepts digitized input information
o Process it according to a list of
internally stored instructions
o Produces the resulting output
information
• The list of instructions are called computer
program
• Internal storage is via computer Memory

Dr. Ilavarasi A K, VIT Chennai


Introduction to computer 4

systems
 An user interacts with computer system with the
help of application software
 Application software communicates with the
operating system and returns the results of
required operation

Dr. Ilavarasi A K, VIT Chennai


5
Hardware components

Dr. Ilavarasi A K, VIT Chennai


6

System Software
 Operating System
Interfaces between a user’s program and the
hardware and provides a variety of services and
supervisory functions
 Compilers
A program that translates high-level language
statements into assembly language statements
 Assembler
A program that translates assembly language
statements in to 1’s and 0’s

Dr. Ilavarasi A K, VIT Chennai


High level to Hardware Language 7

 If programmer writes, Add A,B


The compiler translate to a symbolic
language called as assembly language:
Mov A, R1
Add B,R1
Mov R1, C

 Assembler translates to binary language


that a machine understands and is called as
machine language, Eg. 1000110010100000

Dr. Ilavarasi A K, VIT Chennai


Power of abstraction 8

High level language Assembly language Binary machine


program in C program (for MIPS) language program (for
MIPS)
Dr. Ilavarasi A K, VIT Chennai
9

Computer Organization?

 Encompasses all physical/hardware


aspects of computer systems.
Eg., circuit design, control unit, memory
chip.
 How does a computer work?

Dr. Ilavarasi A K, VIT Chennai


10

Computer Architecture?

 Logical aspects of system


implementation as seen by the
programmer.
 Eg., instruction sets, instruction
formats, addressing modes.
 How do I design a computer?

Dr. Ilavarasi A K, VIT Chennai


11
Functional components of a computer
CPU
ALU

Control Unit
Input Data Data
Output

Registers

Data

Memory
Dr. Ilavarasi A K, VIT Chennai
12
Processor
ALU (Arithmetic & Logic Unit)
Most computer operations are executed in the ALU of the
processor
• Suppose: two numbers located in the memory are to
be added
• They are brought into the processor and the actual
addition is carried out by the ALU
• The sum may then be stored in the memory or
retained in the processor for immediate use
Control unit
 Coordinates the tasks between the computer
components like memory, ALU and I/O devices.
Registers
• Storage elements within the processor
• The data in this unit is collected from the higher
memory components (i.e. cache).
Dr. Ilavarasi A K, VIT Chennai
13
Main memory
 Large number of semiconductor storage cells
 Stores programs and data
 Two types
 Primary memory (RAM)
 Secondary memory (Magnetic disks & tapes
Optical disks(CD-ROMs), Flash memory
devices

Dr. Ilavarasi A K, VIT Chennai


14
Input unit
Input units are used to provide the
coded information to the computer
Keyboard, Joysticks, Mouse,
Microphone, Scanner

Dr. Ilavarasi A K, VIT Chennai


15
Output unit

• To send processed results to the outside


world
• Printers, Graphics display, Audio output
devices (Speakers)

Dr. Ilavarasi A K, VIT Chennai


16
System interconnection
 System bus is a very common mechanism for
providing communication path for transfer of
data across the functional units of a computer
like CPU, main memory and I/O

Dr. Ilavarasi A K, VIT Chennai


17
Secondary memory Registers
 Register is memory unit inside the processor and
capable of high speed processing.
Primary memory
 The memory hierarchy defined in the figure
shows the memory levels of high storage capacity
to low storage capacity as well as low speed to
Cache memory high speed
 In memory hierarchy secondary memory is less
expensive one and register is high expensive
memory unit
Registers

Dr. Ilavarasi A K, VIT Chennai


18
Registers
Registers have 2 specific roles:
1. User variable registers: These registers
minimizes main memory references
2. Control and status registers: These
registers are used by control unit in CPU
to control the processor’s operation and
execution of operating system programs

Dr. Ilavarasi A K, VIT Chennai


19
User variable registers
These registers are 4 types:
1. General purpose
2. Data
3. Address
4. Condition codes

Dr. Ilavarasi A K, VIT Chennai


20
General purpose registers
The programmer assigns these registers for
different functions
These registers can hold the operands of
arithmetic operations

Dr. Ilavarasi A K, VIT Chennai


21
Data registers
 These registers only holds the data
The restriction of these registers is, these can
not be used for operand address calculation

Dr. Ilavarasi A K, VIT Chennai


22
Address registers
There are different categories of address registers
1. Segment pointers:
a. These holds segments base address
b. There may be multiple registers
2. Index registers:
a. These can be used for indexed addressing
b. Autoindexed
3. Stack pointers: for user variable stack addressing, top of the
stack is pointed by a dedicated register

Dr. Ilavarasi A K, VIT Chennai


23
Control and status registers
 The operation of the processor is controlled
 These registers are not visible to the user on most of the
machines
 Some of these registers are visible in operating system mode

Dr. Ilavarasi A K, VIT Chennai


24
Control and status registers
There are 4 registers, which are important for execution of an
instruction
1. Program counter: This register contain an instruction
address selected for fetching
2. Instruction register: Most recently fetched instruction stores
in this register
3. Memory address register: This register holds the address of
the instruction in memory
4. Memory data/ buffer register: The data in this register is
either read from memory or written to memory

Dr. Ilavarasi A K, VIT Chennai


25
Control and status registers
Program status word (PSW): This register contains status
information. This also contains condition codes as well as some
status information. Common fields or flags of this register
contain the following:
a. Sign
b. Zero
c. Carry
d. Equal
e. Overflow
f. Interrupt enable/disable
g. Supervisor
Dr. Ilavarasi A K, VIT Chennai
26
Register file
 Register file is a structure that stores the processor’s 32
general purpose registers

 It contains a register state of the computer.

Dr. Ilavarasi A K, VIT Chennai


27
Register file
Register A register file with four inputs and two
Number
5 Read outputs are shown in the figure.
Register1 Read
5 Data1
Read
Register2 Registers Data
5
Read
Register3 Read
Data Data2
Write
Data

Dr. Ilavarasi A K, VIT Chennai


RegWrite
28
Register file
 R-format instructions have 3 register operands,
 Reading of two data words from the register file
 Writing of one data word into the register.
 For reading of each data word from the registers, the following
are needed
1. Input – number of the register to be read
2. Output – this will carry the value that has been read
from the registers

Dr. Ilavarasi A K, VIT Chennai


29
Register file
 Write of data word needs two inputs:
1. Specifies the number of the register to be written
2. Supplies the data to be written into the register.
 It outputs the contents of Read register inputs (i.e. register
number).

Dr. Ilavarasi A K, VIT Chennai


30

Interconnection Architecture

Dr. Ilavarasi A K, VIT Chennai


31

Interconnection of components
 Program Counter (PC) is specialized register
 Keep track of the execution of a program
 It contains memory address of the next instruction
to be fetched and executed
 During the execution of an instruction, the
contents of the PC are updated to correspond to
the address of the next instruction to be executed
 PC points to the next instruction that is to be
fetched from memory.
Dr. Ilavarasi A K, VIT Chennai
32

Interconnection of components
 The Instruction Register (IR):
 Holds the instruction that is currently being executed
 Its output is available to the control circuits
 Generates the timing signals that control the various
processing elements involved in executing the
instruction

Dr. Ilavarasi A K, VIT Chennai


33

Processor- Memory interaction


 Two registers facilitates communication with the
memory
 Memory Address Register (MAR)
 holds the address of the location to be accessed
 Memory Data Register (MDR)
 Contains the data to be written into or read out of the
addressed location

Dr. Ilavarasi A K, VIT Chennai


34

Typical operational steps


 Programs reside in the memory
 Execution of the program starts when PC is set to point to
the first instruction of the program
 The content of the PC are transferred to MAR
 A read control signal is sent to the memory
 The addressed word is read out of the memory and
loaded into the MDR
 Next, the contents of the MDR are transferred to the IR
 At this point the instruction is ready to be decoded and
executed

Dr. Ilavarasi A K, VIT Chennai


35

Typical operational steps

 It is necessary to obtain the required operands to complete the execution of


instruction
 If an operand resides in the memory, it has to be fetched by sending its address
to the MAR and initiate read cycle
 Operand is read from the memory to MDR, then it is transferred from MDR to
ALU
 After one or more operands are fetched in this way, the ALU can perform the
desired operation.
 If the results of this operation is to be stored in the memory, the results is sent
to MDR
 The address of the location where the result is to be stored is sent to the MAR,
and write cycle is initiated

Dr. Ilavarasi A K, VIT Chennai


36

References
1. Carl Hamacher, Zvonko Vranesic, Safwat Zaky,
Computer organization, Mc Graw Hill, Fifth
edition ,Reprint 2011.
2. David A. Patterson and . John L. Hennessy
“Computer Organization and Design-The
Hardware/Software Interface” 5th edition,
Morgan Kaufmann, 2011.

Dr. Ilavarasi A K, VIT Chennai

You might also like