Presentation is loading. Please wait.

Presentation is loading. Please wait.

Part II : Lecture III 240-334 By Wannarat.

Similar presentations


Presentation on theme: "Part II : Lecture III 240-334 By Wannarat."— Presentation transcript:

1 Part II : Lecture III By Wannarat

2 Multiplication 0010 (multiplicand) x 1011 (multiplier) ????
By Wannarat

3 Unsign Combinational Multiplier
By Wannarat

4 Multiplication : First Version (Unsign)
By Wannarat

5 Multiplication : First Version (contd.)
By Wannarat

6 Analyze First Version 1 clock per cycle
50 % of bit in multiplicand always = 0 => 64-bit adder is wasted 0’s inserted in left of multiplicand as shifted => lead significant bits of product never changed once formed By Wannarat

7 Multiplication : Second Version
By Wannarat

8 Multiplication : Second Version (Contd.)
By Wannarat

9 Analyze Second Version
Product register wasted space that exactly matches size of multiplier Combine Multiplier register and Product register By Wannarat

10 Multiplication : Third Version
By Wannarat

11 Multiplication : Third Version (Contd.)
By Wannarat

12 Analyze Third Version 2 steps per bit because multiplier & product combined MIPS registers Hi, Lo are left and right half of product By Wannarat

13 Booth’s Algorithm By Wannarat

14 Example : 2 x 7 By Wannarat

15 Example : 2 x -3 By Wannarat

16 Shifter : 2 kinds By Wannarat

17 Part III : Lecture III By Wannarat

18 Divide By Wannarat

19 Divide : First Version By Wannarat

20 Divide : First Version (Contd.)
By Wannarat

21 Analyze First Version 50% bits in divisor always 0
=>1/2 of 64-bit adder is wasted => 1/2 divisor is wasted 1 step cannot produce a 1 in quotient bit => Switch order to shift first By Wannarat

22 Divide : Second Version
By Wannarat

23 Divide : Second Version (Contd.)
By Wannarat

24 Analyze Second Version
Eliminate Quotient register by combining with Remainder as shifted left By Wannarat

25 Divide : Third Version By Wannarat

26 Divide : Third Version (Contd.)
By Wannarat

27 Analyze Third Version Do Analyze by yourself By Wannarat

28 Floating Point : IEEE754 By Wannarat

29 Floating-point Representation
-0.75 = -3/4 = -3/22 = -11/ 22 = = -1.1x 2-1 = (-1)s x (1 + signifiand) x 2 (exponent-127) = (-1) x ( ) x 2( ) S E M 1-bit 8-bit bit By Wannarat

30 Floating-point Addition
9.999 x x10-1 Step1 : Change exponent as : 1.610 x = x 101 Step2 : Add significands 9.999 (10) (10) (10) Sum = x 101 By Wannarat

31 Floating-point Addition
9.999 x x10-1 Step3 : correct it (normalization) : x 10 1 = x 102 Step4 : Four digits for significand 1.002 x 102 By Wannarat

32 Example Floating-point Addition
0.5 + ( ) 0.5 = 1/2 = 1/21 = 0.1 x 20 = 1.00 x 2-1 = -7/16 = -7/24 = = x 2-2 step 1 : x 2-1 step 2 : 1.0x ( x 2-1)=0.001 x 2-1 step 3 : 1.0 x 2 -4 step 4 : By Wannarat

33 Multiplication Floating-point
Study in Text Book by yourself. By Wannarat

34 Next on Lecture 4 By Wannarat


Download ppt "Part II : Lecture III 240-334 By Wannarat."

Similar presentations


Ads by Google