Download presentation
Presentation is loading. Please wait.
1
12/7/2018 1
2
11.1 Shift-Add Multiplication
Figure Multiplication of 4-bit numbers in dot notation.
3
Example shift-add multiplication: Works basically like you do "long-hand" multiplication except that you (1) add partial products together as you get them, and (2) shift running total to the right after it is recalculated. This eliminates need to add digits of the partial product to nothing. It also ensures same column of digits are always added. Digits shifted to the right of these columns are simply carried down.
4
Recurrence equation describing above process
add Shift right
5
Shift-add example: 10100011 Figure Step-by-step multiplication examples for 4-digit unsigned binary and decimal numbers.
6
Signed integer multiplication
Signed-magnitude numbers can be multiplied by using the shift-add algorithm discussed above, and deriving the sign of the products as XOR of the two input sign bits. In the last multiplication step, we must subtract, rather than add, the partial product yk-1x. e.g., x (1011)2’s-compl = -8x +2x+x = -5x
7
Example: Two’s-complement multiplication
Figure Step-by-step multiplication examples for 4-digit 2’s-complement numbers.
8
11.2 Hardware Multipliers Figure Hardware multiplier based on the shift-add algorithm.
9
Figure Shifting incorporated in the connections to the partial product register rather than as a separate phase.
10
Fast hardware multiplication
Full-tree multiplier Array muplier HA: half adder, FA: full adder, MA: modified full adder
11
Figure 11.6 Schematic diagrams for full-tree and partial-tree multipliers.
12
Figure 11.7 Array multiplier for 4-bit unsigned operands.
15
8-bit array multiplier (unsiged)
17
Figure 11.9 Division of an 8-bit number by a 4-bit number in dot notation.
18
Recurrence equation describing above process
shift subtract
19
Unsigned operands, z: 2k-bit, x: k-bit
1 1 Figure Step-by-step division examples for 8/4-digit unsigned binary integers and decimal fractional numbers.
20
Unsigned operands, z: k-bit, x: k-bit
Figure Step-by-step division examples for 4/4-digit unsigned binary integers and fractional numbers.
21
Dividing signed number:
(1) Convert operands to into unsigned values, perform unsigned division (2) At then end, adjust signs for y (quotient) and s (remainder)
22
11.5 Hardware Dividers k cycle for 2k/k division
Figure Hardware divider based on the shift-subtract algorithm
23
Figure Shifting incorporated in the connections to the partial remainder register rather than as a separate phase.
24
Figure 11.14 Array divider for 8/4-bit unsigned integers.
25
Array Divider (unsigned)
26
Conditional Subtractor
q = 0 co = majority ( r, d, ci ) ; s = r // identity q = 1 s = r XOR d XOR ci // subtraction
27
11.6Programmed Division Figure Register usage for programmed division superimposed on the block diagram for a hardware divider.
Similar presentations
© 2024 SlidePlayer.com Inc.
All rights reserved.