JPS61131034A - High-speed comparator - Google Patents
High-speed comparatorInfo
- Publication number
- JPS61131034A JPS61131034A JP25215684A JP25215684A JPS61131034A JP S61131034 A JPS61131034 A JP S61131034A JP 25215684 A JP25215684 A JP 25215684A JP 25215684 A JP25215684 A JP 25215684A JP S61131034 A JPS61131034 A JP S61131034A
- Authority
- JP
- Japan
- Prior art keywords
- inverted
- circuit
- numerical values
- carry
- magnitude
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Landscapes
- Manipulation Of Pulses (AREA)
- Hardware Redundancy (AREA)
Abstract
Description
【発明の詳細な説明】
〔産業上の利用分野〕
本発明は2数値の大小を比較するだめの比較器に係り、
特に動作遅延時間を減少させることができるとともに回
路素子数が少い高速比較器に関するものである。[Detailed Description of the Invention] [Industrial Application Field] The present invention relates to a comparator for comparing the magnitude of two numerical values.
In particular, the present invention relates to a high-speed comparator that can reduce operation delay time and has a small number of circuit elements.
従来、2数値の大小を比較するための比較器としては、
排他的論理和の演算を行って比較結果を得るものが一般
に用いられている。Conventionally, as a comparator for comparing the magnitude of two numerical values,
Generally used is one that obtains a comparison result by performing an exclusive OR operation.
第6図は従来の比較器を示したものであって、1−、、
1−2.・・・+ 1−(?L−1) + 1−、はイ
ンバータ、2−4゜2−2.・・・、2−(?L−1)
は排他的論理和(zx−oR)回p、5−1゜3−2.
・・・s 3−(n−1) + 5−n + 4はナン
ド回路である。FIG. 6 shows a conventional comparator, 1-,...
1-2. ...+ 1-(?L-1) + 1- is an inverter, 2-4°2-2. ..., 2-(?L-1)
is exclusive OR (zx-oR) times p, 5-1°3-2.
...s3-(n-1)+5-n+4 is a NAND circuit.
第6図に示された比較器は、2数値A、Elをそれぞれ
次のようにnビット2進表示したとき2数値A、Bの大
小の比較結果’(A>B)を次式の演算によって求める
ものである。The comparator shown in Fig. 6 calculates the comparison result of the magnitude of the two numerical values A and B (A>B) using the following formula when the two numerical values A and El are respectively expressed in n-bit binary as shown below. It is determined by
しかしながら(2)式の演算中における排他的論理和の
演$(■)を行うためには、通常、論理和や論理積の演
算を行う場合に比べて回路素子数を多く必要とし遅延時
間も大きいため、比較器も回路素子数が増大し遅延時間
も大きくなる。However, in order to perform the exclusive OR operation (■) during the operation of equation (2), it usually requires a larger number of circuit elements and a longer delay time than when performing an OR or AND operation. Since the comparator is large, the number of circuit elements in the comparator also increases, and the delay time also increases.
本発明はこのような従来技術の問題点を解決しようとす
るものであって、2数値、4 、 Bの大小の比較を行
う際の演算の方法を変更し排他的論理和演算素子を排除
するようにすることによって、回路素子数および遅延時
間を減少させた比較器を提供しようとするものである。The present invention aims to solve the problems of the prior art, by changing the calculation method when comparing the magnitude of two numerical values, 4, and B, and eliminating the exclusive OR operation element. By doing so, the present invention attempts to provide a comparator with a reduced number of circuit elements and a reduced delay time.
本発明の高速比較器においては、2数値のうちの一方と
他方を論理反転した数値との和を?JIT′Js−シて
キャリーを求める手段を具え、該キャリーの発生によっ
て前記2数値の大小を判定するようにしたものである。In the high-speed comparator of the present invention, the sum of one of the two numerical values and the logically inverted value of the other? JIT'Js is provided with means for determining a carry, and the magnitude of the two numerical values is determined based on the occurrence of the carry.
本発明の高速比較器は、2数値の一方と他方を論理反転
した数値との和を演算してキャリーを求めて、このキャ
リーによって2数値の大小を判定するので、排他的論理
和回路を用いることなく構成することができる。The high-speed comparator of the present invention calculates the carry by calculating the sum of one of the two numerical values and the logically inverted value of the other, and uses this carry to determine the magnitude of the two numerical values, so an exclusive OR circuit is used. It can be configured without any need.
本発明の高速比較器は、2数値、4 、 EにおいてA
からBを滅典した結果が正の数ならば、(≧Bであり、
負の数ならば、4<Bであることを利用して、A、!:
Bとの加尊を行ってキャリーが発生するか否かを判定す
ることによって、比較結果を得るものである。The high speed comparator of the present invention has two numerical values, 4, A in E
If the result of discarding B from is a positive number, then (≧B,
If it is a negative number, using the fact that 4<B, A,! :
A comparison result is obtained by performing a comparison with B and determining whether or not a carry occurs.
ここで2数AとBの加昇は
A−B=A+(−B)=A+(m+t)−A+m+1
・・・(2)でおるから(2)式における1の方を
補正して、演算結果キャリーが発生する場合はA> 8
. 発生しない場合はA≦Bという結果を得ることが
できる。Here, the increase of the two numbers A and B is A-B=A+(-B)=A+(m+t)-A+m+1
...Since (2) is satisfied, correct 1 in equation (2), and if a carry occurs as a result of the operation, A > 8
.. If it does not occur, it is possible to obtain the result that A≦B.
第1図は本発明の第1の実施例を示したものであって、
11−1.11−21・・・+ 11−(n−1) *
11−nはインバータ、12−1はオア回路、12.
、・・・、12−(n−1)はノア回路、13−1.
13−29・・・、13−(、−1)、15−%v14
−1+・・・、14−(3−2) + 14−(n−1
)はナンド回路、15はアンド回路766・
I第1図に示された実施例
は(2)式の両辺に罰を加えることによって、次式
%式%(3)
のように表わされることを利用したものである。FIG. 1 shows a first embodiment of the present invention,
11-1.11-21...+ 11-(n-1) *
11-n is an inverter, 12-1 is an OR circuit, 12.
,..., 12-(n-1) is a NOR circuit, 13-1.
13-29..., 13-(,-1), 15-%v14
-1+..., 14-(3-2) + 14-(n-1
) is a NAND circuit, 15 is an AND circuit 766.
The embodiment shown in FIG. 1 takes advantage of the fact that equation (2) is expressed as the following equation (3) by adding penalties to both sides of equation (2).
2数、(、Bを(1)式のようにnビット2進表示した
とき、(3)式の右辺は次のように表わされる。When the number 2, (, B, is expressed in n-bit binary as in equation (1), the right side of equation (3) is expressed as follows.
、イ+B = ((Lx +b])#((Lr+br+
Gt ・6+) ・(1に+6s+Gr 62+CL1
・bl) ・−・=”(α、&−1””;T< 十”
3−2 ・bs−2+ ”・+tzi ・bx+(Lx
・bt )a(αr&’ rtc+α%−1・bx−
1+−+chφbt+a+・bl’) −L4)第
1図の回路は(4)式を実現したものであり、従って2
数A、13を第1図の回路に入力したとき、ルックアヘ
ッドキャリーすなわちアンド回路15の出力を求め、こ
れが1であればA>Bであり、0であればA≦Bである
と判定する。, i+B = ((Lx +b]) #((Lr+br+
Gt ・6+) ・(1+6s+Gr 62+CL1
・bl) ・-・=”(α, &-1””;T< 10”
3-2 ・bs-2+ ”・+tzi ・bx+(Lx
・bt )a(αr&' rtc+α%-1・bx-
1+-+chφbt+a+・bl') -L4) The circuit in Figure 1 realizes equation (4), and therefore 2
When the numbers A and 13 are input to the circuit shown in Figure 1, the look-ahead carry, that is, the output of the AND circuit 15 is obtained, and if it is 1, it is determined that A>B, and if it is 0, it is determined that A≦B. .
第2図は本発明の第2の実施例を示したものであって、
21−1.21−2.・・・+2l−(3−1)、21
−ユはインバータ、22−、 はオア回路、22−2
y・・・+22−(i−1)・22−?&はノア回路、
23−1,26−2.・・・+23−(s−1) +2
4−1 +・・・、24−(n−2) + 2’−(n
−1)はナンド回路、25はアンド回路である。FIG. 2 shows a second embodiment of the present invention,
21-1.21-2. ...+2l-(3-1), 21
-U is an inverter, 22-, is an OR circuit, 22-2
y...+22-(i-1)・22-? & is Noah circuit,
23-1, 26-2. ...+23-(s-1) +2
4-1 +..., 24-(n-2) + 2'-(n
-1) is a NAND circuit, and 25 is an AND circuit.
2数A、Bを1ビツト2進衣示したとき、(2)式は次
のように表わされる。When the two numbers A and B are expressed in 1-bit binary format, equation (2) can be expressed as follows.
A十B−1−1=(cl+b1 ) ・(CLx+bz
+CL1・bl) ((Ls+b3+(Lx ・b2
+Gs −bt ) −明(αn−1+bn−1+αn
−2・bn−2+”’+α@”b2十α1°b、)・(
−+へ十〇、−1・ζコ+・・・+−・几+L0Ll−
η)・・・(5)第2図の回路は(5)式を実現したも
のである。第2図の回路において2FA、Bを入力した
とき、アンド回路25の出力が1であればA≧8であり
、0であればA<Bでおると判定する。第2図の回路は
第1図の回路と比較して下位のビットの論理のとりがた
を変更することによって、第1図の回路がA>8を判定
するのに対し、A2Bを判定できるようにしたものであ
る。A+B-1-1=(cl+b1) ・(CLx+bz
+CL1・bl) ((Ls+b3+(Lx・b2
+Gs -bt ) -bright(αn-1+bn-1+αn
−2・bn−2+”’+α@”b20α1°b, )・(
-+ to 10, -1・ζko+...+-・几+L0Ll-
η)...(5) The circuit shown in FIG. 2 realizes equation (5). In the circuit of FIG. 2, when 2FA and B are input, if the output of the AND circuit 25 is 1, it is determined that A≧8, and if it is 0, it is determined that A<B. By changing the logic of the lower bits compared to the circuit in Figure 1, the circuit in Figure 2 can determine A2B, whereas the circuit in Figure 1 determines A>8. This is how it was done.
第5図は本発明の第6の実施例を示したものであって、
31−1+3l−zt・・・+31−(s−1) +3
1−sはインバータ、32−1はオア回路、52−2.
・・・s 32−(3−1) 、52−nはノア回路、
33−1 、55−2 、・・・+ 3”−(f&−1
) e 55−n+ 54−1 + ・・・。FIG. 5 shows a sixth embodiment of the present invention,
31-1+3l-zt...+31-(s-1) +3
1-s is an inverter, 32-1 is an OR circuit, 52-2.
...s32-(3-1), 52-n is a NOR circuit,
33-1, 55-2,...+3"-(f&-1
) e 55-n+ 54-1 +...
”’−(w−2) + 34−(a−1) 、54−n
はナンド回路、35はアンド回路である。”'-(w-2) + 34-(a-1), 54-n
is a NAND circuit, and 35 is an AND circuit.
第6図の実施例は切換人力Cを有し、Cの値によって第
1図の実施例と同様にA>8の判定を行うか、第2図の
実施例と同様にA2Bの判定を行うかを切り換えて実行
することかで“含るようにしたものであって、次式を実
現したものである。The embodiment of FIG. 6 has a switching force C, and depending on the value of C, it is determined whether A>8 as in the embodiment of FIG. 1 or A2B is determined as in the embodiment of FIG. By switching between the two and executing the two, the following formula is realized.
(a1+o1)−(az+oz+α1”’1)・(α3
+o3+c2−o2+α1”’1)・・・・明(0%−
1+br&−1+cL+s−2°ロ÷・・+〇2”’2
+αl・bl)−((L、+b、 +cL、−I J、
−1+−+ (L2 ・62 + Gl 鷹)・(S+
α1人十〇、−1・ζコ+・・・+−・ら+α1・11
) ・・・(6)第4図は本発明の第4の実施例を示
したものであって、41−1〜41−7はインバータ、
421+42−4はオア回路、42−2 + 42−s
+ 42−5 t 42−6はノア回路145−1〜
45−7 、4.fL、〜44−3.45.46−1〜
46−3はナンド回路、47はアンド回路である。(a1+o1)-(az+oz+α1”'1)・(α3
+o3+c2-o2+α1'''1)...Bright (0%-
1+br&-1+cL+s-2°ro÷...+〇2'''2
+αl・bl) −((L, +b, +cL, −I J,
-1+-+ (L2 ・62 + Gl Hawk)・(S+
α1 person 10, -1・ζko+・・・+−・ra+α1・11
) (6) FIG. 4 shows a fourth embodiment of the present invention, in which 41-1 to 41-7 are inverters;
421+42-4 is OR circuit, 42-2 + 42-s
+ 42-5 t 42-6 is the NOR circuit 145-1~
45-7, 4. fL, ~44-3.45.46-1~
46-3 is a NAND circuit, and 47 is an AND circuit.
縞4図の実施例はビット数が多い場合に回路規模が大き
くなることを避けるため、数ビットで区切って回路構成
した例を示し、このようにすることによって回路素子数
を節約することができる。The example shown in the striped diagram 4 shows an example in which the circuit is configured by dividing it into several bits in order to avoid increasing the circuit size when the number of bits is large. By doing this, the number of circuit elements can be saved. .
第4図の実施例は第1図の実施例と同様に、A+8の演
算を次式によって実現するものである。The embodiment shown in FIG. 4, like the embodiment shown in FIG. 1, realizes the calculation of A+8 using the following equation.
A十B −(自+5)・偶+ら十αl・6)・(α3+
ら+α2・ら+α1・ら°)・・・(7)
第5図は本発明の第5の実施例を示したものであって、
51−+ 、 51−21・・・+5’−(、&−1)
、51−ユはインバータ、52−1.52−2 、・・
・+ 52−(n−1) + 52−s + 53−1
、53−21’−”・。A 10 B - (self + 5)・even + 10 αl ・6) ・(α 3 +
ra+α2・ra+α1・ra°) (7) FIG. 5 shows a fifth embodiment of the present invention,
51-+, 51-21...+5'-(, &-1)
, 51-U is an inverter, 52-1.52-2 ,...
・+ 52-(n-1) + 52-s + 53-1
, 53-21'-".
53−(w−1) +54−1 +54−2+・・・、
54−(、−1)はアンド回路、5s−1,55−2、
・・・+55−(s−+)はオア回路である。53-(w-1) +54-1 +54-2+...,
54-(,-1) is an AND circuit, 5s-1, 55-2,
...+55-(s-+) is an OR circuit.
第5図の実施例は上述の第1図ないし第4図の実施例と
異なシ、ルックアヘッドキャリーを用いるかわりにリプ
ルキャリーを用いて判定するようにしたものである。n
ビット2進表示の2数A、Hの大小の比較は、次式を演
算したときのキャリーの発生の可熱によって判定するこ
とができる。The embodiment shown in FIG. 5 is different from the embodiments shown in FIGS. 1 to 4 described above, in that instead of using look-ahead carry, ripple carry is used for determination. n
The comparison of the magnitude of the two numbers A and H in bit binary representation can be determined based on the heating of the occurrence of carry when the following equation is calculated.
第5図の実施例は(8)式を実現したものであって、2
数A、Bを第5図の回路に入力したときりプルキャリ
ーすなわちオア回路55−1の出力を求めて、−□これ
が1であればA>8であり0であればA≦Bであると判
定する。The embodiment shown in FIG. 5 realizes equation (8), and has 2
When the numbers A and B are input to the circuit shown in Fig. 5, the output of the pull-carry or OR circuit 55-1 is obtained, -□If this is 1, A>8, and if it is 0, A≦B. It is determined that
第5図の実施例では、演J11:遅延時間が大きくなる
が、それを問題にしなければ大喝な回路素子の節約を行
うことができる。In the embodiment shown in FIG. 5, the delay time increases; however, if this is not a problem, a considerable saving in circuit elements can be achieved.
以上説明したように本発明の高速比較器によれば、2数
値の一方と他方を論理反転した数値との和を演算してキ
ャリーを求め、このキャリーによって2数値の大小を判
定するようにしたので、排他的論理和回路を用いること
なく比較器を構成することができ、従って必要な回路素
子数を減少するとともに、遅延時間も短くすることがで
きる。As explained above, according to the high-speed comparator of the present invention, the carry is calculated by calculating the sum of one of the two numerical values and the logically inverted value of the other, and the magnitude of the two numerical values is determined based on this carry. Therefore, the comparator can be configured without using an exclusive OR circuit, and therefore the number of necessary circuit elements can be reduced and the delay time can also be shortened.
第1図ないし第5図はそれぞれ本発明の高速比較器の一
実施例を示す図、第6図は従来の比較器を示す図である
。
1−+ + 1−2 +””+ 1ペルー1)+1−s
*111j11−2+11−(ルー1)。
IL、、211.21−2.・・・、2l−(31)、
2l−sjl 1+31−2+・・・。
3l−Cn−1)、3l−n141−+〜41−7.5
l−1151−2s”’*5l−(F&−1)+5L、
:インバータ、2−1+22+・・・、2−(n−1
) ’排他的ta 連相(Ex−oR) 回路、5−
1 t 3−2 s”’r !’−(1%−1) +
3−””;Jl !’−1t 13−2 +””+ 1
3−(s−1) + 1 !’−3+ 1 a−4+”
”+ 14−Cr&−2) 114−(ルー1)+25
−1+23−2+・”123−(F&−1)+24−1
+24−Cn−2)+24−(,5−1)+33−1e
33−2+・・・+35−(n−1)+ 65−n+3
4−1+・・・。1 to 5 each show an embodiment of the high-speed comparator of the present invention, and FIG. 6 shows a conventional comparator. 1-+ + 1-2 +””+ 1 Peru 1) +1-s
*111j11-2+11-(Rue 1). IL,, 211.21-2. ..., 2l-(31),
2l-sjl 1+31-2+... 3l-Cn-1), 3l-n141-+~41-7.5
l-1151-2s''*5l-(F&-1)+5L,
: Inverter, 2-1+22+..., 2-(n-1
) 'Exclusive ta linked phase (Ex-oR) circuit, 5-
1 t 3-2 s"'r !'-(1%-1) +
3-””;Jl! '-1t 13-2 +""+ 1
3-(s-1) + 1! '-3+ 1 a-4+'
”+14-Cr&-2) 114-(Rue 1)+25
-1+23-2+・”123-(F&-1)+24-1
+24-Cn-2)+24-(,5-1)+33-1e
33-2+...+35-(n-1)+65-n+3
4-1+...
Claims (1)
一方と他方を論理反転した数値との和を演算してキャリ
ーを求める手段を具え、該キャリーの発生によって前記
2数値の大小を判定することを特徴とする高速比較器。A circuit for comparing the magnitude of two numerical values, comprising means for calculating the sum of one of the two numerical values and a logically inverted value of the other to obtain a carry, and determining the magnitude of the two numerical values based on the occurrence of the carry. A high-speed comparator characterized by:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP25215684A JPS61131034A (en) | 1984-11-29 | 1984-11-29 | High-speed comparator |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP25215684A JPS61131034A (en) | 1984-11-29 | 1984-11-29 | High-speed comparator |
Publications (2)
Publication Number | Publication Date |
---|---|
JPS61131034A true JPS61131034A (en) | 1986-06-18 |
JPH0370250B2 JPH0370250B2 (en) | 1991-11-07 |
Family
ID=17233259
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP25215684A Granted JPS61131034A (en) | 1984-11-29 | 1984-11-29 | High-speed comparator |
Country Status (1)
Country | Link |
---|---|
JP (1) | JPS61131034A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR100429892B1 (en) * | 2002-08-26 | 2004-05-03 | 삼성전자주식회사 | High speed binary comparator circuit and High speed binary data comparison method |
KR100824378B1 (en) * | 2001-06-26 | 2008-04-22 | 삼성전자주식회사 | Apparatus for comparing bit reverse amplitude of word and method thereof |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS5127978A (en) * | 1974-09-02 | 1976-03-09 | Tokyo Koon Denpa Kk |
-
1984
- 1984-11-29 JP JP25215684A patent/JPS61131034A/en active Granted
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS5127978A (en) * | 1974-09-02 | 1976-03-09 | Tokyo Koon Denpa Kk |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR100824378B1 (en) * | 2001-06-26 | 2008-04-22 | 삼성전자주식회사 | Apparatus for comparing bit reverse amplitude of word and method thereof |
KR100429892B1 (en) * | 2002-08-26 | 2004-05-03 | 삼성전자주식회사 | High speed binary comparator circuit and High speed binary data comparison method |
Also Published As
Publication number | Publication date |
---|---|
JPH0370250B2 (en) | 1991-11-07 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Solinas | Generalized mersenne numbers | |
US5289397A (en) | High-speed modulo exponentiator device | |
JPS61131034A (en) | High-speed comparator | |
JP3388819B2 (en) | Process for executing numerical calculation and arithmetic unit for implementing the process | |
US5144577A (en) | Two-sum comparator | |
Ganguly et al. | A unified flagged prefix constant addition-subtraction scheme for design of area and power efficient binary floating-point and constant integer arithmetic circuits | |
Matutino et al. | Binary-to-RNS Conversion Units for moduli {2^ n±3} | |
US5954788A (en) | Apparatus for performing modular multiplication | |
WO2018209978A1 (en) | Xiu-accumulation register, xiu-accumulation register circuit and electronic device | |
Langroudi et al. | Modulo-(2^ n--2^ q--1) Parallel Prefix Addition via Excess-Modulo Encoding of Residues | |
Tawfik et al. | High-speed area-efficient inner-product processor | |
Sathyabhama et al. | Area and power efficient carry select adder using 8T full adder | |
Phalguna et al. | RNS-to-Binary Converters for New Three-Moduli Sets {2 k− 3, 2 k− 2, 2 k− 1} and {2 k+ 1, 2 k+ 2, 2 k+ 3} | |
US5922043A (en) | Reduced hardware linear interpolator | |
Bloom et al. | On bijections for pattern-avoiding permutations | |
Gok et al. | Efficient integer multiplication overflow detection circuits | |
Cesari | Parallel implementation of Schönhage's integer GCD algorithm | |
KR100444905B1 (en) | Finite field multiplier | |
Phalguna et al. | Novel RNS-to-binary converters for the three-moduli set {2 m− 1, 2 m, 2 m+ 1} | |
Nagendra et al. | Unifying carry-sum and signed-digital number representations for low power | |
Du et al. | The potential-Ramsey number of K n and K t− k | |
Mathew et al. | Residue-to-Binary Arithmetic Converter for the Moduli Set {2 n-1, 2 n, 2 n+ 1, 2 n+ 1, 2 n-1} | |
Prabagaran et al. | Area Efficient and Low Power Design of Modulo 2 n+ 1 Adder Using Carry Skip Logic | |
Jaberipur et al. | Modulo-(2 q− 3) Multiplication with Fully Modular Partial Product Generation and Reduction | |
KR20060078258A (en) | Division arithmetic unit of variable radix |