SKV Unit 1 COA
SKV Unit 1 COA
Dr. S. K. Verma
Introduction
Computer Organization vs Computer
Architecture
System And Computer System
Computer Types
◦ Embedded computers
used for a specific purpose
◦ Personal computers
Desktop computers
Workstation computers
Portable and Notebook computers
◦ Servers and Enterprise systems
◦ Supercomputers and Grid computers
cloud computing
Eight Great Ideas in Computer
Architecture
Design for Moore’s Law
Use Abstraction to Simplify Design
trackball.
Microphones
Cameras
Digital communication facilities
Memory Unit
There are two classes of storage:
Primary Memory
◦ main memory
◦ a fast memory that operates at electronic speeds
◦ memory consists of a large number of semiconductor storage cells
◦ cells are rarely read or written individually
◦ handled in groups of fixed size called words
◦ one word can be stored or retrieved in one basic operation
◦ word length of the computer
◦ distinct address is associated with each word location
◦ A memory in which any location can be accessed in a short and
fixed amount of time after specifying its address is called a
random-access memory (RAM).
◦ memory access time
Contd.
Cache Memory
◦ adjunct to the main memory, a smaller, faster RAM unit,
called a cache.
◦ Used to hold sections of a program that are currently
being executed.
◦ cache is tightly coupled with the processor and is usually
contained on the same integrated-circuit chip.
Secondary Storage
◦ additional, less expensive, permanent secondary storage is
used.
◦ Access times for secondary storage are longer than for
primary memory
◦ magnetic disks, optical disks (DVD and CD), and flash
memory devices.
Arithmetic and Logic Unit
operations are executed in the arithmetic
and logic unit (ALU)
When operands are brought into the
outside world.
Control Unit
Coordination among different units done by CU.
Control circuits are responsible for generating the
timing signals.
large set of control lines (wires) carries the signals
used for timing and synchronization of events in all
units.
The operation of a computer can be summarized as
follows:
◦ The computer accepts information in the form of programs
and data through an input unit and stores it in the memory.
◦ Information stored in the memory is fetched under
program control into an arithmetic and logic unit, where it
is processed.
◦ Processed information leaves the computer through an
output unit.
◦ All activities in the computer are directed by the control unit.
Basic Operational
Concepts
Load R2, LOC
Add R4, R2, R3
Store R4, LOC
Contd.
Contd.
Contd.
Contd.
the processor contains a number of
registers used for several different
purposes.
instruction register (IR) holds the instruction
register
PC points to the next instruction that is to
length
Contd.
Byte Addressability
◦ byte-addressable memory is used
◦ if the word length of the machine is 32 bits,
successive words are located at addresses 0,
4, 8, . . . , with each word consisting of four
bytes.
Big-Endian and Little-Endian
Assignments
Contd.
Representing Instructions in
the Computer
layout of the instruction is called the
instruction format
the numeric version of instructions machine
language and a sequence of such instructions
machine code.
indirect
Displacement
Stack A = contents of an address field in the instruction
R = contents of an address field in the instruction that
refers to a register
EA = actual (effective) address of the location
containing the referenced operand
(X) = contents of memory location X or register X
Contd.
Virtually all computer architectures provide more
than one of addressing modes. (mode field)
the effective address will be either a main
memory address or a register.
Immediate Addressing
◦ the operand value is present in the instruction
Operand = A
◦ advantage of immediate addressing is that no
memory reference other than the instruction fetch is
required to obtain the operand
◦ disadvantage is that the size of the number is
restricted to the size of the address field
Contd.
Direct Addressing
◦ the address field contains the effective address of the
operand:
EA = A
◦ It requires only one memory reference and no special
calculation.
◦ limitation is that it provides only a limited address space.
Indirect Addressing
◦ the address field refer to the address of a word in memory
EA = (A)
◦ advantage of approach is that for a word length of N, an
address space of 2N is now available.
◦ disadvantage is that three or more memory references
could be required to fetch an operand.
Contd.
Register Addressing
◦ It is similar to direct addressing
◦ address field refers to a register rather than a main memory
address:
EA = R
◦ if the contents of a register address field in an instruction is
5, then register R5 is the intended address, and the operand
value is contained in R5.
◦ advantages of register addressing are
a small address field is needed in the instruction
no time- consuming memory references are required
◦ modern processors employ multiple general-purpose
registers, placing a burden for efficient execution on the
assembly- language programmer
Contd.
Register Indirect Addressing
◦ register indirect addressing is analogous to indirect
addressing.
EA = (R)
◦ advantages and limitations of register indirect
addressing are the same as for indirect addressing.
◦ register indirect addressing uses one less memory
reference than indirect addressing.
Displacement Addressing
◦ combines the capabilities of direct addressing and
register indirect addressing
EA = A + (R)
Contd.
Relative addressing
Base-register addressing
Indexing
relative addressing
Floating-Point Arithmetic
A floating-point operation may produce one of
these conditions:
◦ Exponent overflow: A positive exponent exceeds
the maximum possible exponent value.
◦ Exponent underflow: A negative exponent is less
than the minimum possible exponent value (e.g., -
200 is less than -127).
◦ Significand underflow: In the process of aligning
significands, digits may flow off the right end of the
significand.
◦ Significand overflow: The addition of two
significands of the same sign may result in a carry
out of the most significant bit.
Addition and Subtraction
There are four basic phases of the algorithm
for addition and subtraction:
◦ Check for zeros.
◦ Align the significands.
◦ Add or subtract the significands.
◦ Normalize the result.
Multiplication and Division
Contd.
Thank You (End Unit 1)