1.39k likes | 1.41k Views
Explore various multiplier types and algorithms for efficient digital signal processing applications. Learn about circuit designs and multiplication techniques.
E N D
Multipliers • A must have circuit in most DSP applications • A variety of multipliers exists that can be chosen based on their performance • Serial, Serial/Parallel,Shift and Add, Array, Booth, Wallace Tree,….
r e e s n e r t e e s n e t RA converter 16x16 multiplier Converter r RC e e s n e t RB converter
Multiplication Algorithm X= Xn-1 Xn-2 ………..……X0 Multiplicand Y=Yn-1 Yn-2……………….Y0 Multiplier Yn-1X0 Yn-2X0 Yn-3X0 …… Y1X0 Y0X0 Yn-1X1 Yn-2X1 Yn-3X1 …… Y1X1 Y0X1 Yn-1X2 Yn-2X2 Yn-3X2 …… Y1X2 Y0X2 … … … … …. …. …. …. …. Yn-1Xn-2 Yn-2X0 n-2 Yn-3X n-2 …… Y1Xn-2 Y0Xn-2 Yn-1Xn-1 Yn-2X0n-1 Yn-3Xn-1 …… Y1Xn-1 Y0Xn-1 ----------------------------------------------------------------------------------------------------------------------------------------- P2n-1 P2n-2 P2n-3 P2 P1 P0
1.Multiplication Algorithms Implementation of multiplication of binary numbers boils down to how to do the additions. Consider the two 8 bit numbers A and B to generate the 16 bit product P. First generate the 64 partial Products and then add them up.
Storage R E G I N REG OUT MU ( Multiplier Unit) Control Unit Multiplier Design
Serial Multiplier X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Slide 1
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Slide 2
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Slide 3
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Slide 4
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Slide 5
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Slide 6
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 7
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 8
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 9
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 10
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 11
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 12
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 13
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 14
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 15
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 16
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 17
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 18
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 19
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 20
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 21
X: x3x2x1x0Y:y 3y2y1y0 Input Sequence for G1: 00x3x2x1x00x3x2x1x0 0x3x2x1x0 0x3x2x1x0 00y 3y3y3y3 0y 2y2y2y2 0y 1y1y1y1 0y 0y0y0y0 Reset:010000100001000010000 Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 21
Si: the ith bit of the final result Serial / Parallel Multiplier Slide 1
Si: the ith bit of the final result Ci: the only carry from column i Slide 2
Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 3
Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 4
Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 5
Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 6
Si: the ith bit of the final result Ci: the only carry from column i Sij: the jth partial sum for column i Cij: the jth partial carry from column i Slide 7
Si: the ith bit of the final result Ci: the only carry from column i Slide 8
Shift AND Add Multiplier INPUT Ain (7 downto 0) REGA 0 MUX INPUT Bin (7 downto 0) 8 bit Adder REGB REGC Result (7 downto 0) Result (15 downto 8) CLOCK
Synchronous Shift and Add Multipliercontroller • Multiplication process: • 5 states: Idle, Init, Test, Add, and Shift&Count. • Idle: Starts by receiving the Start signal; • Init: Multiplicand and multiplier are loaded into a load register and a shift register, respectively; • Test: The LSB in the shift register which contains the multiplier is tested to decide the next state;
Synchronous Shift and Add Multiplier ControllerDesign • Add: If LSB is ‘1’, then next state is to add the new partial product to the accumulation result, and the state machine transits to shift&count state ; • Shift&Count: If LSB is ‘0’, then the two shift register shift their contains one bit right, and the counter counts up byone step. After that, the state machine transits back to test state; • When the counter reaches to N , a Stopsignal is asserted and the state machine goes to the idle state; • Idle: In the idle state, a Donesignal is asserted to indicate the end of multiplication.
n-bit Multiplier: Q0=1: Multiplicand is added to register A; the result is stored in register A; registers C, A, Q are shifted to the right one bit Q0=0: Registers C, A, Q are shifted to the right one bit Slide 1
Example: 4-bit Multiplier Initial Values Slide 2
Example: 4-bit Multiplier First Cycle--Add Slide 3
Example: 4-bit Multiplier First Cycle--Shift Slide 4
Example: 4-bit Multiplier Second Cycle--Shift Slide 5
Example: 4-bit Multiplier Third Cycle--Add Slide 6
Example: 4-bit Multiplier Third Cycle--Shift Slide 7
Example: 4-bit Multiplier Fourth Cycle--Add Slide 8
Example: 4-bit Multiplier Fourth Cycle--Shift Slide 9
4*4 Synchronous Shift and Add Multiplier DesignLayout Design Floor plan of the 4*4 Synchronous Shift and Add Multiplier
Comparison between Synchronous and Asynchronous Approaches .