One of the basic functions in the operation of virtually all computer systems is the capability of adding two integers together. Having an addition function is essential because not only is addition used to provide numerical sums to users, it is also used in the implementation of numerous logic functions internal to the computer systems. Hence, one or more adders are typically found in the arithmetic logic unit of a computer's microprocessor.
As such, when two bits are added together, the result is a sum of those two bits plus a carry to the next, or leftward, position. Thus, the addition of multiple bits can be effectuated by using carry-out of one set of bits for carrying into the neighboring set of bits to its left. For example, the binary addition of the two bits “11” and “01” is performed by first adding together the two least significant, or rightmost, bits “1” and “1.” The result is a sum of “0” with a carry-out bit “1.” The carry-out bit is accounted for as a carry bit to the addition of the next set of bits, “0” and “1.” The result is a sum of “0” with a carry-out of “1.” This yields a final correct answer of “100” (i.e., 3+1=4).
As known to those skilled in the art, this type of adder is known as a ripple-carry adder because the addition function involves rippling the carry bit, which can be either “1” or “0,” all the way from the rightmost bit to the leftmost bit. One problem, however, associated with this type of adder is that it takes time to ripple the carry signal. In some cases, two levels of logic are implemented in computing the carry-out from a carry-in. Hence, if the least significant bit generates a carry which is propagated through the length of the adder, the signal passes through 2n levels of logic, with n being the length of the adder, before the last gate can determine whether there is a carry-out of the most significant bit. An example of such length-wide ripple effect is the addition of the binary numbers “101 . . . 111” and “000 . . . 001.”
In general, the time a circuit takes to produce an output is proportional to the maximum number of logic levels through which the signal travels, which constitutes a “critical path” of the circuit. This propagation delay is especially severe for cases involving the addition of large numbers having multiple bits, which frequently occurs in a circuit, such as a microprocessor. For example, a substantial amount of time is required to ripple a carry through the entire addition chain of two 32-bit words. Consequently, the time required to ripple the carry retards the critical time path, thereby slowing down the overall speed of the microprocessor. This detrimentally impacts the performance of a computer system.
However, ripple-carry adders are widely used in today's digital signal processing (DSP) applications because additions in these applications are most efficiently implemented using this type of adders. DSP technology serves the basis for devices such as mobile phones, multimedia computers, video recorders, CD players, etc., and will soon replace analog circuitry in television sets and telephones. Therefore, ripple-carry adders are an essential component in today's electronic devices.
Hence, it would be desirable to provide improved methods and systems for executing additions on ripple-carry adders that optimize their computational efficiency.
The present invention relates to systems and methods for a signed magnitude adder based on one's complement logic for optimally and efficiently performing addition operations in the digital domain.
According to one aspect of the invention, the operands to be added by a signed magnitude adder of the present invention are represented in the signed-magnitude domain. The adder operates by first converting the operands to their one's complement representations before adding them to produce a sum that is also in the one's complement domain. If an overflow bit is generated during the addition, this bit is removed from the sum and added to the sum at its least significant bit position. If a negative sum is subsequently produced, the magnitude bits of the sum are inverted in order to accurately convert the sum to its signed-magnitude representation.
In certain implementations, a two's complement ripple-carry adder is used to handle the adding of operands in their one's complement domain. In certain implementations, the signed magnitude adder based on one's complement logic is used in a digital signal processing application and the bit-width of the operands to be added are no more than ten.
The present invention provides systems and methods for a signed magnitude adder based on one's complement logic for optimally and efficiently performing addition operations in digital domain.
In general binary numbers are represented in a signed-magnitude format in most computer systems. Hence, signed-magnitude adders are needed to perform addition operations in those systems. Conventional signed-magnitude adders operate by first converting the operands into their two's complement representations before performing additions of these operands using two's complement logic. The resulting sum is then converted from its two's complement format to its signed-magnitude format.
According to the illustrative implementation of
Subsequently, these operands in the two's complement format undergo addition at, for example, traditional two's complement adder 106, as illustrated in
If a negative sum is produced from the addition operation at adder 106, as indicated by the sum's sign bit being 1, another round of bit-inversion of all the bits in the sum is required and followed by an addition of 1 so as to accurately convert the two's complement sum to its signed-magnitude representation. Half adder 108 may be used to perform such add-by-1 operation.
In
The implementation of
Subsequently, the one's complement operands undergo addition at, for example, a traditional two's complement adder 204, as illustrated in
If an overflow is generated from the two's complement addition operation at adder 204, the overflow bit is removed from the resulting sum and added to the sum at its least significant bit location, or the rightmost bit. This addition is implemented by adder 206 which includes a series of half adders (HA).
If the addition operation produces a negative sum in the one's complement domain, as indicated by the sum's most significant bit being 1, a final round of flipping of the sum's magnitude bits accurately converts the sum from its one's complement format to a signed-magnitude representation.
The implementation of
In comparing the traditional signed magnitude adder 100 of
In one aspect, the number of add-by-1 operations performed in adder 100 is equal to the number of operands involved in the addition. For example, two add-by-1 operations are required for the addition of A and B since there are two operands that are being added. Thus, the number of add-by-1 operations grows linearly with the number of operands in adder 100. On the other hand, for one's complement-based adder 200, the number of add-by-1 operations needed is a constant value of 1, regardless of how many operands there are in the addition operation. This overhead of the add-by-1 computation in two's complement-based adder 100 is significant in typical digital signal processing (DSP) applications which allocate only a limited number of bits (e.g., 5) to represent their internal variables.
In one implementation, a ripple-carry adder architecture is used to implement adder operations 106 and 204 of
It can be shown that the maximum ripple lengths of the two adder designs differ by a factor of 2 despite the fact that critical time paths 110 and 208 for the respective adders both trace through N−1 full adders (FA) and N+1 half adders (HA), where N is an exemplary operand bit-width. The explanation consists of the following: first consider a pair of operands A′ and B′ that give rise to a maximum ripple distance without producing an overflow. For example, A′ may be “101 . . . 111” and B′ may be “000 . . . 001”, both of which are in the two's complement domain. The sum of this critical-path addition, S′, is then “110 . . . 000.” Since S′ is a negative value based on its most significant bit being 1, its conversion to a signed-magnitude representation requires flipping its magnitude bits, generating 101 . . . 111, and subsequently added by 000 . . . 001, which initiates another round of maximum ripple length addition. Hence, the total ripple distance of this operation is 2N−2, where N is the bit width of operands A′ and B′.
Now consider a pair of operands A″ and B″ that give rise to a maximum ripple distance in a one's complement-based adder, such as adder 200 of
In certain embodiments, other adder architectures may be used to implement the adder designs of
Referring now to
Referring now to
The HDTV 320 may communicate with mass data storage 327 that stores data in a nonvolatile manner such as optical and/or magnetic storage devices including hard disk drives (HDDs) and digital versatile disk (DVD) drives. The HDD may be a mini HDD that includes one or more platters having a diameter that is smaller than approximately 1.8″. The HDTV 320 may be connected to memory 328 such as RAM, ROM, low latency nonvolatile memory such as flash memory and/or other suitable electronic data storage. The HDTV 320 also may support connections with a WLAN via the WLAN interface 329.
Referring now to
The present invention may also be implemented in other control systems 340 of the vehicle 330. The control system 340 may likewise receive signals from input sensors 342 and/or output control signals to one or more output devices 344. In some implementations, the control system 340 may be part of an anti-lock braking system (ABS), a navigation system, a telematics system, a vehicle telematics system, a lane departure system, an adaptive cruise control system, a vehicle entertainment system such as a stereo, DVD, compact disc and the like. Still other implementations are contemplated.
The powertrain control system 332 may communicate with mass data storage 346 that stores data in a nonvolatile manner. The mass data storage 346 may include optical and/or magnetic storage devices such as hard disk drives (HDDs) and/or DVD drives. The HDD may be a mini HDD that includes one or more platters having a diameter that is smaller than approximately 1.8″. The powertrain control system 332 may be connected to memory 347 such as RAM, ROM, low latency nonvolatile memory such as flash memory and/or other suitable electronic data storage. The powertrain control system 332 also may support connections with a WLAN via the WLAN interface 348. The control system 340 may also include mass data storage, memory and/or a WLAN interface (all not shown).
Referring now to
The cellular phone 350 may communicate with mass data storage 364 that stores data in a nonvolatile manner such as optical and/or magnetic storage devices including hard disk drives (HDDs) and/or DVD drives. The HDD may be a mini HDD that includes one or more platters having a diameter that is smaller than approximately 1.8″. The cellular phone 350 may be connected to memory 366 such as RAM, ROM, low latency nonvolatile memory such as flash memory and/or other suitable electronic data storage. The cellular phone 350 also may support connections with a WLAN via the WLAN interface 368.
Referring now to
The set top box 380 may communicate with mass data storage 390 that stores data in a nonvolatile manner. The mass data storage 390 may include optical and/or magnetic storage devices such as hard disk drives (HDDs) and/or DVD drives. The HDD may be a mini HDD that includes one or more platters having a diameter that is smaller than approximately 1.8″. The set top box 380 may be connected to memory 394 such as RAM, ROM, low latency nonvolatile memory such as flash memory and/or other suitable electronic data storage. The set top box 380 also may support connections with a WLAN via the WLAN network 396.
Referring now to
The media player 400 may communicate with mass data storage 410 that stores data such as compressed audio and/or video content in a nonvolatile manner. In some implementations, the compressed audio files include files that are compliant with MP3 format or other suitable compressed audio and/or video formats. The mass data storage 410 may include optical and/or magnetic storage devices such as hard disk drives (HDDs) and/or DVD drives. The HDD may be a mini HDD that includes one or more platters having a diameter that is smaller than approximately 1.8″. The media player 400 may be connected to memory 414 such as RAM, ROM, low latency nonvolatile memory such as flash memory and/or other suitable electronic data storage. The media player 400 also may support connections with a WLAN via the WLAN interface 416. Still other implementations in addition to those described above are contemplated.
Thus it is seen that systems and methods for a one's complement adder is provided that offers enhancements in both speed and chip area consumption. One skilled in the art will appreciate that the invention can be practiced by other than the described embodiments, which are presented for purposes of illustration and not of limitation, and the present invention is limited only by the claims which follow.
This application is a continuation of U.S. patent application Ser. No. 11/805,362, filed May 22, 2007 (currently allowed), which claims the benefit under 35 U.S.C. §119(e) of U.S. Provisional Application No. 60/809,747, filed May 31, 2006, each of which is hereby incorporated by reference herein in its entirety.
Number | Name | Date | Kind |
---|---|---|---|
3380027 | Kamm et al. | Apr 1968 | A |
3970833 | Gehweiler | Jul 1976 | A |
4099248 | Borgerson et al. | Jul 1978 | A |
4298952 | Guenthner et al. | Nov 1981 | A |
5159568 | Adiletta et al. | Oct 1992 | A |
5267187 | Hsieh et al. | Nov 1993 | A |
5546335 | Lee | Aug 1996 | A |
6343306 | Lo | Jan 2002 | B1 |
6473529 | Lin | Oct 2002 | B1 |
6523050 | Dhablania et al. | Feb 2003 | B1 |
6671734 | Shimizu | Dec 2003 | B1 |
Number | Date | Country |
---|---|---|
0626638 | Nov 1994 | EP |
Entry |
---|
Balabanian, Norman, and Bradley Carlson; “Digital Logic Design Principles”; Wiley, 2001. |
John Shedletsky, Comment on the Sequential and Indeterminate Behavior of an End-Around-Carry Adder, 1977, IEEE, pp. 271-272. |
Andrew Tanenbaum, “Structured Computer Organization”, 1984, Prentice-Hall, Second Edition, pp. 10-12. |
Tutorial: Twos Complement Numbers, Sep. 19, 2002, Rocky Mountain Computer Consulting Inc, pp. 1-7. |
Andrew Tanenbaum, Structured Computer Organization, 1984, Prentice-Hall International Inc, pp. 10-12. |
Gergen et al., Novel Digital Signal Processing Architecture with Microcontroller Features, Freescale Superconductor, Revision 1, 2005, pp. 1-20. |
UAF Department of Computer Science, CS 301 Class Notes, http://www.cs.uaf.eduJ2000/fa1L/cs3O 1 /notes/Cha ter4/node4.html, 2 pages. |
Jaehong Park et al., 470ps 64bit Parallel Binary Adder, 2000 Symposium on VLSI Circuits, Digest of Technical Papers, 2 pages. |
Jan M. Rabacy et al., Digital Integrated Circuits: A Design Perspective, 2d ed., Prentice Hall, § 11.3, pp. 561-570. |
Yasuhisa Shimazaki et al., A Shared-Well Dual-Supply-Voltage 64-bit ALU, ISSCC 2003, Session 6, Low-Power Digital Techniques, Paper 6.2. |
Number | Date | Country | |
---|---|---|---|
60809747 | May 2006 | US |
Number | Date | Country | |
---|---|---|---|
Parent | 11805362 | May 2007 | US |
Child | 14246773 | US |