Computer multiplication circuits accept a multiplicand and a multiplier and generate a product. One straightforward method to multiply binary numbers is the long form of multiplication. This is the standard shift-and-add approach. That is, for each column in a multiplier, shift the multiplicand the appropriate number of columns and add the shifted multiplicand into the final total if the multiplier column contains a one, or don't add it if the if the multiplier column contains a zero. The shifted numbers to be added are called partial products because they represent intermediate results in determining the final product of the multiply. All of the partial products are added together to determine the final product. Thus, the number of shifts to be executed is equal to the number of columns in the multiplier, and the number of partial products to be added is equal to the number of ones in the multiplier.
This method of multiplying is slow and there have been methods developed to speed up the multiplying process. One method to speed up multiplying is to use radix-four multiplication or Booth multiplication. Instead of shifting and adding for every column of the multiplier, the method uses every other column. Booth encoding involves looking at three consecutive bits of a multiplier to determine whether to multiply the multiplicand by −1, +1, −2, +2, or zero to obtain a partial product. This method reduces the number of partial products to be added by one-half, and consequently reduces the complexity and power consumption of circuits that implement the method.
The Booth encoding process consists of looking at three bits of a multiplier to determine how to calculate a partial product. As an example the hexadecimal number 4E2 is shown below.
010011100010—
In long multiplication by the shift and add method, twelve partial products would be used to determine the final product. To determine the partial products for Booth encoding, the number is grouped into the three-bit blocks. The least significant block begins with only the two least significant bits of the multiplier and zero is used as the least significant bit (LSB) of the block. Grouping starts at the LSB and each block overlaps the previous block by one bit. The most significant block is sign extended if necessary to fill out a block. Based on the three bits in the block, the multiplicand is multiplied by −1, +1, −2, +2, or 0 to obtain the partial product. Table 1 shows the encoding used for each possible three-bit block.
Starting with the LSB in the example above, the six blocks are 100, 001, 100, 111, 001 and 010. The multiplicand is then multiplied by −2, +1, −2, 0, +1 and +1 to obtain the six partial products. The partial products are shifted according to which block is decoded and then added together to obtain the final product.
Despite reducing the number of partial products by one-half, Booth multiplication can still result in complex circuits. Typically, computers that want to obtain the result of a multiply as quickly as possible use a circuit to calculate each bit of the partial products. So, for example, a 64-bit by 64-bit multiply that uses the shift and add method needs to add 64 partial products of 64 bits each; or 4096 circuits. A 64-bit by 64-bit multiply that uses Booth encoding reduces the number of partial products to be added by one-half. However, this method still requires adding 32 partial products of 64 bits each; or 2048 circuits.
It can be seen from this discussion that reducing the complexity of multiply circuits would result in significant savings of space used in fabricating the circuits and saving of power consumption in the operation of such circuits.
In the drawings like numerals refer to like components throughout the several views.
In the following detailed description, reference is made to the accompanying drawings which form a part hereof, and in which is shown by way of illustration specific embodiments in which the invention may be practiced. It is to be understood that other embodiments may be used and structural changes may be made without departing from the scope of the present invention.
This document describes circuits to generate partial products for multiplication. The partial products are generated for a type of multiplication known as radix-four multiplication, or Booth multiplication.
To generate the partial products, multiplexing can be used. In multiplexing, signals corresponding to the Booth-multiply functions of multiply by 0, −1, +1, −2, and +2 are used to select a bit for output from the multiplexer.
The middle two rows of the table show that the multiplicand bit is inverted at the Zj+1′ output by an active NEG signal or an inactive POS signal. It is also shown that if the NEG and POS control signals are both inactive, the Zj+1′ output is necessarily “0.”
The embodiment 320 shows four logic circuits. The first logic circuit generates the NEG signal. The first logic circuit includes a two-input NAND gate 325 where the inputs to the NAND gate 325 are first and second bits y2, y1 of the multiplier block. The first logic circuit also includes a transmission gate, or T-gate, 330 coupled to the output of the NAND gate 325. A third multiplier bit y3 and its complement activate the T-gate 330. A pull-down transistor 335 is coupled to the output of the T-gate 330. The complement of the third multiplier y3 bit activates the pull down transistor 335. The output of the T-gate 330 provides the NEG signal.
A second logic circuit generates the POS signal. In the embodiment 320, the second logic circuit includes a two-input NAND gate 340, where the inputs to the NAND gate 340 are complements of the first and second bits y2, y1 of the multiplier block. A T-gate 345 is coupled to the output of the NAND gate 340. The third multiplier bit y3 and a complement of the third multiplier bit activate the T-gate 345. The output of the T-gate 345 provides the POS signal. A pull-down transistor 350 is coupled to the output T-gate 345. The third multiplier bit y3 activates the pull down transistor 350.
A third logic circuit generates the M1 signal. In the embodiment 320, the third logic circuit includes a two-input XOR gate 355, where the inputs to the XOR gate 355 are first and second bits y2, y1 of a multiplier block and the output of the XOR gate 355 is the M1 signal.
A fourth logic circuit generates the M2 signal. In the embodiment 320, the fourth logic includes a two-input XNOR gate 360, where the inputs to the XNOR gate 360 are first and second bits y2, y1 of a multiplier block and the output of the XNOR gate 360 is M2 signal.
A multiplying operation where M and N are relatively large integers shows the advantages of a multiplexer circuit that minimizes the number of pass gates in a multiplexer. For example, an integrated circuit implementation of a multiply operation that uses a sixty-four bit multiplier and a sixty-four multiplicand would require 32*64 or 2048 multiplexers. Use of the four-transistor multiplexer 215 of
As the size of the multiplicand increases, the Booth control signals need to be distributed to more multiplexers. As the size of the multiplier increases, the multiplexer outputs may have to drive longer interconnect lines.
A read only memory (ROM) 1045 or other non-volatile storage device for storing fixed information for the processor 1015 is coupled to the system bus 1010. Other components such as a mass storage device 1040, a display device 1050, a keyboard 1055 or other input device and a cursor control device 1060 may also be included in the computer system 1000.
Although specific examples have been illustrated and described herein, it will be appreciated by those of ordinary skill in the art that any arrangement calculated to achieve the same purpose could be substituted for the specific example shown. This application is intended to cover any adaptations or variations of the present invention. Therefore, it is intended that this invention be limited only by the claims and the equivalents shown.
Number | Name | Date | Kind |
---|---|---|---|
5818743 | Lee et al. | Oct 1998 | A |
5880985 | Makineni et al. | Mar 1999 | A |
5917741 | Ng | Jun 1999 | A |
5943250 | Kim et al. | Aug 1999 | A |
6035316 | Peleg et al. | Mar 2000 | A |
6035318 | Abdallah et al. | Mar 2000 | A |
6055555 | Boswell et al. | Apr 2000 | A |
6065032 | Nicol | May 2000 | A |
6173304 | Goldovsky | Jan 2001 | B1 |
6240438 | Goto | May 2001 | B1 |
6269384 | Oberman | Jul 2001 | B1 |
6275842 | Nicol | Aug 2001 | B1 |
6286023 | Purcell et al. | Sep 2001 | B1 |
6301599 | Chehrazi et al. | Oct 2001 | B1 |
6308195 | Hirase et al. | Oct 2001 | B1 |
6393454 | Chu | May 2002 | B1 |
6460065 | Purcell | Oct 2002 | B1 |
6535902 | Goto | Mar 2003 | B2 |
6684236 | Farnbach | Jan 2004 | B1 |
6721774 | Lee et al. | Apr 2004 | B1 |
7069290 | Garrett et al. | Jun 2006 | B2 |
7096246 | Ferroussat | Aug 2006 | B2 |
20030158880 | Ng | Aug 2003 | A1 |
Number | Date | Country | |
---|---|---|---|
20050125478 A1 | Jun 2005 | US |