JPH0477819A - Multiplier - Google Patents

Multiplier

Info

Publication number
JPH0477819A
JPH0477819A JP18611690A JP18611690A JPH0477819A JP H0477819 A JPH0477819 A JP H0477819A JP 18611690 A JP18611690 A JP 18611690A JP 18611690 A JP18611690 A JP 18611690A JP H0477819 A JPH0477819 A JP H0477819A
Authority
JP
Japan
Prior art keywords
multiplier
bits
multiplication
multiplicand
result
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.)
Pending
Application number
JP18611690A
Other languages
Japanese (ja)
Inventor
Yoshinobu Murakami
善宣 村上
Minoru Kuroda
稔 黒田
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Panasonic Electric Works Co Ltd
Original Assignee
Matsushita Electric Works Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Matsushita Electric Works Ltd filed Critical Matsushita Electric Works Ltd
Priority to JP18611690A priority Critical patent/JPH0477819A/en
Publication of JPH0477819A publication Critical patent/JPH0477819A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To obtain a multiplier in a comparatively ;small gate scale by adding in sequence the results of multiplication carried out between the prescribed bits of the multipliers divided by an S/P multiplication means and a multiplicand to the results of multiplication carried out between the precedent divided prescribed bits and the multiplicand through an adder and then adding together these multipliers and the multiplicand. CONSTITUTION:A full adder 8 adds sequentially the results of multiplication carried out between four bits of the multiplier X divided by an S/P multiplica tion means and amultiplicand Y to the results of multiplication carried out between the multiplicand Y and four bits of the multiplier X divided precedently. Then 64 latches 90 - 963 serving as the 1st storage means store successively the prescribed lower rank bits that are decided based on the result of addition of the adder 8. Furthermore a selector 10 and 32 latches 110 - 1131 serving as the 2nd storage means store successively plural remaining undecided bits, i.e., the results of multiplication excluding those decided bits and then give these results of multiplication in sequence to the adder 8 as the precedent results of multiplication. In such a constitution, a multiplier is obtained in a compara tively small gate scale.

Description

【発明の詳細な説明】 [産業上の利用分野] 本発明は、プログラマブルコントローラ等の演算用に用
いられる乗算器に関するものである。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a multiplier used for calculations in programmable controllers and the like.

[従来の技術] 従来のプログラマブルコントローラ等では第3図に示す
乗算器が演算用に用いられている。こび)乗算器では乗
数と被乗数とを夫々16ビツ1−ずつに分割し、1.6
 X 16ビツトの乗算を4回行って32ビツトの乗数
と32ビツトの被乗数との乗算を行うもので、具体的に
は乗数と被乗数とを夫々32ビツトラツチ151.15
2にラッチしておき、このラッチ151.15□からセ
レクタ161.16□で乗数及び被乗数の上位あるいは
下位の16ビツトを選択し、夫々選択した]6ビツトす
−)の乗数と被乗数との乗算を16 X 16ビントの
並列乗算器17で4回繰り返して行って、その結果を3
2ビツトラツチ18にラッチし、このラッチ]8にラッ
チされた各回の乗算結果をシフタ19により桁自わぜを
行い、桁自わせ後の各回の乗算結果を64ヒツトの加算
器20及び64ビツトラツチ21を用いて加算して、3
2X32ビツトの乗算結果を得るようにしである。なお
、」1記セレクタ161、 t 62及びシフタ19は
2ビツトカウンタ22の切換信号に応じて動作する。
[Prior Art] In a conventional programmable controller, a multiplier shown in FIG. 3 is used for calculation. (difficult) In the multiplier, the multiplier and multiplicand are each divided into 16-bit 1- bits, and 1.6
X 16-bit multiplication is performed four times to multiply a 32-bit multiplier and a 32-bit multiplicand. Specifically, the multiplier and multiplicand are each 32-bit latch 151.15
2, select the upper or lower 16 bits of the multiplier and multiplicand from this latch 151.15□ with the selector 161.16□, and multiply the multiplier of the selected 6 bits by the multiplicand. is repeated four times using a 16 x 16 bit parallel multiplier 17, and the result is
The multiplication results latched in the 2-bit latch 18 are shifted by the shifter 19, and the multiplication results after the shift are sent to the 64-hit adder 20 and the 64-bit latch 21. Add using , 3
This is to obtain a 2×32 bit multiplication result. Note that the selectors 161, t62 and shifter 19 operate according to the switching signal from the 2-bit counter 22.

[発明が解決しようとする課題1 しかしながら、上述の従来の乗算器の構成であると、6
4ヒツl〜の加算器2oを構成するために全加算器が6
4個必要であり、ケート1規模が大きくなるという問題
があった。
[Problem to be solved by the invention 1 However, with the above-mentioned conventional multiplier configuration, 6
6 full adders are used to configure the adder 2o of 4 hits l~.
Since four are required, there is a problem in that the scale of each cage becomes large.

本発明は上述の点に鑑みて為されたものであり、その目
的とするところは、比較的に小さなゲート規模で構成で
きる乗算器を提供することにある。
The present invention has been made in view of the above points, and an object thereof is to provide a multiplier that can be configured with a relatively small gate scale.

1課題を解決するための手段コ 上記目的を達成するために、本発明は乗数を下位ビット
から所定ビット毎に分割し、分割された乗数の下位の所
定ビットがら被乗数と順次乗算する直並列乗算手段と、
この直並列乗算手段による分割された乗数の所定ビット
と被乗数との乗算結果を前回の分割された乗数の所定ビ
ットと被乗数との乗算結果に逐次加算していく加算手段
と、この加算手段による加算結果で確定する下位の所定
ビットを順次記憶していく第1の記憶手段と、上記確定
した所定ビットを除く乗算結果の残りの不確定な複数ビ
ットを順次記憶し上記加算手段に前回の乗算結果として
逐次与える第2の記憶手段とを備えている。
1. Means for Solving the Problems In order to achieve the above object, the present invention divides a multiplier into predetermined bits starting from the lower bits, and performs series-parallel multiplication in which the lower predetermined bits of the divided multiplier are sequentially multiplied by the multiplicand. means and
an addition means for sequentially adding the multiplication result of a predetermined bit of the divided multiplier and the multiplicand by the series-parallel multiplication means to the multiplication result of the previous predetermined bit of the divided multiplier and the multiplicand; A first storage means that sequentially stores lower predetermined bits determined by the result, and a first storage means that sequentially stores the remaining uncertain bits of the multiplication result excluding the determined predetermined bits, and stores the previous multiplication result in the addition means. and a second storage means for sequentially providing the data.

なお、乗数及び被乗数を記憶するラッチの制御を同一ク
ロックで行えるようにする場なには、乗数の上記所定ヒ
ツトと被乗数の各ビットとを乗算するために設けられ被
乗数を下位ピッ1〜がら順次シフl−L、なから−時記
憶する上記直並列乗算手段の被乗数のシフト用の複数個
のう・ソチの個数を少なくとも乗数の分割ビット数の2
倍設ければ良い。
Note that in order to control the multiplier and the latch that stores the multiplicand using the same clock, a multiplier is provided for multiplying each bit of the multiplicand by the predetermined value of the multiplier. Shift l-L, when the number of multiplicands of the serial/parallel multiplication means stored is at least 2 of the number of divided bits of the multiplier.
Just double it.

[作用] 本発明は、上述のように直並列乗算手段で乗数を下位ピ
ッ1へから所定ビット毎に分割し、分割ビット数の乗数
と被乗数との乗算を上記乗数の分割数繰り返して行い、
且−)直並列乗算手段による分割された乗数の所定ビッ
トと被乗数との乗算結果を前回の分割された乗数の所定
ピッI・と被乗数との乗算結果に加算器で逐次加算して
、乗数と被乗数との加算を行うことにより、全加算器の
個数を分割ビット数に1を加えた個数にすることがてき
るようにして、比較的に小さなゲート規模で乗算器を構
成できるようにしたものである。
[Function] As described above, the present invention divides the multiplier into predetermined bits starting from the lower bit 1 using the serial/parallel multiplication means, and repeats the multiplication of the multiplicand by the multiplicand by the number of divided bits,
and-) The result of multiplying the predetermined bits of the divided multiplier by the serial-parallel multiplier and the multiplicand is successively added to the result of multiplying the predetermined bit of the multiplicand by the multiplicand of the previous divided multiplier by an adder, and the multiplier is obtained. By performing addition with the multiplicand, the number of full adders can be made equal to the number of divided bits plus 1, making it possible to configure a multiplier with a relatively small gate scale. It is.

また、乗数の上記所定ビットと被乗数の各ビットとを乗
算するために設けられ被乗数を下位ビットから順次シフ
トしながら一時記憶する上記直並列乗算手段の被乗数の
シフト用の複数個のラッチの個数を少なくとも乗数の分
割ビット数の2倍設けると、乗数の所定ビットと被乗数
との乗算と、乗数の次の所定ビットと被乗数との乗算と
の間に、乗数の所定ビットをクロックに従ってシフトさ
せる期間を設けることができ、乗数及び被乗数を記憶す
るラッチの制御を同一クロックで行えるようにもてきる
Further, the number of latches for shifting the multiplicand of the series/parallel multiplication means is provided for multiplying the predetermined bit of the multiplier by each bit of the multiplicand, and temporarily stores the multiplicand while sequentially shifting the multiplicand from the lower bits. By providing at least twice the number of divided bits of the multiplier, there is a period during which the predetermined bit of the multiplier is shifted according to the clock between the multiplication of the predetermined bit of the multiplier and the multiplicand and the multiplication of the next predetermined bit of the multiplier with the multiplicand. It is also possible to control the latches that store the multiplier and the multiplicand using the same clock.

[実施例]−1 第1図に本発明の一実施例を示す。本実施例の乗算器は
、乗数Xを下位から4ピツ1〜ずつに分け、この4ピツ
I・ずつに分割された乗数Xを下位のものから順次被乗
数Yと乗算して、計8回の直並列乗算を行い、この乗算
結果を桁合わせを行いながら加算して、32ビット×3
2ビットの乗算を結果を得るものである。この乗算器て
は、32ビツトの乗数Xを記憶するラッチ1と、被乗数
Yを記憶するラッチ2と、ラッチ2に記憶された被乗数
Yの下位1ビツトをタロツクに従って順次右シストしな
がらラッチしていく4個のラッチ3゜−33と、ラッチ
1から夫々出力される乗数Xの下位4ビツトX0〜X3
の夫々と上記ラッチ3゜〜33に記憶した被乗数Yの1
ビツトとのアンドをとるアンドゲート4゜〜43と、ア
ンドケート4゜〜43の出力に夫々接続され乗数Xの分
割ビットの桁に応じたクロック数だけアンドゲート4゜
〜43の出力を遅延させるラッチ5゜・5.と、乗数X
の分割ビットの桁毎に設けられ乗数Xと被乗数Yとの1
ビツトずつの加算を行う全加算器60.−63と、全加
算器6゜〜61Iの加算結果を1タロツクだけ保持する
ラッチ7o〜・73とを備え、これら各ゲー1〜により
直並列乗算手段を構成しである。さらに、この乗算器で
は」1記直並列乗算手段の乗算結果を桁合わせを行って
加算して32X32ビツトの乗算結果を得るために、上
記直並列乗算手段による分割された乗数Xの4ビットと
被乗数Yとの乗算結果を前回の分割された乗数Xの4ビ
ツトと被乗数Yとの乗算結果に逐次加算していく加算手
段としての全加算器8と、この全加算器8による加算結
果で確定する下位の所定ピッl−(乗数Xの分割ヒツト
数が4ピツI・であるので、4ビツト)を順次記憶して
いく第1ぴ)記憶手段としての64個のラッチ9゜〜9
63と、」1記確定した所定ビットく4ビツト)を除く
乗算結果び)残りの不確定な複数ビットく直並列乗算手
段による乗数Xの4ビット×被乗数Yの32ビツトの乗
算結果は36ビツトとなるので、不確定なヒラ1〜数は
32ビツトとなる)を順次記憶し、」1記全加算器8に
前回の乗算結果として逐次与える第2y+記憶手段とし
てのセレクタ10及び32個のラッチ]−1゜〜1]3
1とを備えている。なお、この乗算器においては最終的
な32ビツト×32ビツト(64ビツト)の乗算結果か
ラッチ9゜〜96゜から得られる。
[Example]-1 FIG. 1 shows an example of the present invention. The multiplier of this embodiment divides the multiplier X into 4 bits 1 to 4 bits starting from the lowest, and multiplies the divided multiplier Perform series-parallel multiplication and add the multiplication results while aligning the digits to create 32 bits x 3
The result is a 2-bit multiplication. This multiplier consists of a latch 1 that stores a 32-bit multiplier The four latches 3°-33 and the lower 4 bits X0 to X3 of the multiplier X output from latch 1, respectively.
and 1 of the multiplicand Y stored in the latches 3° to 33.
AND gates 4° to 43 that perform AND with the bits are connected to the outputs of AND gates 4° to 43, respectively, and delay the outputs of AND gates 4° to 43 by the number of clocks corresponding to the digit of the divided bit of multiplier X. Latch 5°・5. and multiplier X
1 of the multiplier X and the multiplicand Y provided for each digit of the divided bits of
A full adder 60 that performs bit-by-bit addition. -63, and latches 7o to 73 for holding the addition results of full adders 6° to 61I by one tarlock, and each of these gates 1 to constitutes a series/parallel multiplication means. Furthermore, in this multiplier, in order to obtain a 32x32-bit multiplication result by digit-aligning and adding the multiplication results of the series/parallel multiplier described in item 1, the 4 bits of the multiplier A full adder 8 serves as an addition means that sequentially adds the result of multiplication with the multiplicand Y to the result of multiplication between the 4 bits of the previously divided multiplier 64 latches 9° to 9 as storage means for sequentially storing lower predetermined bits (4 bits since the number of divided hits of the multiplier X is 4 bits)
63, the result of multiplication excluding (1) determined predetermined bits (4 bits) and the remaining uncertain multiple bits (4 bits of multiplier Therefore, the selector 10 and 32 latches serve as a 2nd y+ storage means, which sequentially stores the uncertain numbers 1 to 32 bits, and sequentially supplies them to the full adder 8 as the previous multiplication result. ]-1°~1]3
1. In this multiplier, the final 32 bits x 32 bits (64 bits) multiplication result is obtained from latches 9° to 96°.

以下、本実施例の乗算器の動作を説明する。The operation of the multiplier of this embodiment will be explained below.

まず、タロツクTLlが入力されると、ラッチ2に記憶
された被乗数Yの最下位ビットデータY0をラッチ31
.が−時記憶し、次にクロックT1が入力されると、ラ
ッチ3゜に保持していたビットデータY。がラッチ3.
にシフトされ、ラッチ3゜が新たに被乗数Yの次のとッ
トデータY1を一時記憶するというようにラッチ3.〜
3.はタロツク]゛11に従って順次布シストを行いな
がら被乗数Yのビットデータを記憶していく。この様子
を下記の表ここで、クロックT、が入力された時点では
、アントゲ−1−4、による上記Y。と乗数Xの最下位
ビットデータX0とのアンド出力、つまりは乗数Xと被
乗数Yとの最下位ビットの乗算結果(X、Yo)がラッ
チ5゜に入力される。
First, when the tarokku TLl is input, the least significant bit data Y0 of the multiplicand Y stored in the latch 2 is transferred to the latch 31.
.. When the clock T1 is inputted next time, the bit data Y held in the latch 3° is stored. is the latch 3.
, and latch 3.degree. temporarily stores the next cut data Y1 of multiplicand Y, and so on. ~
3. The bit data of the multiplicand Y is stored while sequentially performing cloth storage according to the tarokku] 11. This situation is shown in the table below. Here, at the time when clock T is input, the above Y by Antogame 1-4 is input. and the least significant bit data X0 of the multiplier X, that is, the result of multiplying the least significant bit of the multiplier X and the multiplicand Y (X, Yo) is input to the latch 5°.

次に、タロツクT2が入力された時点て、ラッチ5゜に
保持していた乗算結果(xoy、、)が全加算器6゜に
入力され、全加算結果がラッチ7゜に記憶される。但し
、この全加算器6゜は最下位桁であり、桁上げ入力がな
いので、ラッチ7゜にはアンドゲート4゜の出力(X 
o Y o >がそのまま記憶されることになる。この
とき、アンドゲート4゜による乗算結果(X OY l
)がラッチ5.に入力され、アンドゲート41による乗
算結果(x+yo>がラッチ51に入力される。
Next, when the tarlock T2 is input, the multiplication result (xoy, . . . ) held in the latch 5° is input to the full adder 6°, and the full addition result is stored in the latch 7°. However, since this full adder 6° is the least significant digit and there is no carry input, latch 7° receives the output of AND gate 4° (X
o Y o > will be stored as is. At this time, the multiplication result (X OY l
) is the latch 5. The multiplication result (x+yo>) by the AND gate 41 is input to the latch 51.

クロックT3が入力されると、全加算器6、で上記ラッ
チ7゜に保持された加算結果(X o Y a >とラ
ッチ52に保持された乗算結果との加算が行われる。但
し、このタロツクT3か入力された時点ではラッチ51
からラッチ52にアンドゲート4.の乗算結果(XIY
o)がシフl〜されるだけで、ラッチ52からは全加算
器6Iに乗算結果が入力されないので、全加算器6Iの
加算結果はX。Y、となり、この加算結果(x OY 
o)はラッチ7、で保持される。
When the clock T3 is input, the full adder 6 adds the addition result (X o Y a > held in the latch 7°) and the multiplication result held in the latch 52. When T3 is input, latch 51
to latch 52 and gate 4. Multiplication result (XIY
o) is only shifted l~, and the multiplication result is not input to the full adder 6I from the latch 52, so the addition result of the full adder 6I is X. Y, and this addition result (x OY
o) is held by latch 7.

二のとき、全加算器6゜には新たにアンドゲート4゜の
乗算結果(XoYl)がラッチ5゜から入力され、全加
算器6゜の加算結果としてラッチ7のにX。Yが保持さ
れる。これと同時にラッチ5゜にアンドゲート4 oの
新たな乗算結果(X o Y 2 )が入力され、ラッ
チ5.に保持していた乗算結果(XIYo)がラッチ5
2にシフトされると共に、アンドゲート4の新たな乗算
結果(x+y+)がラッチ5.に入力され、ラッチ5.
にアンドゲート42の乗算結果(X2’1’0)が入力
される。
2, the multiplication result (XoYl) of the AND gate 4° is newly inputted to the full adder 6° from the latch 5°, and X is input to the latch 7 as the addition result of the full adder 6°. Y is retained. At the same time, the new multiplication result (X o Y 2 ) of the AND gate 4 o is input to the latch 5°, and the latch 5. The multiplication result (XIYo) held in latch 5
At the same time, the new multiplication result (x+y+) of AND gate 4 is shifted to latch 5. is input to latch 5.
The multiplication result (X2'1'0) of the AND gate 42 is input to.

クロックT、が入力されると、全加算器6□で上記ラッ
チ7、に保持された加算結果(xoy、)とラッチ55
に保持された乗算結果との加算が行われる。但し、この
クロックT、が入力された時点ではラッチ5.に記憶し
た乗算結果(X2YO)がラッチ5.にシストされる状
態にあり、ラッチ55からは全加算器62に乗算結果が
入力されないので、全加算器62の加算結果はX。Yo
となり、この加算結果〈XoYLl〉はラッチ7□て保
持される。このとき、全加算器61では上記ラッチ7 
(+に保持された加算結果(X oY + )とラッチ
52に保持された乗算結果(X IY o)との加算が
行われ、その加算結果(XIYO+XoY、)がラッチ
7、で保持される。さらに、全加算器6゜には新たにア
ンドゲート4゜の乗算結果(X。Y、)がラッチ5゜か
ら入力され、全加算器6゜の加算結果としてラッチ7゜
にX。Y2が保持される。これと同時に、ラッチ5゜に
乗算結果(XoY]>、ラッチ51に乗算結果(XIY
2)が入力され、ラッチ52に乗算結果くX1Y1)が
シストされ、ラッチ53に乗算結果(X2Yl)が入力
され、ラッチ5.に乗算結果(x2YO)がシストされ
、さらにラッチ56にアンドゲート43による乗算結果
(X:1YO)が入力される。
When the clock T is input, the full adder 6□ adds the addition result (xoy,) held in the latch 7 and the latch 55.
Addition is performed with the multiplication result held in . However, when this clock T is input, latch 5. The multiplication result (X2YO) stored in latch 5. Since the latch 55 does not input the multiplication result to the full adder 62, the addition result of the full adder 62 is X. Yo
The addition result <XoYLl> is held in the latch 7□. At this time, in the full adder 61, the latch 7
(The addition result (X oY + ) held in + and the multiplication result (X IY o) held in the latch 52 is performed, and the addition result (XIYO+XoY,) is held in the latch 7. Furthermore, the multiplication result (X, Y,) of the AND gate 4° is newly inputted to the full adder 6° from the latch 5°, and X, Y2 is held in the latch 7° as the addition result of the full adder 6°. At the same time, the multiplication result (XoY]> is applied to the latch 5°, and the multiplication result (XIY) is applied to the latch 51.
2) is input, the multiplication result (X1Y1) is input to the latch 52, the multiplication result (X2Y1) is input to the latch 53, and the multiplication result (X2Y1) is input to the latch 53. The multiplication result (x2YO) is input to the latch 56, and the multiplication result (X:1YO) by the AND gate 43 is input to the latch 56.

クロックT、か入力された時点ては、全加算器6、の加
算結果が」二連の場斤と同様にしてX。Y。
When the clock T is input, the addition result of the full adder 6 is "X" in the same way as in the double case. Y.

となり、この加算結果(xoYo)がラッチ73に保持
される。また、全加算器6.ではラッチ7、に保持され
た加算結果(x + y o + x OY I >と
ラッチ55との加算を行う。この場合にもラッチ5.に
は乗算結果がシストされていないので、全加算器6□の
加算結果はX、 + Y o + X o Y 1とな
り、この加算結果がラッチ7、で保持される。全加算器
6.ではラッチ7゜に保持された加算結果くχ。Y2)
とラッチ52に保持された乗算結果(XIYI>との加
算が行jわれ、この加算結果(x + y + + x
 OY 2 )がラッチ7で保持される。この時点にお
ける全加算器6゜の加算結果はX。Y3となり、この加
算結果がラッチ7oに入力される。さらに、これと同時
に、ラッチ50.5+、53.5Gに夫々X、Y、、X
、Y、、X2Y2、x3y、が入力され、ラッチ52.
5−.55.57にX、 I ¥3、X 2 Y 1.
 X 2 Y o 、 X 3Y +がシストされる。
This addition result (xoYo) is held in the latch 73. Also, full adder 6. Then, the addition result held in latch 7 (x + y o + x OY I The addition result of 6□ is X, + Y o + X o Y 1, and this addition result is held in latch 7. In full adder 6, the addition result held in latch 7° is χ.Y2)
and the multiplication result (XIYI> held in the latch 52), and this addition result (x + y + + x
OY 2 ) is held by latch 7. The addition result of the full adder 6° at this point is X. Y3, and this addition result is input to the latch 7o. Furthermore, at the same time, latches 50.5+ and 53.5G are connected to X, Y, , X, respectively.
, Y, , X2Y2, x3y are input, and the latch 52 .
5-. 55.57 to X, I ¥3, X 2 Y 1.
X 2 Y o , X 3Y + are cysted.

タロツクT6が入力されると、全加算器63〜6゜の夫
々の加算結果か、X、Yo−1−X、Y、、X 2 Y
 o 十XIY1+XoY2、X、Y2+XOY、、X
 o Y 4となり、以下同様にして乗数Xの下位4ビ
ツトど被乗数Yとの直並列乗算が行われ、表2に示す演
算結果が得られる。そして、上述の直並列乗算が終了し
た時点で、乗数Xの4ピツ1へをシフl−した後に、次
の4ビツト・と被乗数Yとの直並列乗算を同様に行うと
いうようにして、乗数Xの上位4ビツトまで計8回の被
乗数Yとの直並列乗算を繰り返す。
When the tally clock T6 is input, the addition results of the full adders 63 to 6 degrees, X, Yo-1-X, Y, , X 2 Y
o 10XIY1+XoY2, X, Y2+XOY,,X
o Y 4, and the lower 4 bits of the multiplier X are serially and parallel multiplied with the multiplicand Y in the same manner, and the calculation results shown in Table 2 are obtained. Then, when the above-mentioned series-parallel multiplication is completed, after shifting the multiplier The series-parallel multiplication with the multiplicand Y is repeated up to the upper 4 bits of X a total of 8 times.

−/l− 上述のようにして乗数Xの4ビツトと被乗数Yとの直並
列乗算を行った桁毎の結果であるラッチ73に保持され
た加算結果は全加算器8に逐次入力°される。今、乗数
Xの下位4ピツ1へと被乗数Yとの直並列乗算を行って
いるとすると、この場合には最初の直並列乗算であるの
て、ラッチ1]−o〜113、には何らのデータも記憶
されていない。従って、全加算器8の結果はそのままラ
ッチ73に保持された直並列乗算結果となる。
-/l- The addition result held in the latch 73, which is the result for each digit of serial-parallel multiplication of the 4 bits of the multiplier . Now, suppose we are performing series-parallel multiplication with the multiplicand Y to the lower four bits 1 of the multiplier data is also not stored. Therefore, the result of the full adder 8 becomes the serial/parallel multiplication result held in the latch 73 as it is.

ところで、本実施例の場合の乗数Xの4ビツト。By the way, in this embodiment, the multiplier X has 4 bits.

と被乗数)lとの直並列乗算は、表3中に平行四辺例え
ば乗数Xの下位4ビツトと被乗数Yとの直並列乗算を行
った結果の下位4ビツトのデータP。・・P、は、その
上の乗数Xの4ビツトと被乗数Yとの直並列乗算の結果
を待たずに確定することになる。よって、本実施例の場
合には、その確定ヒツトデータとしての下位4ビツトデ
ータP。〜P3をラッチ9゜〜963に記憶する。そし
て、セレクタ10で残りのビットデータを選択してラッ
チ11゜〜1131に記憶する。、二こて°、4ヒツト
×32ビツトの乗算を行った場合の乗算結果は36ビツ
トとなるので、上記4ピツI・の確定ビットを除くと、
32ビツトのデータがラッチ1.1o〜113.に逐次
記憶されることになる。
The series/parallel multiplication of the multiplicand (x) and the multiplicand (l) is the data P of the lower 4 bits as a result of serial/parallel multiplication of the lower 4 bits of the multiplier X and the multiplicand Y. . . P is determined without waiting for the result of serial-parallel multiplication between the 4 bits of the multiplier X above it and the multiplicand Y. Therefore, in the case of this embodiment, the lower 4 bit data P is the confirmed hit data. ~P3 is stored in the latch 9°~963. Then, the remaining bit data is selected by the selector 10 and stored in the latches 11° to 1131. , 2 irons, 4 hits x 32 bits, the result of the multiplication is 36 bits, so if we exclude the definite bits of the above 4 bits, we get
32 bits of data are stored in latches 1.1o to 113. will be stored sequentially.

その後、乗数Xの次の4ビツトと被乗数Yとの直並列乗
算を行った場合、全加算器8ではラッチ73に保持され
たデータを逐次ラッチ11o〜11゜に記憶したデータ
と加算していく。この際にも、下位4ビットデータP、
〜P7は乗数Xのさらに上位の4ピツl〜と被乗数Yと
の直並列乗算を待たずに確定するので、このデータP、
・F”7をラッチ9゜〜963に記憶し、残りのデータ
をセレクタ10を介してラッチllo〜113.に記憶
していく。このようにして演算を繰り返して行えば、乗
数Xの上位4ビツトと被乗数Yの直並列乗算により最後
の36ビツトデータP211〜F’63が確定して、ラ
ッチ9o〜963に記憶されたデータが乗数Xの32ビ
ット×被乗数Yの32ビツトの乗算結果となる。本実施
例の乗算器のように構成すれば、全加算器を5個にする
ことができ、比較的に小さいゲート規模て乗算器を構成
することができる。
After that, when serial-parallel multiplication is performed between the next 4 bits of the multiplier . At this time, the lower 4 bits data P,
~P7 is determined without waiting for the series-parallel multiplication of the higher-order 4 bits l~ of the multiplier X and the multiplicand Y, so this data P,
・F”7 is stored in latches 9° to 963, and the remaining data is stored in latches llo to 113. via the selector 10. If the calculation is repeated in this way, the top four The last 36-bit data P211 to F'63 are determined by series-parallel multiplication of the bits and the multiplicand Y, and the data stored in the latches 9o to 963 becomes the multiplication result of 32 bits of the multiplier X x 32 bits of the multiplicand Y. If the multiplier of this embodiment is configured, the number of full adders can be reduced to five, and the multiplier can be configured with a relatively small gate scale.

[実施例2] 第2図に本発明の他の実施例を示す。本実族□例では第
1の実施例のラッチ3゜〜33の後段に4個のラッチ3
.〜37を付加したもので、その他の構成は第1の実施
例と全・く同しものである。
[Example 2] FIG. 2 shows another example of the present invention. In this example, four latches 3 are installed after the latches 3 to 33 of the first embodiment.
.. 37 are added, and the other configurations are completely the same as the first embodiment.

上述の第1の実施例の場合、乗数Xの4ビツトと被乗数
Yの直並列乗算の演算終了時点で、ラッチ1の乗数Xを
4ビツトシフトさせた後に乗数Xの次の4ビツトと被乗
数Yとの演算を行わなればならず、このためラッチ1.
2のクロックタイミングを異ならせなけれはならず、ラ
ッチ1.2の制御が複雑になる。そこで、この点を改良
するために、本実施例では上述のようにラッチ3゜へ3
3の後段に4個のラッチ3.〜37を付加した。このよ
うにすれば、乗数Xの次の4ピツ■・と被乗数Yとの直
並列乗算を行う前に、5クロツク分く表4のT35〜T
39参照)たけラッチ33、−33をデータが0の状態
にすることができ、この間の4クロツクを乗数χのビッ
トのシフト用のタロツクとして用いれば、ラッチ1,2
のタロツクを変えずに済む[発明の効果] 本発明は上述のように、乗数を下位ビットから所定ビッ
ト毎に分割し、分割された乗数の下位の所定ビットから
被乗数と順次乗算する直並列乗算手段と、この直並列乗
算手段による分割された乗数の所定ビットと被乗数との
乗算結果を前回の分割された乗数の所定ビットと被乗数
との乗算結果に逐次加算していく加算手段と、この加算
手段による加算結果て確定する下位の所定ビットを順次
記憶していく第1の記憶手段と、上記確定した所定ビッ
トを除く乗算結果の残りの不確定な複数ビットを抽出し
て順次記憶し上記加算手段に前回の乗算結果として逐次
与える第2の記憶手段とを備えているので、全加算器の
個数を分割ビット数に1を加えた個数に削減することが
でき、比較的に小さなゲート規模で乗算器を構成できる
In the case of the first embodiment described above, at the end of the serial/parallel multiplication of the 4 bits of the multiplier X and the multiplicand Y, the multiplier Therefore, latch 1.
The clock timings of latches 1.2 and 2 must be made different, which complicates the control of latch 1.2. Therefore, in order to improve this point, in this embodiment, as described above, the latch 3°
4 latches after 3 3. ~37 was added. In this way, before serial-parallel multiplication of the next 4 bits of the multiplier X and the multiplicand Y, it is possible to
(Refer to 39) It is possible to set the data in the latches 33 and -33 to 0, and if the four clocks during this time are used as tarlocks for shifting the bits of the multiplier χ, the latches 1 and 2
[Effects of the Invention] As described above, the present invention is a series-parallel multiplication method in which a multiplier is divided into predetermined bits starting from the lower bits, and the multiplicand is sequentially multiplied from the lower predetermined bits of the divided multiplier. means, an addition means for sequentially adding the result of multiplication of a predetermined bit of the divided multiplier and the multiplicand by the series-parallel multiplication means to the result of multiplication of the predetermined bit of the previous divided multiplier and the multiplicand; a first storage means for sequentially storing lower predetermined bits determined by the addition result by the means; and a first storage means for sequentially storing lower predetermined bits determined as a result of the addition by the means; Since the means is equipped with a second storage means that sequentially supplies the result of the previous multiplication to the means, the number of full adders can be reduced to the number of divided bits plus 1, and the gate size is relatively small. Multipliers can be configured.

また、乗数の上記所定ビットと被乗数の各ビットとを乗
算するために設けられ被乗数を下位ビットから順次シフ
トシながら一時記憶する上記直並列乗算手段の被乗数の
シフト用の複数個のラッチの個数を少なくとも乗数の分
割ビット数の2倍設けると、乗数の所定ピッl−と被乗
数との乗算と、乗数の次の所定ビットと被乗数との乗算
との間に、乗数の所定ビットをクロックに従ってシフト
させる期間を設けることができ、乗数及び被乗数を記憶
するラッチの制御を同一クロックで行える。
In addition, the number of latches for shifting the multiplicand of the series/parallel multiplication means provided for multiplying the predetermined bit of the multiplier by each bit of the multiplicand and temporarily storing the multiplicand while sequentially shifting the multiplicand from the lower bits is set at least. If twice the number of divided bits of the multiplier is provided, a period during which a predetermined bit of the multiplier is shifted according to the clock between the multiplication of a predetermined bit of the multiplier and the multiplicand and the multiplication of the next predetermined bit of the multiplier and the multiplicand. can be provided, and the latches that store the multiplier and the multiplicand can be controlled with the same clock.

【図面の簡単な説明】[Brief explanation of drawings]

第1図は本発明の一実施例の構成図5第2図は他の実施
例の構成図、第3図は従来例の構成図である。 Xけ乗数、Yは被乗数、1.2.31〜3y、5o〜5
5,7o〜73.90〜9+13.1.10〜]−1,
、はラッチ、4゜〜43はアンドゲート、6o〜61,
8は全加算器、]0はセレクタ、3o〜37はラッチで
ある。 代理人 弁理士 石 1)長 七
FIG. 1 is a block diagram of one embodiment of the present invention. FIG. 2 is a block diagram of another embodiment, and FIG. 3 is a block diagram of a conventional example. X times multiplier, Y is multiplicand, 1.2.31~3y, 5o~5
5,7o~73.90~9+13.1.10~]-1,
, is a latch, 4° to 43 is an and gate, 6o to 61,
8 is a full adder, ]0 is a selector, and 3o to 37 are latches. Agent Patent Attorney Ishi 1) Choshichi

Claims (2)

【特許請求の範囲】[Claims] (1)乗数を下位ビットから所定ビット毎に分割し、分
割された乗数の下位の所定ビットから被乗数と順次乗算
する直並列乗算手段と、この直並列乗算手段による分割
された乗数の所定ビットと被乗数との乗算結果を前回の
分割された乗数の所定ビットと被乗数との乗算結果に逐
次加算していく加算手段と、この加算手段による加算結
果で確定する下位の所定ビットを順次記憶していく第1
の記憶手段と、上記確定した所定ビットを除く乗算結果
の残りの不確定な複数ビットを抽出して順次記憶し上記
加算手段に前回の乗算結果として逐次与える第2つ記憶
手段とを備えて成る乗算器。
(1) A series/parallel multiplication means that divides a multiplier into predetermined bits starting from the lower bits and sequentially multiplies the divided multiplier by a multiplicand starting from the lower predetermined bits, and predetermined bits of the multiplier divided by the series/parallel multiplication means. Adding means for sequentially adding the result of multiplication with the multiplicand to the multiplication result of the predetermined bits of the previously divided multiplier and the multiplicand, and sequentially storing lower predetermined bits determined by the addition result by the addition means. 1st
and a second storage means that extracts and sequentially stores the remaining uncertain bits of the multiplication result excluding the determined predetermined bits, and sequentially supplies the same to the addition means as the previous multiplication result. Multiplier.
(2)乗数の上記所定ビットと被乗数の各ビットとを乗
算するために設けられ被乗数を下位ビットから順次シフ
トしながら一時記憶する上記直並列乗算手段の被乗数の
シフト用の複数個のラッチの個数を少なくとも乗数の分
割ビット数の2倍設けて成ることを特徴とする請求項1
記載の乗算器。
(2) Number of latches for shifting the multiplicand of the series/parallel multiplication means, which are provided for multiplying the predetermined bit of the multiplier by each bit of the multiplicand, and temporarily store the multiplicand while sequentially shifting the multiplicand from the lower bits. Claim 1 characterized in that the number of divided bits of the multiplier is at least twice as large as the number of divided bits of the multiplier.
Multiplier as described.
JP18611690A 1990-07-14 1990-07-14 Multiplier Pending JPH0477819A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP18611690A JPH0477819A (en) 1990-07-14 1990-07-14 Multiplier

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP18611690A JPH0477819A (en) 1990-07-14 1990-07-14 Multiplier

Publications (1)

Publication Number Publication Date
JPH0477819A true JPH0477819A (en) 1992-03-11

Family

ID=16182644

Family Applications (1)

Application Number Title Priority Date Filing Date
JP18611690A Pending JPH0477819A (en) 1990-07-14 1990-07-14 Multiplier

Country Status (1)

Country Link
JP (1) JPH0477819A (en)

Similar Documents

Publication Publication Date Title
US4525796A (en) Pipelined operation unit for vector data
JP2003346126A (en) Inference system based on probability
JPS6347874A (en) Arithmetic unit
JPS6132437Y2 (en)
JPH0477338B2 (en)
US6519621B1 (en) Arithmetic circuit for accumulative operation
JPS60140429A (en) Decimal notation multiplier system
JPH0234054B2 (en)
JPH0317132B2 (en)
JPS61166628A (en) division device
JPH05197525A (en) Method and circuit for negating operand
JPS58129653A (en) Multiplication system
GB1565460A (en) Fibonacci code adders
CN220208247U (en) Division operation circuit
US3813623A (en) Serial bcd adder
US3192367A (en) Fast multiply system
JPH03265925A (en) Multiplier for programmable controller
JPS6259828B2 (en)
JPH043221A (en) Digital arithmetic unit
JPS60186933A (en) Binary coded decimal multiplication method
JPH0113129B2 (en)
JP3460780B2 (en) Numerical arithmetic unit
JP3477866B2 (en) Divider division method
JPS6115232A (en) Multiplier
JPS61177543A (en) Multiplying device