Intro To COA Ans Von Neumann

Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 14

Prof.

Tasneem Mirza
Difference between Computer Organization
and Computer Architecture
Computer Architecture is related to attributes visible to a
programmer.
Eg: Instruction set
Representation of various data types
I/O mechanisms
Addressing modes
Computer Organization is about the operational units, and
their interconnections.
Eg: Control signals.
Memory technology
Interface between the computer and peripherals
Prof. Tasneem Mirza
 All computers more or less based on the same basic design, the
Von Von Neumann Architecture.

 Designed by John Von Neumann in 1946 at the Institute for


advanced studies (IAS).

 Also referred to as IAS machine or a stored program computer

The computer consists of four main sub-systems:


 Main Memory : Stores data and instructions
 ALU (Arithmetic/Logic Unit) :Performs operations on binary
data.
 Control Unit : Interprets the instructions in memory and
causes them to be executed.
 Input/Output System (I/O) : Peripheral devices through
which input is accepted and to which output is generated.
Bus

Processor (CPU)

Memory Input-Output
Control Unit

ALU
Communicate with
Store data and program
"outside world", e.g.
• Screen
• Keyboard
Interprets Instructions
• Storage devices
• ...
Do arithmetic/logic operations
requested by program
CMPUT101 Introduction to
(c) Yngvi Bjornsson Computing 5
 ALU + CU -- Central processing unit (CPU)
 The primary function of a CPU is to execute a sequence of
instructions stored in main memory which is external to the
CPU
 Instruction Cycle :The sequence of operations involved in
processing an instruction constitutes an instruction cycle
 Instruction Cycle

Fetch Cycle Execute Cycle

Instruction Includes:
is obtained 1.Decoding the instruction
from MM 2.Fetching the required
operands(if any)
3.Performing the
operation as
Main Memory

Address
Data Control
Bus
Bus Bus

MAR MDR
Control

PC R0
R1
IR
ALU
Rn-1

N general
purpose reg.
1-D memory

1000 25

1001

1002

1003

1004
1. Instruction register(IR)
IR contains the instruction which is being executed.
2. Program counter(PC)
Keeps track of program execution.
During the execution of the current instruction, the contents of
the PC are updated to correspond to the address of the next
instruction to be executed.
Two registers that facilitate communication with the main
Memory.
3. Memory address register(MAR)
Used to hold the address of the location to or from which data
is to be transferred.
4. Memory data register(MDR)
Contains the data to be written into or read out of the addressed
location
5. General purpose register
Used for temporary storage.
6. Stack Pointer
Stack memory is intended for saving key information about
an
interrupted program via push operation so that the saved
information can be retrieved later via a pop operation.
The stack pointer keeps track of the stack’s entry point.
Operation of the CPU :
1. Programs are stored in the main memory.

2. Execution of the program starts when the PC is set to point


to the first instruction of the program.
3. Contents of PC are transferred to the MAR.

4. Read control signal is sent to the memory.

5. The addressed word ( first instruction of the program) is


read out of the memory and loaded into the MDR.
6. The contents of the MDR are transferred to the IR.

7. Now the instruction is decoded and ready to be executed.


8. If the operands are residing in the memory , it will have to
be fetched by -----
1. Sending it’s address to the MAR.
2. Read control signal is sent to the memory.
3. The required operand is read out of the memory and
loaded into the MDR.
4. From MDR the data is transferred to the ALU.

In this way one/more operands can be fetched from the


memory and the ALU can perform the desired operation.
10. If the result of the operation is to be stored in the memory then------
1. Result is sent to the MDR.
2. The address of the location where the result is stored is
sent to the memory through the MAR.
3. A write control signal is sent to the memory.
4. Contents of the MDR are written onto the memory location

During the instruction execution the contents of the PC are


incremented to point to the next instruction to be executed.
Note : Status register is used by the processor to record
exceptional conditions such as attempt to divide by zero or all
zero result.
Detailed Von Neumann Architecture
Data
General processing
Purpose ALU unit
registers

MDR Status
Register
T
o
Data Bus
Address Bus
M
e Control Bus
m Program
o MAR IR Control
r Unit
y
PC Address
Control
Generation
Logic Unit
SP

You might also like