JPS59103148A - Multiplying circuit - Google Patents

Multiplying circuit

Info

Publication number
JPS59103148A
JPS59103148A JP21130382A JP21130382A JPS59103148A JP S59103148 A JPS59103148 A JP S59103148A JP 21130382 A JP21130382 A JP 21130382A JP 21130382 A JP21130382 A JP 21130382A JP S59103148 A JPS59103148 A JP S59103148A
Authority
JP
Japan
Prior art keywords
multiplication
bits
data
adder
input
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
JP21130382A
Other languages
Japanese (ja)
Inventor
Hideyuki Hara
秀幸 原
Tadaaki Bando
忠秋 坂東
Shigeo Abe
阿部 重夫
Masao Takato
高藤 政雄
Hidekazu Matsumoto
松本 秀和
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.)
Hitachi Ltd
Original Assignee
Hitachi 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 Hitachi Ltd filed Critical Hitachi Ltd
Priority to JP21130382A priority Critical patent/JPS59103148A/en
Publication of JPS59103148A publication Critical patent/JPS59103148A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F7/00Methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F7/38Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation
    • G06F7/48Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation using non-contact-making devices, e.g. tube, solid state device; using unspecified devices
    • G06F7/483Computations with numbers represented by a non-linear combination of denominational numbers, e.g. rational numbers, logarithmic number system or floating-point numbers
    • G06F7/487Multiplying; Dividing
    • G06F7/4876Multiplying
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2207/00Indexing scheme relating to methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F2207/38Indexing scheme relating to groups G06F7/38 - G06F7/575
    • G06F2207/3804Details
    • G06F2207/3808Details concerning the type of numbers or the way they are handled
    • G06F2207/3852Calculation with most significant digit first

Abstract

PURPOSE:To perform the multiplication beginning from the highest bit without increasing the hardware of an adder by carrying out the multiplication of blocks containing the lowest bits from the multiplication of blocks containing the highest bits. CONSTITUTION:A processor which performs an operation of the floating decimal point data is provided with a host computer 1, interface part 2 and an arithmetic unit 3 having a pipeline stage. Furthermore an FIFO register which selects and supplies the arithmetic result of the unit 3 is added together with a register file 4 having a U-port register, memory part 5, address arithmetic part 6 and a microprogram controller 7. The multiplication is started from the blocks containing the highest bits through the multiplication of the blocks containing the lowest bits. The result of multiplication of a partial multiplier is shifted to the right by the bit number equivalent to the block length by a shifter and supplied to one side of an adder. Thus the multiplication is possible beginning from the highest bit without increasing the hardware of the adder.

Description

【発明の詳細な説明】 〔発明の利用分野〕 本発明は、被乗数及び乗数となるデータを複数ブロック
に分割し、各ブロック毎に乗算を行い、その乗算結果の
累積により積を求める乗算回路に関する。本発明になる
乗算回路は、例えば、倍精度浮動小数点データの乗算を
行う場合に用いられ、ベクトル演算を高速に実行するパ
イプライン乗算回路として利用される。
[Detailed Description of the Invention] [Field of Application of the Invention] The present invention relates to a multiplication circuit that divides data serving as a multiplicand and a multiplier into a plurality of blocks, performs multiplication for each block, and obtains a product by accumulating the multiplication results. . The multiplication circuit according to the present invention is used, for example, when performing multiplication of double-precision floating point data, and is used as a pipeline multiplication circuit that executes vector operations at high speed.

〔従来技術〕[Prior art]

倍精度浮動小数点データの乗算を行う場合、仮数部を数
ブロックに分割し、各ブロック毎に乗算を行い、その乗
算結果の累積により仮数部の乗算を行うものが知られて
いる。この場合、従来は、仮数部の最下位ビットを含む
ブロック同志の乗算から開始していた。
When performing multiplication of double precision floating point data, it is known that the mantissa is divided into several blocks, multiplication is performed for each block, and the mantissa is multiplied by accumulating the multiplication results. In this case, conventionally, the multiplication of blocks including the least significant bits of the mantissa part is started.

通常、倍精度浮動小数点データは、メモ17 K格納さ
れており、乗算を行う毎にメモリから読み出され、乗算
が行なわれる。
Normally, double-precision floating point data is stored in a memory 17K, and is read out from the memory each time a multiplication is performed.

ブロック単位の乗算を行う場合、ブロック単位にメモリ
から読み出す必要があるが、通常、最下位ビットを含む
ブロックは、最下位ビットを含まないブロックに対して
メモリアドレスの上位側に格納されており、最下位ビッ
トを含むブロックは2回目のアクセスで読み出される。
When performing block-by-block multiplication, it is necessary to read each block from memory, but normally the block containing the least significant bit is stored at a higher memory address than the block not containing the least significant bit. The block containing the least significant bit is read on the second access.

この為、パイプライン乗算を行う場合、パイプラインに
あきが生じ、パイプライン動作を高速に実行できなかっ
た。
For this reason, when pipeline multiplication is performed, a gap occurs in the pipeline, making it impossible to execute the pipeline operation at high speed.

また、IEEE標準浮動小数点フォーマットを採用する
と、指数部がオール「1」の時、その数は非数とみなし
て、特別の定められた値を乗算結果として出力する必要
があるが、最下位ビットを含むブロックから乗算を開始
すると、指数部のデータは最下位ビットを含むブロック
の乗算が行なわれた後で読み出され、非数の認識が遅れ
、パイプライン動作に乱れを生じるという不都合があっ
た。
In addition, when the IEEE standard floating point format is adopted, when the exponent part is all 1's, the number must be regarded as a non-number and a special predetermined value must be output as the multiplication result, but the least significant bit If multiplication is started from the block containing the least significant bit, the exponent data will be read after the block containing the least significant bit has been multiplied, resulting in a delay in recognition of non-numbers and disturbances in pipeline operation. Ta.

〔発明の目的〕[Purpose of the invention]

本発明の目的は、被乗数及び乗数のデータを複数ブロッ
クに分割して乗算する場合、最上位ビットを含むブロッ
クのデータから乗算が可能な乗算回路を提供するにある
An object of the present invention is to provide a multiplication circuit that can perform multiplication starting from data of a block including the most significant bit when multiplicand and multiplier data are divided into a plurality of blocks and multiplied.

本発明の1つの目的は、最上位ビットを含むブロックの
データから乗算が可能で且つ簡便な回路構成の乗算回路
を提供するにある。
One object of the present invention is to provide a multiplication circuit that can perform multiplication from data of a block including the most significant bit and has a simple circuit configuration.

〔発明の概要〕[Summary of the invention]

本発明による乗算回路は、ブロック単位同志の乗算を行
う部分積乗算器と、この部分積乗算器の乗算結果を一方
の入力とし累積された乗算結果を他方の入力とする加算
器を有し、更に、該部分積乗算器の乗算結果をブロック
長のビット数だけ右シフトする機能を有するシフタを設
け、シフタの出力を該加算器の一方の入力に印加する構
成にしている。
The multiplication circuit according to the present invention has a partial product multiplier that performs block-by-block multiplication, and an adder that takes the multiplication result of the partial product multiplier as one input and the accumulated multiplication result as the other input, Further, a shifter having a function of right-shifting the multiplication result of the partial product multiplier by the number of bits of the block length is provided, and the output of the shifter is applied to one input of the adder.

本発明によれば、最上位ビットを含むブロック同志の乗
算から開始され、最下位ビットを含むブロック同志の乗
算を行ないこの乗算結果と累積された乗算結果の加算を
する場合、シフタによって該部分積乗算器の乗算結果は
ブロック長のビット数だけ右シフトされて加算器の一方
の入力に印加される。
According to the present invention, when starting from multiplication between blocks including the most significant bit, performing multiplication between blocks including the least significant bit, and adding this multiplication result to the accumulated multiplication result, the shifter uses the partial product. The multiplication result of the multiplier is shifted to the right by the number of bits of the block length and applied to one input of the adder.

これにより、加算器のハードウェア規模を増加すること
なく最上位ビットを含むブロックからの乗算が可能とな
る。
This allows multiplication from the block containing the most significant bit without increasing the hardware scale of the adder.

実施例 第1図は本発明が適用される浮動小数点データの演算を
行う処理装置の全体構成を示す図である。
Embodiment FIG. 1 is a diagram showing the overall configuration of a processing device for performing arithmetic operations on floating point data to which the present invention is applied.

第1図において、lはホストコンピュータ(HO8T)
、2けインターフェイス部、3け演算ユニット、4はレ
ジスタファイル、5はメモリ部、6はアドレス演算部、
7けマイクロプログラムコントローラである。3〜6の
各ユニットは、マイクロプログラムコントローラ7によ
り制御される。
In Figure 1, l is the host computer (HO8T)
, 2-digit interface section, 3-digit operation unit, 4 is a register file, 5 is a memory section, 6 is an address operation section,
It is a 7-digit microprogram controller. Each of the units 3 to 6 is controlled by a microprogram controller 7.

本発明による乗算回路は演算ユニット3の内部で使用さ
れる。
The multiplication circuit according to the invention is used inside the arithmetic unit 3.

第2図に、演算ユニット3の構成を示す。図において、
10は、4段のパイプラインステージ10−1〜10−
4より成る32ビット乗算回路、11け、3段のバ・「
ブラインステージ11−1〜11−3より成る64ピッ
ト加算回路、12〜15はバスであり、それぞれ12は
、加算回路11の右入力、13け、加算回路11の左入
力、141d乗算回路10の右入力、111:乗!¥−
回M10の左入力信号を入力する。16は乗算或いは加
算した結果を出力するデータバス、17は加算回路出力
信号線、18は乗算回路出力信号線、19は加算回路1
1の下32ビットを、加算回路11の左入力に入力する
信号線、20は加算回路11の上32ビットを加算回路
11の左入力に入力する信号線、21は乗算回路10の
出力の上32ビットを加算回路11の右入力に入力する
信号線、22は乗算回路10の下32ビットを、加算回
路11の右入力の下32ピットに入力する信号線である
FIG. 2 shows the configuration of the arithmetic unit 3. In the figure,
10 is a four-stage pipeline stage 10-1 to 10-
32-bit multiplier circuit consisting of 4, 11 digits, 3 stages
A 64-pit addition circuit consisting of brine stages 11-1 to 11-3, 12 to 15 are buses, 12 is the right input of the addition circuit 11, 13 is the left input of the addition circuit 11, and 141d is the left input of the multiplication circuit 10. Right input, 111: Multiply! ¥−
The left input signal of time M10 is input. 16 is a data bus that outputs the result of multiplication or addition; 17 is an adder circuit output signal line; 18 is a multiplier circuit output signal line; 19 is an adder circuit 1
20 is a signal line that inputs the lower 32 bits of 1 to the left input of the adder 11, 20 is a signal line that inputs the upper 32 bits of the adder 11 to the left input of the adder 11, and 21 is the upper output of the multiplier 10. A signal line 22 inputs 32 bits to the right input of the adder circuit 11, and a signal line 22 inputs the lower 32 bits of the multiplier circuit 10 to the lower 32 pits of the right input of the adder circuit 11.

乗算回路10への入力は、乗算回路出力信号線14、乗
算回路圧入力信号線15によシ行なわれ、その出力は、
データバス16に、信号線21を介して加算回路右入力
信号線12K、及び信号線18を介して、レジスタファ
イル4に送られる。
Input to the multiplier circuit 10 is carried out through a multiplier circuit output signal line 14 and a multiplier circuit pressure input signal line 15, and its output is as follows.
The signal is sent to the data bus 16 via the signal line 21 to the adder circuit right input signal line 12K, and via the signal line 18 to the register file 4.

乗算が倍精度乗算の場合は、演算結果の下32ビットを
信号線22を介して直接加算回路11の右入力に入力で
きる構成となっている。
When the multiplication is double precision multiplication, the configuration is such that the lower 32 bits of the calculation result can be directly input to the right input of the addition circuit 11 via the signal line 22.

加算回路11への入力は、単精度データ、及び倍精度で
二度に分けて入力される場合の上位32ビツトデータは
、加算回路右入力信号線12、及び加算回路出力信号線
13を介して行なわれる。
The input to the adder circuit 11 is single-precision data, and upper 32-bit data when double-precision is input in two parts via the adder circuit right input signal line 12 and the adder circuit output signal line 13. It is done.

加算回路11の出力は、データバス16に、あるいは信
号線17を介してレジスタファイル4に、あるいけ信号
線20を介して加算回路在入力信号線13に送られる。
The output of the adder circuit 11 is sent to the data bus 16 or via the signal line 17 to the register file 4, and via the input signal line 20 to the adder circuit input signal line 13.

倍精度演算のときは、出力の下32ビットを信号線19
を介して直接加算回路11の左入力に入力できる構成と
なっている。加算回路11は、米国特許4,075,7
04  で例示されるようなパイプライン加算回路であ
る。
For double-precision arithmetic, the lower 32 bits of the output are connected to signal line 19.
The configuration is such that it can be directly input to the left input of the adder circuit 11 via. Adder circuit 11 is described in U.S. Patent No. 4,075,7.
This is a pipeline addition circuit as exemplified by 04.

本発明による乗算回路10の詳細な構成は以下で説明さ
れる。
The detailed structure of the multiplication circuit 10 according to the invention will be explained below.

第3図にレジスタファイル4の構成を示す。図において
、30は加算回路出力17、乗算回路出力18のうちの
1つを選択するセレクタ、31は、読出し要求信号(a
g)、書き込み要求信号(WE)をもつFIFO(Fi
rst−In 、 First−□ut)レジスタ、3
2t−j:、加算回路出力17、乗算回路出力18、デ
ータバス16のうちの1つを選択するセレクタ、33け
2つの読み出しアドレス(RAI、RA2)、及び書き
込みアドレス(WA)を持つ2ボートレジスタである。
FIG. 3 shows the configuration of the register file 4. In the figure, 30 is a selector that selects one of the adder circuit output 17 and the multiplier circuit output 18, and 31 is a read request signal (a
g), FIFO (Fi
rst-In, First-□ut) register, 3
2t-j: adder circuit output 17, multiplier circuit output 18, selector for selecting one of the data buses 16, 2 ports with 33 digits, two read addresses (RAI, RA2), and a write address (WA). It is a register.

FIFO31へのデータの書込みは、加算回路出力信号
線17、及び乗算回路出力信号線18のうちのいずれか
をセレクタ30で選択して、書き込み要求信号WEをオ
ンすることにより行なわれる。
Data is written into the FIFO 31 by selecting either the adder circuit output signal line 17 or the multiplier circuit output signal line 18 by the selector 30 and turning on the write request signal WE.

またFIFO31からの読み出しは、読み出し要求信号
BEをオンすることにより行なわれ、加算回路在入力信
号線12、及び左入力信号線13に出力される。
Further, reading from the FIFO 31 is performed by turning on the read request signal BE, which is output to the adding circuit input signal line 12 and the left input signal line 13.

2ボートレジスタ33への入力は、加算回路出力信号線
17、乗算回路出力信号線18、データバス16のうち
のいずれかをセレクタ32で選択して、書き込みアドレ
スWAの位置に書き込まれる。また、2ボートレジスタ
33からの読み出しは、2ボートレジスタ33の読み出
しアドレスRAI、R,A2で指定された位置から読み
出され、各々、乗算回路入力信号線15、加算回路在入
力信号線13、及び乗算回路出力信号線14、加算回路
在入力信号線12に出力される。
The input to the 2-vote register 33 is written into the write address WA by selecting one of the adder circuit output signal line 17, the multiplier circuit output signal line 18, and the data bus 16 by the selector 32. Further, reading from the 2-boat register 33 is performed from the positions specified by the read addresses RAI, R, and A2 of the 2-boat register 33, and the multiplier circuit input signal line 15, adder circuit input signal line 13, It is output to the multiplier circuit output signal line 14 and the adder circuit input signal line 12.

第4図にメモリ部5及びアドレス演算部6の構成ヲ示す
。図において、40はメモリデータ読み出しレジスタ(
MDR,几1)、41はメモリ1.42はメモリデータ
書き込みレジスタ1(MDWRI)、43はメモリアド
レスレジスタ1(MARL)、44はメモリデータ読み
出しレジスタ2(MD几FL2)、45はメモ+72.
46はメモリデータ書き込みレジスタ、47はメモリア
ドレスレジスタ2.48.49はそれぞれMDf’Lf
’L1 (40)、MD几FL2(41)のデータをデ
ータバス16に出力する信号線、50は演算ロジックユ
ニット(ALU)53の出力と、データバス16のうち
の1つを選択するセレクタ、51は2ボートレジスタ(
BEG)、52はMDRR1(40)、MDRR,2(
44) 、几EG51の出力のうちの1つを選択するセ
レクタである。
FIG. 4 shows the configuration of the memory section 5 and address calculation section 6. In the figure, 40 is a memory data read register (
MDR, 几1), 41 is memory 1.42 is memory data write register 1 (MDWRI), 43 is memory address register 1 (MARL), 44 is memory data read register 2 (MD几FL2), 45 is memo+72.
46 is a memory data write register, 47 is a memory address register 2, 48, and 49 are MDf'Lf, respectively.
'L1 (40), a signal line that outputs the data of MD FL2 (41) to the data bus 16; 50, a selector that selects the output of the arithmetic logic unit (ALU) 53 and one of the data buses 16; 51 is a 2-vote register (
BEG), 52 is MDRR1 (40), MDRR,2 (
44) is a selector for selecting one of the outputs of the EG51.

2つのメモ1J41,44は同一の機能を持ち、例えば
メモリ41では、読み出しのときは、MAR1(43)
に指定されたアドレスのデータを読み出して、MDR,
ELl (40)にセットする。書き込みのときは、M
DWRI(42)のデータを、MAfLl(43)で指
定されたアドレスの位置に書き込む。
The two memos 1J41 and 44 have the same function; for example, in the memory 41, when reading, MAR1 (43)
Read the data at the address specified in MDR,
Set to ELl (40). When writing, M
Write the data of DWRI (42) to the address specified by MAfLl (43).

MDWRI (42)はデータバス16からのデータを
セットでき、またMDRRI (40)はデータノ(ス
16、加算器右入力(12)、加算器在入力(13)、
乗算器右入力(14)、乗算器在入力(15)の信号線
に出力が可能な構成となっている。
MDWRI (42) can set data from the data bus 16, and MDRRI (40) can set data from the data bus 16, adder right input (12), adder present input (13),
The configuration allows output to the signal lines of the multiplier right input (14) and multiplier existing input (15).

またMAR,1(43)は、ALU53の出力をセット
できるほか、■だけカウントアツプ及びダウンする機能
を持つ。
In addition to being able to set the output of the ALU 53, MAR,1 (43) also has the function of counting up and down by (2).

RgGsiは、2つの読み出しアドレスWKI。RgGsi is two read addresses WKI.

WK2を持つ2ボートレジスタであシ、書き込みは1マ
シンサイクルの後半でWKIのアドレスに書き込まれる
。ALU53は、右入力はREG 51からのデータ、
左入力は、几EG51.MDRRI(40)。
It is a two-vote register with WK2, and writes are written to the WKI address in the second half of one machine cycle. The right input of ALU53 is data from REG51,
The left input is EG51. MDRRI (40).

MDRR,2(44)のいずれか1つのデータを用いて
演算し、その結果をMAR1(43)、MAR2(47
)。
MDRR, 2 (44) is used for calculation, and the result is MAR1 (43), MAR2 (47).
).

REG51にセットできる。Can be set to REG51.

3〜6の各ユニットの1マシンサイクルの動作ハマイク
ロプログラムコントロージ7にあるマイクロプログラム
の1語によシ規定される。信号線12〜16の各々ユニ
ットからの出力は、どれか1つしか選択されないように
規定されている。
The operation of each of the units 3 to 6 in one machine cycle is defined by one word of the microprogram in the microprogram controller 7. Outputs from each unit of signal lines 12 to 16 are specified so that only one is selected.

第5図に本発明になるパイプライン乗算回路10の一具
体例を示す。図において、101゜102は、指数部入
力制御回路、103,104は、レジスタ、105は加
算器、106はセレクタ、107は加算器、108,1
09はレジスタ、110は加算器、111は、808回
路、112゜113.114はレジスタ、115,11
6は、仮数部入力制御回路、117,118はレジスタ
、119は部分積乗算回路、120はレジスタ、121
はセレクタ、122け加算器、123はシフタ、124
はレジスタ、125はセレクタ、126は出力制御回路
、127はセレクタ、128は符号信号線、129け指
数部信号線、130け仮数部信号線である。各信号線に
付加された0書きの小文字の数はそれぞれ信号線の数(
ビット数)を示している。
FIG. 5 shows a specific example of the pipeline multiplication circuit 10 according to the present invention. In the figure, 101 and 102 are exponent part input control circuits, 103 and 104 are registers, 105 is an adder, 106 is a selector, 107 is an adder, and 108, 1
09 is a register, 110 is an adder, 111 is an 808 circuit, 112゜113.114 is a register, 115, 11
6 is a mantissa input control circuit, 117 and 118 are registers, 119 is a partial product multiplication circuit, 120 is a register, 121
is a selector, 122-digit adder, 123 is a shifter, 124
125 is a register, 125 is a selector, 126 is an output control circuit, 127 is a selector, 128 is a code signal line, a 129-digit exponent signal line, and a 130-digit mantissa signal line. The number of lowercase 0 characters added to each signal line is the number of signal lines (
number of bits).

第5図の入力制御回路101,102,115゜116
は、データが単精度か倍精度かに従ってレジスタ103
,104,117,118にデータをセットする回路で
ある。単精度および倍精度のデータのフォーマットを第
6図に示している。このとき表現されるデータは、 単精度では、(1)  X2    Xl、Fs倍精度
では、(1)X2    Xi、Fnである。但し、B
5 、BDは、それぞれ指数部Es 、EDのバイアス
分である。
Input control circuit 101, 102, 115° 116 in FIG.
register 103 depending on whether the data is single or double precision.
, 104, 117, and 118. The format of single-precision and double-precision data is shown in FIG. The data expressed at this time is (1) X2 Xl in single precision, and (1) X2 Xi, Fn in double precision. However, B
5 and BD are the bias portions of the exponent parts Es and ED, respectively.

第7図は指数部入力制御回路101の構成を示している
。図中のSSは、入力が単精度データのとき「1」とな
シ、それ以外ではrOJとなる。
FIG. 7 shows the configuration of the exponent part input control circuit 101. SS in the figure is "1" when the input is single-precision data, and is rOJ otherwise.

5s=rl」のとき入力データの1〜8ビツトのデータ
がゲー1−03を介して出力信号線の4〜11ビツト目
に出力され、出力信号線の1〜3ビツト目にはゲートG
1を介して「o」が出力される。SS−l”’oJのと
きは、ゲートG2.G4を介して入力データがそのまま
出方される。この結果、レジスタ103には、単・倍精
度とも、指数部のデータが右にそろえられて、セットさ
れる。
5s=rl'', the 1st to 8th bits of input data are output to the 4th to 11th bits of the output signal line via gates 1-03, and the 1st to 3rd bits of the output signal line are output to the gate G.
1, "o" is output. When SS-l"'oJ, the input data is output as is through gates G2 and G4. As a result, the register 103 has exponent data aligned to the right for both single and double precision. , is set.

指数部入力制御回路102も101と同じ構成であシ、
レジスタ104には、指数部のデータがとシだされてセ
ットされる。EOR1x+は、2つの入力データの符号
ピッ)SのEORをとる。この結果2つのデータの積の
符号が得られ、これをレジスタ112にセットする。
Exponent input control circuit 102 also has the same configuration as 101,
The data of the exponent part is output and set in the register 104. EOR1x+ takes the EOR of the sign bits of two input data. As a result, the sign of the product of the two data is obtained, and this is set in the register 112.

仮数部人力ftjlJ御回路115の構成を第8図に示
す。図において、88.DU、DLは各々入力データが
単精度、倍精度の上位32ビツト、倍精度の下位32ピ
ツトのときに「1」となシ、それ以外は「0」となるこ
とを示している。SS−「1」のとき、出力信号線の0
〜7ビツト目はゲートGllを介してrOJが、8ビツ
ト目はゲートG13を介して「1」が、9〜31ビツト
目はゲ−)Gl 7〜G20を介して入力信号線の9〜
31ビツト目のデータが出力される。ここで8ビツト目
をrlJとして出力するのは、データフォーマット上、
隠されているビットを立てるためのものである。DU=
 rlJのときは、ゲートGll。
The configuration of the mantissa manual ftjlJ control circuit 115 is shown in FIG. In the figure, 88. DU and DL indicate that the input data is "1" when the input data is the upper 32 bits of single precision, the upper 32 bits of double precision, and the lower 32 bits of double precision, and is "0" otherwise. SS - When "1", 0 of the output signal line
The 7th to 7th bits are rOJ through the gate Gll, the 8th bit is 1 through the gate G13, and the 9th to 31st bits are the input signal lines 9 through G20.
The 31st bit data is output. Here, the reason why the 8th bit is output as rlJ is because of the data format.
It is used to raise hidden bits. DU=
When rlJ, gate Gll.

G14.G16を介して出力信号線の0〜ioピツトは
「0」が、11ビツト目はゲート018を介して「1」
が、12〜31ピツトはゲートG20を介して入力信号
線の12〜31ピツトのデータがそれぞれ出力される。
G14. The 0 to io pits of the output signal line are set to "0" through G16, and the 11th bit is set to "1" through gate 018.
However, for the 12th to 31st pits, the data of the 12th to 31st pits of the input signal line are outputted via the gate G20, respectively.

DL=rlJのときは、ゲートG12.G15.G17
.G19.G20を介して入力データがそのまま出力信
号線に出力される。仮数部入力制御回路116も115
と同じ構成であり、115.116の出力は、レジスタ
117,118にセットされる。
When DL=rlJ, gate G12. G15. G17
.. G19. Input data is output as is to the output signal line via G20. The mantissa input control circuit 116 is also 115
The outputs of 115 and 116 are set in registers 117 and 118.

加算器105では、レジスタ103,104のデータが
加算され、加算器107の左入力となる。
In the adder 105, the data in the registers 103 and 104 are added, and the result becomes the left input of the adder 107.

ここで単精度の2つのデータの指数部をEel。Here, Eel is the exponent part of the two single-precision data.

EI!2とすると、乗算によって指数部は、2Kill
−Blil   EB −811,、,2E[Il+E
l!2−2BII×2 =2  (”s+”+!2  Bs)−111!の加算
をする必要がある。単精度で出力するためには、E s
 I とE8gを加え合わせて、さらにそれからB11
を引く必要がある。入力が倍精度で、倍精度で出力する
場合も同様に、指数部を加え合わせて、それからバイア
ス分Baを引く必要がある。
EI! 2, the exponent part is multiplied by 2Kill
-Blil EB -811,,,2E[Il+E
l! 2-2BII×2 = 2 (“s+”+!2 Bs)-111! It is necessary to add . To output in single precision, E s
Add I and 8g of E, then add B11
It is necessary to subtract. Similarly, when the input is double precision and the output is double precision, it is necessary to add the exponent parts and then subtract the bias amount Ba.

セレクタ106、加算器107は、この補正を行なう回
路である。セレクタ106け、入力データが単精度で出
力も単精度のとき、Bsを、入出力とも倍精度のとき、
BDをセレクトする。
The selector 106 and adder 107 are circuits that perform this correction. Selector 106, when the input data is single precision and the output is also single precision, Bs, when both the input and output are double precision,
Select BD.

加算器107では、左入力データの値から右入力データ
を減じて、出力する。その結果はレジスタ108にセッ
トされる。レジスタ112の内容ハレシスタ113に転
送されセットされる。
The adder 107 subtracts the right input data from the value of the left input data and outputs the result. The result is set in register 108. The contents of register 112 are transferred to register 113 and set.

第9図に部分積乗算器119の構成を示す。FIG. 9 shows the configuration of partial product multiplier 119.

201〜204は16ビツトの入力データを乗算して3
2ビツトの出力を出す乗算器である。201は、入力デ
ータの上位16ビツトの乗算、202け、左入力の下位
16ビツト、右入力の上位16ビツトの乗n、203は
、左入力の上位16ビツト、右入力の下位16ビツトの
乗算、204け入力データの下位16ビツトの乗算を行
ない、その結果をレジスタ120にセットする。
201 to 204 are multiplied by 16-bit input data to obtain 3
This is a multiplier that produces a 2-bit output. 201 is the multiplication of the upper 16 bits of the input data, 202 is the multiplication of the lower 16 bits of the left input, the upper 16 bits of the right input is multiplied by n, and 203 is the multiplication of the upper 16 bits of the left input and the lower 16 bits of the right input. , 204 input data are multiplied by the lower 16 bits, and the result is set in the register 120.

加算器122の動作を単精度乗算、倍精度乗算に分けて
説明する。
The operation of the adder 122 will be explained separately into single-precision multiplication and double-precision multiplication.

まず単精度乗算時は、セレクタ121け、l’−oJが
選択され、力6算器122では、レジスタ120の出力
が第10図のように加算されて、レジスタ124にセッ
トされる。
First, during single-precision multiplication, l'-oJ is selected by the selector 121, and the outputs of the register 120 are added together in the force 6 multiplier 122 as shown in FIG. 10, and the result is set in the register 124.

次に、倍精度乗算時は、被乗数、乗数共に上位32ビツ
トの乗算、次に被乗数上位32ビツトと乗数の下位32
ビツトの乗算、次に被乗数の下位32ビツトと乗数の上
位32ビツトの乗算、最後に被乗数、乗数共に下位32
ビツトの乗算の順で行なわれる。以上4つのステップに
ついて順に第11図を用いて詳細に説明する。図におい
て、500(a)、 501(b)は各々、被乗数の仮
数部の上位32ビツト、下位32ビツト、502(C)
Next, when performing double-precision multiplication, the upper 32 bits of both the multiplicand and the multiplier are multiplied, and then the upper 32 bits of the multiplicand and the lower 32 bits of the multiplier are multiplied.
Multiply the bits, then multiply the lower 32 bits of the multiplicand by the upper 32 bits of the multiplier, and finally multiply the lower 32 bits of both the multiplicand and the multiplier.
This is done in the order of bit multiplication. The above four steps will be explained in detail using FIG. 11 in order. In the figure, 500(a) and 501(b) represent the upper 32 bits, lower 32 bits, and 502(C) of the mantissa part of the multiplicand, respectively.
.

503 (d)は各々乗数の仮数部の上位32ビツト、
下位32ビツトである。
503 (d) are the upper 32 bits of the mantissa of each multiplier,
This is the lower 32 bits.

まず第1のステップでは、500X502 (a×C)
の64ビツトデータ504と、セレクタ121にて選択
された505の「0」が加算器122にて加算されその
結果の75ピツトデータ506が、レジスタ124に格
納される。
First, in the first step, 500X502 (a×C)
The adder 122 adds the 64-bit data 504 and 505 "0" selected by the selector 121, and the resulting 75-bit data 506 is stored in the register 124.

第2のステップでは、500X503 (axd)の6
4ピツトデータ508と、レジスタ124に格納されて
いる75ビツトデータ506をシフタ123によって左
に32ビツトシフトしたデータ507が、セレクタ12
1によって選択され、この両者が加算器122によって
加算され、加怨結果の上位75ビツト509がVラスタ
124に格納される。
In the second step, 6 of 500X503 (axd)
The 4-pit data 508 and the data 507 obtained by shifting the 75-bit data 506 stored in the register 124 by 32 bits to the left by the shifter 123 are transferred to the selector 12.
1 is selected, both are added by the adder 122, and the upper 75 bits 509 of the modification result are stored in the V raster 124.

第3のステップでは、501X502 (bxc)の6
4ピツトデータ510と、レジスタ124に格納されて
いる75ピツトデータ509がシフト数Oでシフタ12
3でシフトされ(すなわち、全くシフトされない)、セ
レクタ121で選択され、この両者が加算器122によ
って加算され、加算結果の上位75ビツト511が、レ
ジスタ124に格納される。
In the third step, 6 of 501X502 (bxc)
The 4-pit data 510 and the 75-pit data 509 stored in the register 124 are transferred to the shifter 12 with a shift number O.
3 (that is, not shifted at all), is selected by selector 121, and both are added by adder 122, and the upper 75 bits 511 of the addition result are stored in register 124.

最後の第4ステツプでは、501X503 (bxd)
の64ビツトデータ512が、シフタ131によって右
に32ビツトシフトされたデータ513と、レジスタ1
24に格納されている75ビツトデータ511が、シフ
ト数0でシフタ123でシフトされ(すなわち、全くシ
フトされないで)、セレクタ121で選択され、この両
者が、加算器122によって加算され、加算結果の上位
75ビツト514が、レジスタ124レジスタに格納さ
れる。
In the fourth and final step, 501X503 (bxd)
The 64-bit data 512 of
The 75-bit data 511 stored in the 24 is shifted by the shifter 123 with a shift number of 0 (that is, not shifted at all) and selected by the selector 121, and both are added by the adder 122 and the addition result is The upper 75 bits 514 are stored in register 124 register.

なお、シフタ131は、倍精度乗算の第4のステップ以
外では常にシフト数01すなわち、全くシフトしないで
データを出力するようになっている。
Note that the shifter 131 always outputs data with a shift number of 01, that is, without shifting at all, except in the fourth step of double precision multiplication.

レジスタ124に格納される乗算結果は第12図に示す
ように、単精度乗算時、倍精度乗算時それぞれに2通り
のパターンが存在する。単精度乗算時はピット16.0
〜15.64〜74がOで、ピッl−通16が1で、ビ
ットA17〜63は0あるいは1のパターン、ピット屈
0〜16.64−74がOで、ビット&17が1で、ピ
ットA 18〜63が0あるいは1のパターンである。
As shown in FIG. 12, the multiplication results stored in the register 124 have two patterns for single-precision multiplication and double-precision multiplication. Pit 16.0 during single precision multiplication
~15.64-74 is O, bit 16 is 1, bit A17-63 is 0 or 1 pattern, pit width 0-16.64-74 is O, bit &17 is 1, pit A 18-63 is a pattern of 0 or 1.

これは第8図で示したように、仮数部の入力データが加
工されてセットされるためである。
This is because, as shown in FIG. 8, the input data of the mantissa part is processed and set.

倍精度乗算時も同様の理由により、第12図に示した2
通υのパターンが存在する。
For the same reason, when performing double-precision multiplication, the 2
There is a common pattern.

各々2通りのパターンのときに、単精度、倍精度各々ピ
ッ)417、ビットA23に始めて1が立つようにセレ
クタ125にてシフトと同様の機能を果たし、その出力
が130に出る。
For each of two patterns, the selector 125 performs a function similar to a shift so that bit A23 is set to 1 for the first time in single precision and double precision, respectively, and the output is outputted at 130.

第13図に符号部、指数部、仮数部演算回路の出力制御
回路126の構成を示す。
FIG. 13 shows the configuration of the output control circuit 126 of the sign part, exponent part, and mantissa part calculation circuit.

図中、88.Dはそれぞれ単精度、倍精度演算を示す信
号である。OEは出力許可信号である。
In the figure, 88. D is a signal indicating single-precision and double-precision arithmetic, respectively. OE is an output permission signal.

この回路により、出力として符号部、指数部。This circuit outputs a sign part and an exponent part.

仮数部が浮動小数点フォーマットとして正しい形で演算
結果が出力される。
The operation result is output with the mantissa in the correct floating point format.

本実施例によれば、倍精度乗算時も仮数部のMSBを含
む32ピツトデータ同志の乗算から開始でき、メモリア
クセスデータがパイプライン演算器に空きが生じること
なく供給されることKよ1) ハイプライン演算の全体
的なスループットの向上に効果がある。
According to this embodiment, even during double-precision multiplication, it is possible to start from the multiplication of 32-pit data including the MSB of the mantissa part, and the memory access data is supplied to the pipeline arithmetic unit without any empty space.1) Hypline This is effective in improving the overall throughput of calculations.

〔発明の効果〕〔Effect of the invention〕

本発明によれば、倍精度浮動小数点データを上位32ピ
ツト、下位32ビツトの順にパイプライン乗算器にデー
タ供給できるため、従来の下位32ピツト、上位32ビ
ツトの順に供給する場合に比べ、少なくとも1回の倍精
度乗算において、2マシンザイクルの高速化が可能とな
る。
According to the present invention, double-precision floating point data can be supplied to the pipeline multiplier in the order of the upper 32 pits and the lower 32 bits, so compared to the conventional case where the data is supplied in the order of the lower 32 pits and the upper 32 bits, In double-precision multiplication, the speed can be increased by two machine cycles.

更に本発明によれば、IEgE標準浮動小数点フォーマ
ットを採用した場合も、乗算開始時に指数部のデータは
同時に読み出されておシ、非数の認識が早く、パイプラ
イン動作に乱れを生じることはなくなる。
Furthermore, according to the present invention, even when the IEgE standard floating point format is adopted, the data in the exponent part is read out at the same time at the start of multiplication, so non-numbers are recognized quickly and there is no disturbance in pipeline operation. It disappears.

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

図における演算回路の構成図、第3図は第1図における
レジスタファイルの構成図、第4図は、第1図における
メモリとアドレス演算器の構成図、第5図は本発明によ
る乗算回路の一実施例構成図、第6図はフローティング
フォーマットを説明した図、第7図は第5図における指
数部入力制御回路の構成図、第8図は第5図における仮
数部入力制御回路の構成図、第9図は第5図における部
分積乗算器の構成図、第10図は部分積の加算を説明し
た図、第11図は倍精度乗算時の手順の説明図、第12
図は乗算結果のフォーマットを説明した図、第13図は
第5図における出力制御回路の構成図である。 10・・・パイプライン乗算器L119・・・部分積乗
算器、122・・・加算器、131・・・シフタ。 ¥90 審10口 /Zg 第1/図 竿IZ目
3 is a configuration diagram of the register file in FIG. 1, FIG. 4 is a configuration diagram of the memory and address arithmetic unit in FIG. 1, and FIG. 5 is a configuration diagram of the multiplication circuit according to the present invention. A configuration diagram of one embodiment, FIG. 6 is a diagram explaining the floating format, FIG. 7 is a configuration diagram of the exponent input control circuit in FIG. 5, and FIG. 8 is a configuration diagram of the mantissa input control circuit in FIG. 5. , FIG. 9 is a block diagram of the partial product multiplier in FIG. 5, FIG. 10 is a diagram explaining addition of partial products, FIG. 11 is a diagram explaining the procedure for double precision multiplication,
This figure is a diagram explaining the format of the multiplication result, and FIG. 13 is a configuration diagram of the output control circuit in FIG. 5. 10... Pipeline multiplier L119... Partial product multiplier, 122... Adder, 131... Shifter. ¥90 Judgment 10 pieces/Zg 1st/Figure rod IZth

Claims (1)

【特許請求の範囲】[Claims] 1、複数ブロックに分割された被乗数、及び乗数となる
データをブロック毎に乗算し、その乗算結果の累積によ
シ乗算を実行するものであって、ブロック単位同志の乗
算を行う部分積乗算器と、該部分積乗算器の乗算結果を
一方の入力とし、累積された乗算結果を他方の入力とす
る加算器を有する乗算回路において、該部分積乗算器の
乗算結果をブロック長のビット数だけ右シフトする機能
を有するシフタを設け、該シフタの出力を該加算器の一
方の入力に印加する構成にしたことを特徴とする乗算回
路。
1. A partial product multiplier that multiplies a multiplicand divided into multiple blocks and data serving as a multiplier for each block, and performs multiplication by accumulating the multiplication results, and performs multiplication on a block-by-block basis. In a multiplication circuit having an adder which takes the multiplication result of the partial product multiplier as one input and takes the accumulated multiplication result as the other input, the multiplication result of the partial product multiplier is multiplied by the number of bits of the block length. 1. A multiplication circuit comprising a shifter having a right-shifting function, and an output of the shifter is applied to one input of the adder.
JP21130382A 1982-12-03 1982-12-03 Multiplying circuit Pending JPS59103148A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP21130382A JPS59103148A (en) 1982-12-03 1982-12-03 Multiplying circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP21130382A JPS59103148A (en) 1982-12-03 1982-12-03 Multiplying circuit

Publications (1)

Publication Number Publication Date
JPS59103148A true JPS59103148A (en) 1984-06-14

Family

ID=16603704

Family Applications (1)

Application Number Title Priority Date Filing Date
JP21130382A Pending JPS59103148A (en) 1982-12-03 1982-12-03 Multiplying circuit

Country Status (1)

Country Link
JP (1) JPS59103148A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH02294730A (en) * 1989-04-17 1990-12-05 Internatl Business Mach Corp <Ibm> Floating point arithmetic processor
US9074667B2 (en) 2010-09-29 2015-07-07 Nec Platforms, Ltd. Gear drive mechanism and library device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH02294730A (en) * 1989-04-17 1990-12-05 Internatl Business Mach Corp <Ibm> Floating point arithmetic processor
US9074667B2 (en) 2010-09-29 2015-07-07 Nec Platforms, Ltd. Gear drive mechanism and library device

Similar Documents

Publication Publication Date Title
US5995992A (en) Conditional truncation indicator control for a decimal numeric processor employing result truncation
US4941120A (en) Floating point normalization and rounding prediction circuit
US6556716B2 (en) On-the-fly compression for pixel data
KR100239029B1 (en) Result normalizer and method of operation
EP0075745B1 (en) Method and apparatus for division
US3825895A (en) Operand comparator
CA1170775A (en) Data processor having apparatus for controlling the selection of decimal digits of an operand when executing decimal arithmetic instructions
EP0018120B1 (en) Multiplier circuit
US7725522B2 (en) High-speed integer multiplier unit handling signed and unsigned operands and occupying a small area
EP0505175B1 (en) Preprocessor of a division device employing a high radix division system
JPH0250492B2 (en)
US3840727A (en) Binary multiplication by addition with non-verlapping multiplier recording
US20060179098A1 (en) System and method for reduction of leading zero detect for decimal floating point numbers
US4823300A (en) Performing binary multiplication using minimal path algorithm
US5377135A (en) High cardinal number type non-restoring divider reducing delay time for adding two numbers
JPS59103148A (en) Multiplying circuit
JPS63123125A (en) Floating point adder
JPS5968058A (en) Floating point multiplier
US3492468A (en) Division of negative dividend expressed in two&#39;s complement form
JP3435744B2 (en) Multiplication circuit
JPS5932038A (en) Floating-point adder
JP2591250B2 (en) Data processing device
US4141077A (en) Method for dividing two numbers and device for effecting same
JP2608090B2 (en) High radix non-restoring divider
JP2654062B2 (en) Information processing device