Unit 2: 18CSC203J-Computer Organization and Architecture
Unit 2: 18CSC203J-Computer Organization and Architecture
Unsigned 27 = 128 26 = 64 25 = 32 24= 16 23= 8 22 = 4 21 = 2 20 = 1
Signed -(27) = -128 26 = 64 25 = 32 24 = 16 23 = 8 22 = 4 21= 2 20 = 1
Integer Representation (cont’d)
Sign Magnitude: One's Complement Two's Complement
000 = +0 000 = +0 000 = +0
001 = +1 001 = +1 001 = +1
010 = +2 010 = +2 010 = +2
011 = +3 011 = +3 011 = +3
100 = -0 100 = -3 100 = -4
101 = -1 101 = -2 101 = -3
110 = -2 110 = -1 110 = -2
111 = -3 111 = -0 111 = -1
Boolean Expression
Full Adder
• Full adder is developed to overcome the drawback
of Half Adder circuit. It can add two one-bit
numbers A and B, and carry c. The full adder is a
three input and two output combinational circuit.
Truth Table and Circuit Diagram
Half Subtractor
• Half subtractor is a combination circuit with two
inputs and two outputs (difference and borrow). It
produces the difference between the two binary bits at
the input and also produces a output (Borrow) to
indicate if a 1 has been borrowed. In the subtraction
(A-B), A is called as Minuend bit and B is called as
Subtrahend bit.
Truth Table and Circuit Diagram
• A carry-save adder is a type of digital adder, used to efficiently compute the sum of
three or more binary numbers.
• A carry-save adder (CSA), or 3-2 adder, is a very fast and cheap adder that does not
propagate carry bits.
• A Carry Save Adder is generally used in binary multiplier, since a binary multiplier
involves addition of more than two binary numbers after multiplication.
• It can be used to speed up addition of the several summands required in
multiplication
• It differs from other digital adders in that it outputs two (or more) numbers, and the
answer of the original summation can be achieved by adding these outputs together.
• A big adder implemented using this technique will usually be much faster than
conventional addition of those numbers.
Fast Multiplication
Bit pair recoding reduces summands by a factor of 2
Summands are reduced by carry save addition
Final product can be generated by using carry look ahead adder
Carry-Save Addition of Summands
• Decimal Division
• Binary Division
Why FPR?
• Consider a very small number 0.00000000005
• As it consists of many 0’s after the decimal point, it
requires more number bits for representation
• 0.00000000005 is represented as 0.5 x 10-10, it will require only fewer bits
• Consider a very large number 50000000000 which can be represented as
5 x 1010 (+5
• Consider the example 0.123 x 104 = 0.0123 x 105 = 123 x 103
• But we need a fixed and single representation for floating point numbers.
For this normalization is required.
Floating Point Numbers and Operations
Normalization rules for floating point number
There are 2 rules:
(1)The integer part should be 0 n
In the example 0.123 x 10 = 0.0123 x 105 = 123 x 103, the strikethrough representations are wrong with respect to normalization rules.
4