Professional Documents
Culture Documents
Lecture - 1 Architecture
Lecture - 1 Architecture
1 – Organization
2 – Operation
3 – Design
4 – Control
Computer Architecture
CO1: Identify the basic structure and functional units
of a digital computer.
References –
1. C. Hamacher, Z. Vranesic and S. Zaky, "Computer Organization",
McGrawHill, 2002.
2. W. Stallings, "Computer Organization and Architecture - Designing
for Performance", Prentice Hall of India, 2002.
3. D. A. Patterson and J. L. Hennessy, "Computer Organization and
Design - The Hardware/Software Interface", Morgan Kaufmann,1998.
4. J.P. Hayes, "Computer Architecture and Organization", McGraw-Hill,
1998.
Computer Organization
and Architecture
Why Study Computer Architecture?
• Because you use it everyday,
• Because you will likely use it for the rest of your life,
• If you are writing assembly codes, you know exactly how many
instructions-cycle it will take to execute it, which is generally not
possible in higher languages like C/Java etc.
• The memory hierarchy model lets you optimize the Page
file/cache/RAM, etc. to get the code execute in least time.
• The input unit takes the input, the central processing unit
does the processing of data and the output unit produces
the output. The memory unit holds the data and
instructions during the processing.
• Digital Computer: A digital computer can be defined as a
programmable machine which reads the binary data passed as
instructions, processes this binary data, and displays a
calculated digital output. Therefore, Digital computers are
those that work on the digital data.
• A computer organization describes the functions and
design of the various units of a digital system.
• Cache memory is also a kind of memory which is used to fetch the data very soon. They are
highly coupled with the processor.
• The most common examples of primary memory are RAM and ROM.
• Secondary memory is used when a large amount of data and programs have to be stored
for a long-term basis.
• It is also known as the Non-volatile memory form of memory, means the data is stored
permanently irrespective of shut down.
• The most common examples of secondary memory are magnetic disks, magnetic tapes, and
optical disks.
Arithmetic & Logical Unit -
• Most of all the arithmetic and logical operations of a
computer are executed in the ALU (Arithmetic and
Logical Unit) of the processor. It performs arithmetic
operations like addition, subtraction, multiplication,
division and also the logical operations like AND, OR,
NOT operations.
Control Unit -
• The control unit is a component of a computer's central
processing unit that coordinates the operation of the
processor. It tells the computer's memory, arithmetic/logic
unit and input and output devices how to respond to a
program's instructions.
• The control unit is also known as the nerve center of a
computer system.
Output Unit -
• These operations consider each bit of the register separately and treat
them as binary variables.
• The outputs of the gates are applied to the data inputs of the multiplexer.
• The two selection inputs S1 and S0 choose one of the data inputs of the
multiplexer and direct its value to the output.
Some Applications
• Logic microoperations are very useful for manipulating
individual bits or a portion of a word stored in a register.
Done
Today
Adder - Subtractor - Incrementor
1. For M = 0
The circuit is an adder, since we have .
The full-adders receive the value of B, the input carry C0 is 0, and
the circuit performs the addition of A to B (i.e. A+B).
2. For M = 1
The circuit becomes a Subtractor, since we have
The full-adders receive the value of B, the input carry C0 is 1.
The B inputs are all complemented and a 1 is added through the input
carry. The circuit performs the addition of A to 2’s complement of B.
Note
Incrementing
• Data A can be incremented if logic 1 is applied to the control
inputs of MUX 1 and MUX 3.
• The base of the number system (where base is defined as the total
number of digits available in the number system)
Decimal Number System
• The number system that we use in our day-to-day life is the
decimal number system.
• Decimal number system has base 10 as it uses 10 digits from 0 to
9.
• In decimal number system, the successive positions to the left of
the decimal point represents units, tens, hundreds, thousands and
so on.
• Each position represents a specific power of the base (10).
For example, the decimal number 1234
• 4 in the units position,
• 3 in the tens position,
• 2 in the hundreds position,
• and 1 in the thousands position
• As a computer programmer or an IT professional, you
should understand the following number systems which
are frequently used in computers.
Binary Number System
Characteristics
As mentioned in Steps 2 and 4, the remainders have to be arranged in the reverse order so that
the first remainder becomes the Least Significant Digit (LSD) and the last remainder becomes
the Most Significant Digit (MSD).
• Weighted Codes
• Non-Weighted Codes
• Binary Coded Decimal Code
• Alphanumeric Codes
• Error Detecting Codes
• Error Correcting Codes
Done
Today’s
Class
Complement
Arithmetic
Unit – 2, Part –A, Topic - 1
• Complements are used in the digital computers in order to
simplify the subtraction operation and for the logical
manipulations.
• This notation allows a computer to add and subtract numbers using the
same operations (thus we do not need to implement adders and subtractors).
• Using the 2’s complement (or 1’s though it’s less often used) means the
CPU is cheaper to build while being as fast (or usually faster) in all cases as
it would otherwise be.
Next Class
Done
Today
Booth's Algorithm
• Booth's algorithm is a multiplication algorithm that
multiplies two signed binary numbers in two's
complement notation.
• Digital representations are easier to design, storage is easy, accuracy and precision
are greater.
• There are two major approaches to store real numbers (i.e., numbers with
fractional component) in modern computing.
• These are (i) Fixed Point Notation and (ii) Floating Point Notation. In fixed point
notation, there are a fixed number of digits after the decimal point, whereas
floating point number allows for a varying number of digits after the decimal
point.
Fixed-Point Representation −
• This representation has fixed number of bits for integer
part and for fractional part.
• There are three parts of a fixed-point number
representation: the sign field, integer field, and fractional
field.
Floating-Point Representation −
• This representation does not reserve a specific number of
bits for the integer part or the fractional part.
• Solution –