Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JPS6029406B2 - Arithmetic control method - Google Patents
[go: Go Back, main page]

JPS6029406B2 - Arithmetic control method - Google Patents

Arithmetic control method

Info

Publication number
JPS6029406B2
JPS6029406B2 JP54060720A JP6072079A JPS6029406B2 JP S6029406 B2 JPS6029406 B2 JP S6029406B2 JP 54060720 A JP54060720 A JP 54060720A JP 6072079 A JP6072079 A JP 6072079A JP S6029406 B2 JPS6029406 B2 JP S6029406B2
Authority
JP
Japan
Prior art keywords
adder
bytes
carry
register
cycle
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.)
Expired
Application number
JP54060720A
Other languages
Japanese (ja)
Other versions
JPS55153051A (en
Inventor
眞宏 橋本
健一 和田
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 JP54060720A priority Critical patent/JPS6029406B2/en
Publication of JPS55153051A publication Critical patent/JPS55153051A/en
Publication of JPS6029406B2 publication Critical patent/JPS6029406B2/en
Expired legal-status Critical Current

Links

Description

【発明の詳細な説明】 本発明は、演算制御方式に関し、特にプリント・パター
ンによる伝播遅延の大きい加算器方式に関するものであ
る。
DETAILED DESCRIPTION OF THE INVENTION The present invention relates to an arithmetic control system, and more particularly to an adder system with large propagation delays due to printed patterns.

高速度処理能力が要求される情報処理装置において、処
理速度の向上を計るための最も一般的な方法は、1マシ
ン・サイクル内に処理できるデータ長をできる限り大き
くすることである。
In information processing devices that require high-speed processing capability, the most common method for improving processing speed is to maximize the length of data that can be processed within one machine cycle.

通常の高速処理装置では、8バイト長程度のデータ幅を
1マシン・サイクル内に処理している。いま、2進の先
見的加算器について考えた場合、4バイト幅の加算器と
8バイト幅の加算器を比較してみると、両者のゲート段
数の差は1段ないし2段程度であり、加算器に関する限
りゲート・ディレィの差は従来それほど大きくない。
A typical high-speed processing device processes data width of approximately 8 bytes in one machine cycle. Now, when considering a binary look-ahead adder, if you compare a 4-byte wide adder and an 8-byte wide adder, the difference in the number of gate stages between the two is about 1 or 2 stages, Conventionally, as far as adders are concerned, the difference in gate delay is not that large.

ところで、最近では、高集積度半導体技術の進歩により
、ゲート1段当りの速度が飛躍的に向上してきたため、
半導体素子相互間を連絡するプリント・パターンによる
伝播遅延が、処理装置のマシン・サイクル内に占める比
重としてきわめて大きくなっている。4バイトの加算器
と8バイトの加算器を比較した場合、前者では最下位ビ
ットから上位31ビットまで桁上げを伝達すればよいの
に対して、後者では最下位ビットから上位63ビットま
で桁上げを伝達する必要があり、必然的に後者による桁
上げ伝播のための半導体素子間遅延時間は前者より大き
0くなる。
By the way, in recent years, due to advances in highly integrated semiconductor technology, the speed per gate stage has improved dramatically.
Propagation delays caused by printed patterns that communicate between semiconductor devices have become extremely important in the machine cycles of processing equipment. When comparing a 4-byte adder and an 8-byte adder, the former only needs to transmit a carry from the least significant bit to the upper 31 bits, while the latter only needs to transmit a carry from the least significant bit to the upper 63 bits. It is necessary to transmit the delay time between semiconductor elements for the carry propagation due to the latter, which is inevitably larger than the former and becomes zero.

また、従来の処理装置においては、加算器が一組しか設
けられていないため、四則演算命令を一組の加算器で制
御することになり、加算器に入力すべきデータ・パスが
多くなる。
Further, in the conventional processing device, since only one set of adders is provided, four arithmetic operation instructions are controlled by one set of adders, and the number of data paths to be input to the adder increases.

タ したがって、論理装置を実際の半導体集積回路で実
現しようとすると、半導体集積回路は入出力ピンに物理
的制約を加えられるため、各素子を隔離して配置しなけ
ればならない。
Therefore, when attempting to realize a logic device using an actual semiconductor integrated circuit, physical constraints are imposed on the input/output pins of the semiconductor integrated circuit, and each element must be placed in isolation.

そこで、このような物理的制約から解放して、装置の処
理能力を向上させるために、複数個の演算器を設置し、
各演算器ごとに処理すべき命令群を割当てておく方法が
用いられている。
Therefore, in order to free ourselves from these physical constraints and improve the processing capacity of the device, we installed multiple computing units.
A method is used in which a group of instructions to be processed is assigned to each arithmetic unit.

第1図は、、複数個の演算ユニットを備えた機能分散型
演算器の説明図である。
FIG. 1 is an explanatory diagram of a functionally distributed arithmetic unit including a plurality of arithmetic units.

第1図において、演算器1は第1の演算ユニット(以下
1ユニットという)2と第2の演算ユニット(以下Gユ
ニットという)3に分割されている。
In FIG. 1, an arithmetic unit 1 is divided into a first arithmetic unit (hereinafter referred to as 1 unit) 2 and a second arithmetic unit (hereinafter referred to as G unit) 3.

Fユニット2は、浮動小数点命令および固定小数点乗除
算を実行するものであり、Gユニット3は固定小数点加
減算、論理演算、1坊隼演算、特権命令および割込み処
理等を実行するものである。第1図のような分割構成に
すると、装置全体の金物量は増大するが、各演算ユニッ
ト2,3がそれぞれ構成上得意とする分野において機能
と向上を計っているため、装置全体の処理能力を上げる
ことができる。すなわち、第1図の場合、Gユニット3
の加算器は固定小数点加減算、1G星演算および論理演
算を行うのに対して、Fユニット2の加算器は、2進加
減算を行う機能だけを具備すれば、浮動小数点命令と乗
除算を実行できるので、2進加減算のみを考慮して構成
すればよく、Gユニット3の加算器より必要とする金物
量は少くてよい。
The F unit 2 executes floating point instructions and fixed point multiplication/division, and the G unit 3 executes fixed point addition/subtraction, logical operations, single-point operations, privileged instructions, interrupt processing, and the like. The split configuration shown in Figure 1 increases the amount of hardware for the entire device, but since each calculation unit 2 and 3 is designed to improve functionality in its own field of expertise, the processing capacity of the entire device can be increased. can be raised. That is, in the case of FIG. 1, G unit 3
The adder in F unit 2 performs fixed-point addition and subtraction, 1G star operations, and logical operations, whereas the adder in F unit 2 only needs to have the function to perform binary addition and subtraction, and can execute floating-point instructions and multiplication and division. Therefore, it is sufficient to configure the adder considering only binary addition and subtraction, and the amount of hardware required is smaller than that of the adder of the G unit 3.

他方、Gユニット3の加算器は、要求される演算の種類
数がFユニット2の加算器より多いが、乗除算等の演算
ループとなるような命令はFユニット2で行っているの
で、Gユニット3では加算器の1マシン・サイクル内に
とる時間を長く設定することが可能である。
On the other hand, the adder in G unit 3 requires more types of operations than the adder in F unit 2, but since instructions that result in an operation loop such as multiplication and division are performed in F unit 2, In unit 3, it is possible to set the time taken within one machine cycle of the adder to be long.

次に、演算器1に対する入力データについて着目した場
合、Fユニット2では浮動小数点命令と乗除算命令の第
1および第2オペランドを入力するための汎用レジスタ
、浮動小数点レジスタ、ストレツジおよびインタフェー
スを用意すればよいのに対して、Gユニット3では、一
般命令の2つのオペランドのデータ入力の他に、特権命
令等を処理するために、装置内の制御情報(プログラム
状態語、制御レジスタの内容等)や入出力チャネルのチ
ャネル・アドレスの送出等、装置内で連絡すべきリソー
スの数が多い。
Next, when focusing on the input data to the arithmetic unit 1, the F unit 2 must prepare general-purpose registers, floating-point registers, storage, and interfaces for inputting the first and second operands of floating-point instructions and multiplication/division instructions. In contrast, in the G unit 3, in addition to data input of the two operands of a general instruction, in order to process privileged instructions, etc., the G unit 3 inputs control information within the device (program status word, contents of control registers, etc.) There are many resources that need to be communicated within the device, such as sending channel addresses for input and output channels.

したがって、Gュニット3では、前述のように、半導体
集積回路が入出力ピン数に物理的制約を加えられるため
、加算器の上位と下位のビット位置を実装上近接して設
置することが難しくなる。このように、第1図の構成に
おけるGユニット3の加算器はFユニット2に比較して
、演算ユニット自体への入力データ・パス数が多く、か
つ加算器に要求される演算の種類数が多いので、Fユニ
ット2に比較して実装上近接させて配置することが難し
い。
Therefore, in Gunit 3, as mentioned above, the semiconductor integrated circuit is subject to physical constraints on the number of input/output pins, which makes it difficult to place the upper and lower bit positions of the adder close to each other due to implementation. . In this way, the adder in G unit 3 in the configuration shown in FIG. Since there are many units, it is difficult to arrange them closer to each other than the F unit 2 in terms of mounting.

したがって、1マシン・サイクル内での所定の時間内に
桁上げを行うことが難しくなる。本発明の目的は、この
ような問題を解決するため、加算器の桁上げを所定のマ
シン・サイクル内に伝達することが困難な場合に、装置
のマシン・サイクル内で処理性能を劣化さることなく、
加減算を実行する演算制御方式を提供することにある。
Therefore, it becomes difficult to perform a carry within a predetermined time within one machine cycle. An object of the present invention is to solve such problems by reducing the processing performance within the machine cycle of the device when it is difficult to transmit the carry of the adder within a predetermined machine cycle. Without,
The object of the present invention is to provide an arithmetic control method for performing addition and subtraction.

本発明の演算制御方式は、入力データ長の上位部分を演
算する上位加算器と、下位部分を演算する下位加算器と
からなり、各々1サイクルで演算結果を出力する2つの
加算器、前記下位加算器で生じた上位への桁上げを保持
する第1のフリップフロツプ、該第1のフリツプフロッ
プの桁上げを次サイクルで前記上位加算器に与える第2
のフリップフロップ、および比較命令時に動作作し、前
記上位加算器での等価、桁上げの有無、前記下位加算器
での等価、桁上げの有無を、それぞれ入力して判定する
条件判定手段を有し、加算命令時には、第1のサイクル
で下位を入力して前記下位加算器で加算した後、第2サ
イクルで上位を入力して前記上位加算器で加算するとと
もに、比較命令時には、上位、下位を同時に減算動作さ
せ、下位から上位に桁上げを伝搬することなく、条件判
定手段で判定することに特徴がある。
The arithmetic control method of the present invention consists of an upper adder that calculates the upper part of an input data length and a lower adder that calculates the lower part. a first flip-flop that holds the carry to the higher order generated in the adder; a second flip-flop that supplies the carry of the first flip-flop to the upper adder in the next cycle;
a flip-flop, and a condition determining means that operates at the time of a comparison instruction and determines by inputting the equality in the upper adder, the presence or absence of a carry, and the equality in the lower adder, and the presence or absence of a carry, respectively. However, in the case of an addition instruction, after inputting the lower part in the first cycle and adding it in the lower adder, in the second cycle, inputting the higher part and adding it in the upper adder, and in the case of a comparison command, the upper and lower The characteristic is that the condition determination means performs a subtraction operation at the same time, and the condition determination means determines the carry without propagating the carry from the lower to the upper.

以下、本発明の実施例を、図面により説明する。Embodiments of the present invention will be described below with reference to the drawings.

第2図は、本発明による加算器のブロック構成図である
FIG. 2 is a block diagram of an adder according to the present invention.

以後、説明の都合上、基本データ幅を8バイトと仮定す
る。
Hereinafter, for convenience of explanation, it is assumed that the basic data width is 8 bytes.

Xレジスタ4とYレジスタ5は、それぞれ8バイト・レ
ジスタで、加算器へのX側入力とY側入力とになる。
X register 4 and Y register 5 are each 8-byte registers and serve as the X-side input and Y-side input to the adder.

なお、X側入力レジスタ4、Y側入力レジスタ5とも1
本ずつの入力線を有しているが、それぞれ複数本ずつ有
していてもよい。また、加算器6は、Xレジスタ4の上
位4バイトとYレジスタ5の上位4バイトを入力して4
バイトの加算を行う上位加算器であり、加算器7はXレ
ジスタ4の下位4バイトとYレジスタ5の下位4バイト
を入力して4バイトの加算を行う下位加算器である。加
算器6,7の演算結果を記憶する出力レジスタ8,9は
、信号線104を介してXレジスタ4あるいはYレジス
タ5に演算結果を戻すことができる。また「フリツプ・
フロツプ1川ま下位4バイトの最上位ビットからのキャ
リーを記憶するもので、フリップ・フロッブ11は8バ
イトを加減算を行う場合に下位キャリーを上位キャリー
に伝達するディレィ・フリップ・フロツプである。さら
に、条件判定部12は、比較命令により減算した結果を
判定するものである。なお、Xレジスタ4、Yレジスタ
5は、汎用レジスタあるいは記憶装置とデータの転送を
行うため、あるいはシフタ等、演算器内の他の演算ユニ
ットとデータ転送を行うために、適当なデータ・パスが
設けられるが、直接関係がないので省略してある。第2
図では、×レジスタ4、Yレジスタ5から加算器6,7
に入力されたデータは、加算器6,7において所要の演
算を実施された後、出力レジス夕8,9を経由して信号
線104からXレジスタ4、Yレジスタ5に戻るまでに
、1マシン・サイクルが割当てられる。
Note that both the X-side input register 4 and the Y-side input register 5 are 1.
Although each input line has one input line, each input line may have a plurality of input lines. Additionally, the adder 6 inputs the upper 4 bytes of the X register 4 and the upper 4 bytes of the Y register 5, and
The adder 7 is a high-order adder that performs byte addition, and the adder 7 is a low-order adder that inputs the lower 4 bytes of the X register 4 and the lower 4 bytes of the Y register 5 and performs 4-byte addition. Output registers 8 and 9 that store the calculation results of adders 6 and 7 can return the calculation results to X register 4 or Y register 5 via signal line 104. Also, “Flip
Flop 1 stores the carry from the most significant bit of the lower four bytes, and flip-flop 11 is a delay flip-flop that transmits the lower carry to the upper carry when adding or subtracting 8 bytes. Furthermore, the condition determination unit 12 determines the result of subtraction using a comparison instruction. Note that the X register 4 and Y register 5 are connected to an appropriate data path in order to transfer data with a general-purpose register or storage device, or with other arithmetic units in the arithmetic unit such as a shifter. Although it is provided, it is omitted because it is not directly related. Second
In the figure, adders 6 and 7 are added from × register 4 and Y register 5.
After the data input to the adders 6 and 7 perform the necessary operations, the data is processed by one machine before returning from the signal line 104 to the X register 4 and Y register 5 via the output registers 8 and 9. - Cycles are assigned.

加算器6,7は、論理和、論理積、排他的論理和等の論
理演算と、2進数あるいは1G隻数の加減算を実行する
機能を備えている。
The adders 6 and 7 have functions of performing logical operations such as logical sum, logical product, and exclusive logical sum, and addition and subtraction of binary numbers or the number of 1G ships.

加算器で信号伝達に最も時間を費すのは、最下位ビット
から最上位ビットへのキャリーの伝達であるが、論理演
算では上位ビットと下位ビット間での信号伝達を必要と
しないため、ゲート段数は少〈、加減算に比べて短時間
で実行できる。したがって、第2図の加算器においては
、上位4バイトの加算器6と下位4バイトの加算器7に
2分割し、8バイトの加減算を実行するには、最初のサ
イクルで下位4バイトの加算を行い、次のサイクルで上
位4バイトの加算を行って、8バイトの加算結果を2サ
イクルで得るようにして、マシン・サイクルに対する加
算器の時間的制約を緩和すると同時に、実質的性能を劣
化させないようにするため、論理演算、比較命令および
連続演算に対して次の方法を実行する。
The most time-consuming signal transmission in an adder is the carry transmission from the least significant bit to the most significant bit, but logic operations do not require signal transmission between the upper and lower bits, so gates The number of steps is small, and it can be executed in a shorter time than addition and subtraction. Therefore, in the adder shown in Fig. 2, it is divided into two, adder 6 for the upper 4 bytes and adder 7 for the lower 4 bytes, and in order to perform addition and subtraction of 8 bytes, the adder for the lower 4 bytes must be added in the first cycle. and add the upper 4 bytes in the next cycle to obtain the 8-byte addition result in 2 cycles, which alleviates the time constraints of the adder with respect to machine cycles and at the same time reduces the actual performance. In order to prevent this, implement the following method for logical operations, comparison instructions, and continuous operations.

すなわち、論理演算に対しては、1マシン・サイクルで
8バイト処理を実行し、比較命令に対しては、8バイト
の入力データの比較を下位4バイトから上位4バイトへ
のキャリーの伝達を行うことなく、1マシン・サイクル
で比較結果を算出し、さらに連続演算に対しては、上位
4バイトと下位4バイトを演算を連続的に1サイクル・
ピッチで行うことにより、8バイトの加算器に比べて性
能の劣化を1マシン・サイクルの増加のみにとどめる。
これらの論理演算、8バイト加減算、比較命令処理およ
び連続演算について、第3図〜第6図により説明する。
That is, for logical operations, 8-byte processing is executed in one machine cycle, and for comparison instructions, 8-byte input data is compared and carry is transmitted from the lower 4 bytes to the upper 4 bytes. The comparison result is calculated in one machine cycle without any processing, and for continuous operations, the upper 4 bytes and lower 4 bytes are calculated continuously in one machine cycle.
By doing so in pitch, the performance degradation is limited to an increase of one machine cycle compared to an 8-byte adder.
These logical operations, 8-byte addition/subtraction, comparison instruction processing, and continuous operation will be explained with reference to FIGS. 3 to 6.

第2図において、8バイトの入力データと8バイトの入
力データがXレジスタ4とYレジス夕5に設定された状
態で、加算器6,7に論理演算動作が要求された場合、
加算器6,7はキャリーの伝達がないため、1マシン・
サイクル内に8バイトの論理演算を完了する。第3図は
、第2図における論理演算動作のタイム・チャートであ
る。
In FIG. 2, when 8-byte input data and 8-byte input data are set in X register 4 and Y register 5, when adders 6 and 7 are requested to perform a logical operation,
Since adders 6 and 7 do not transmit carry, one machine/machine
Completes an 8-byte logical operation within a cycle. FIG. 3 is a time chart of logical operation operations in FIG. 2.

装置の1マシン・サイクルは時刻パルスto〜t3に分
割されており、Xレジスタ(X−REG)4およびYレ
ジスタ(Y−REG)5に入力されたデータが同時に加
算器6,7に加えられると、演算結果が時刻りこ出力レ
ジスタ(0一REG)8,9にセットされ、続いて信号
線104を介してXレジスタ4およびYレジス夕5にそ
のデータが戻るので、1マシン・サイクル(第3図のE
o)で8バイトの論理演算が実行される。
One machine cycle of the device is divided into time pulses to to t3, and the data input to the X register (X-REG) 4 and the Y register (Y-REG) 5 are simultaneously added to adders 6 and 7. Then, the calculation results are set in the timer output registers (01REG) 8 and 9, and then the data is returned to the X register 4 and Y register 5 via the signal line 104, so one machine cycle (the E in figure 3
An 8-byte logical operation is performed in o).

第4図は、第2図における8バイト加減算動作のタイム
・チャートである。
FIG. 4 is a time chart of the 8-byte addition/subtraction operations in FIG.

Eoサイクルの先頭でそれぞれ8バイトの入力データが
、Xレジスタ4とYレジスタ5に入力されると、Eoサ
イクルの時刻ビーこ先ず下位4バイトの演算結果が下位
4バイト出力レジスタ(0−REG(L))9にセット
され、これと同時に下位04バイトから上位へのキャリ
ーがフリップ・フロツプFFIOにセットされる。
When 8 bytes of input data are input to the X register 4 and Y register 5 at the beginning of the Eo cycle, the operation result of the lower 4 bytes is first transferred to the lower 4 byte output register (0-REG( L)) is set to 9, and at the same time the carry from the lower 04 bytes to the upper one is set in the flip-flop FFIO.

フリツプ・フロツプ10の内容は、時刻toでフリップ
・フロップFFI Iに移送され、次のE.サイクルの
時刻ら‘,こおいて、入力Xレジスタ4の上位4バイト
と入力Yレジスタ5の上位4バイトと下位からのキャリ
ー・フリツプ・フロッブFFIIの内容により、上位4
バイトの加算結果が出力レジスタ(0−REG(U))
8にセットされる。このようにして、E,サイクルの時
刻らで出力上位4バイト・レジスタ(0一REG(U)
)8と出力下位4バイト.レジスタ(0一REG(L)
)9に8バイトの演算結果が設定され、E,サイクルの
終りの時刻toで演算結果がXレジスタ4、およびYレ
ジスタ5に転送されることにより、8バイトの加減算は
終結する。第5図は、第2図における比較命令の条件判
定部の詳細ブロック図である。
The contents of flip-flop 10 are transferred to flip-flop FFI I at time to, and the contents of flip-flop 10 are transferred to the next E. At cycle time ', the upper 4 bytes of the input X register 4, the upper 4 bytes of the input Y register 5, and the contents of the carry flip-flop FFII from the lower
Byte addition result is output register (0-REG(U))
Set to 8. In this way, the output upper 4 byte register (01 REG (U)
)8 and output lower 4 bytes. Register (01 REG (L)
) 9 is set, and the 8-byte addition/subtraction is completed by transferring the operation result to the X register 4 and the Y register 5 at time to at the end of the cycle. FIG. 5 is a detailed block diagram of the condition determination section of the comparison instruction in FIG. 2.

8バイトの2つのオペランドを比較する場合、Xレジス
タ4、Yレジスタ5の内容を×−REG,Y−REGと
すると、条件判定部は次の各条件を判定し条件コードを
設定する。
When comparing two 8-byte operands, if the contents of the X register 4 and Y register 5 are x-REG and Y-REG, the condition determining section determines the following conditions and sets a condition code.

×−REG=Y−REG X−REG<Y−REG},.....‘1,X−RE
G>Y−REG比較命令が要求されると、加算器6,7
はX−REGからY−REGを減算するが、この8バイ
ト減算においては、1マシン・サイクルで動作を完了す
る。
×-REG=Y-REG X-REG<Y-REG},. .. .. .. .. '1,X-RE
When a G>Y-REG comparison instruction is requested, adders 6 and 7
subtracts Y-REG from X-REG, but this 8-byte subtraction completes in one machine cycle.

通常、比較命令においては演算結果は不要であり、演算
結果の最上位からのキャリーと、演算結果がすべて「O
Jであるか否かの情報のみが必要となる。このため、比
較命令を実行するに際して、上位4バイト加算器6への
キヤリーは、フリップ・フロップ11とは無関係にY入
力の2の補数をとるべく強制的に「1」が加えられ、演
算終了時には、上位出力レジスタに下位バイトからのキ
ヤリ−を無視した上位4バイトに対する演算結果がセッ
トされる。
Normally, the comparison instruction does not require the operation result, and the operation result is carried from the top of the operation result and all the operation results are
Only the information as to whether it is J or not is required. Therefore, when executing the comparison instruction, "1" is forcibly added to the carry to the upper 4-byte adder 6 to take the two's complement of the Y input, regardless of the flip-flop 11, and the operation ends. Sometimes, the result of operation for the upper four bytes, ignoring the carry from the lower byte, is set in the upper output register.

いま、上位4バイトの範囲内における大小判定のもを考
えた場合、×レジスタ4の上位4バイトをX−REG(
U)、Yレジスタ5の上位4バイトをY一REG(U)
と・すると、×一REG(U)=Y−REG(U)の場
合には、減算の結果が「0」となり、×−REG(U}
<Y−REG(U)の場合には、減算結果が「0」でな
く、かつ減算結果の最上位からのキャリーが「0」であ
り、またX−REG(U)>Y−REG(U)の場合に
は、減算結果の最上位からのキャリーが「1」であるこ
とをもって、それぞれ判定できる。
Now, when considering the size judgment within the range of the upper 4 bytes, the upper 4 bytes of × register 4 are
U), upper 4 bytes of Y register 5 as Y-REG(U)
Then, if x-REG(U)=Y-REG(U), the result of subtraction is "0", and x-REG(U}
In the case of <Y-REG(U), the subtraction result is not "0" and the carry from the top of the subtraction result is "0", and ), each can be determined based on the fact that the carry from the top of the subtraction result is "1".

さて、8バイトの比較においては、加算器6,7が上位
4バイトと下位4バイトの減算を独立に行うのであるが
、上位4バイトで、X−REG(U)>Y一REG(T
)、あるいは×一REG(U)くY−REG(U)が判
定できた場合、下位4バイトの演算結果に関係なく、上
位4バイトの判定結果のみで、2つのオペランドの比較
結果が得られるのは明らかである。
Now, when comparing 8 bytes, adders 6 and 7 independently subtract the upper 4 bytes and lower 4 bytes.
), or if ×1 REG (U) × Y-REG (U) can be determined, the comparison result of the two operands can be obtained only from the determination result of the upper 4 bytes, regardless of the operation result of the lower 4 bytes. It is clear that

一方、上位4バイトの減算結果が「0」の場合には、X
レジス夕4とYレジスタ5の上位4バイトのデータが全
く等しいというだけで、8バイト・データの全体の大4
・関係は下位4バイトの減算結果によって決定される。
On the other hand, if the subtraction result of the upper 4 bytes is "0",
Just because the upper 4 bytes of register Y 4 and Y register 5 are exactly the same, the entire 8-byte data is
- The relationship is determined by the subtraction result of the lower 4 bytes.

第5図において、信号線104は上位4バイトの演算結
果がすべて「0」であるとき「1」となり、信号線10
5は上位4バイトの演算結果で、最上位ビットから上位
へキヤリーがある場合に「1」となり、信号線106は
加算器7の下位4バイトがすべて「0」の場合に「1」
となり、信号線107は下位4バイトから上位へキヤリ
ーがあるとき「1」、すなわちフリツプ・フロツプ10
と接続されている。第5図において、×−REG=Y−
REGの場合、信号線104と106がアンド回路19
に入力することにより信号線108が「IJとなり、X
一REG<Y−REGの場合、上位4バイトが等しけれ
ばアンド回路18により、また上位4バイトが等しけれ
ばアンド回路21により、オア回路23を通して信号線
110が「1」となり、さらにX−REG>Y−REG
の場合、上位4バイトが等しくなければアンド回路17
により、また上位4バイトが等しければアンド回路20
‘こより、オア回路22を通して信号線109が「1」
となる。
In FIG. 5, the signal line 104 becomes "1" when the operation results of the upper 4 bytes are all "0";
5 is the operation result of the upper 4 bytes, which becomes "1" when there is a carry from the most significant bit to the upper order, and the signal line 106 becomes "1" when the lower 4 bytes of the adder 7 are all "0".
Therefore, the signal line 107 is "1" when there is a carry from the lower 4 bytes to the upper one, that is, the flip-flop 10
is connected to. In FIG. 5, ×-REG=Y-
In the case of REG, the signal lines 104 and 106 are connected to the AND circuit 19
By inputting the signal line 108 to "IJ",
In the case of 1REG<Y-REG, if the upper 4 bytes are equal, the AND circuit 18 sets the signal line 110 to "1", and if the upper 4 bytes are equal, the AND circuit 21 sets the signal line 110 to "1" through the OR circuit 23, and then X-REG> Y-REG
In this case, if the upper 4 bytes are not equal, the AND circuit 17
Also, if the upper 4 bytes are equal, the AND circuit 20
' From this, the signal line 109 becomes "1" through the OR circuit 22.
becomes.

このような構成の条件判定部12を設けることにより、
比較命令を実施する場合に、下位4バイトから上位4バ
イトへのキヤ1」ーを無視し、各々独立な4バイト減算
を行うことによって、8バイトの比較を1マシン・サイ
クルで実行することが可能となる。
By providing the condition determining section 12 with such a configuration,
When executing a comparison instruction, it is possible to perform an 8-byte comparison in one machine cycle by ignoring the "carrier 1" from the lower 4 bytes to the upper 4 bytes and subtracting each 4 byte independently. It becomes possible.

次に、本発明の第3の特徴である連続加算動作を、第6
図により説明する。
Next, the continuous addition operation, which is the third feature of the present invention, is
This will be explained using figures.

本発明においては、通常、8バイトの加算結果を得るた
めには、2マシン・サイクルを必要とするが、X=X十
Yの連続加算のように、、前のサイクルの加算結果を次
のサイクルで新たに加えていく連続演算においては、8
バイト加算を1サイクルで行える加算器に比べると、ル
ープ性能を1サイクル低下させるのみで連続演算を行う
ことが可能である。
In the present invention, normally two machine cycles are required to obtain an 8-byte addition result, but as in the case of continuous addition of X=X0Y, the addition result of the previous cycle is transferred to the next In continuous operations where new additions are made in cycles, 8
Compared to an adder that can add bytes in one cycle, it is possible to perform continuous operations with only one cycle of deterioration in loop performance.

X=X+Yの演算ループがn回競いた場合、最終結果×
は、ふを変数Xの初期値とすると、次式により表わされ
る。
If the calculation loop of X=X+Y competes n times, the final result ×
is expressed by the following equation, where F is the initial value of the variable X.

×=ふ十宮Yi....‐■ X,Yの上位、下位4バイトをXHi,YHi, XL
i,YHiとすると、第iループ目の下位4バイトは次
式となる。
× = Fujunomiya Yi. .. .. .. -■ Upper and lower 4 bytes of X, Y as XHi, YHi, XL
When i, YHi, the lower 4 bytes of the i-th loop are as follows.

i−1 XLi=XL。i-1 XLi=XL.

十i≧。YLr…・‘3}このとき、下位4バイトから
上位へ伝わるキヤリーをCiとすると、第iループ目で
得るべき上位4バイトの演算結果は次式で表わされる。
10i≧. YLr...'3} At this time, if the carry transmitted from the lower 4 bytes to the higher order is Ci, then the operation result of the upper 4 bytes to be obtained in the i-th loop is expressed by the following equation.

X比=X地十三≦;Y瓜十三≧;Ci‐‐…‐{4}し
たがって、第n回目の加算終了時点において、X地=X
…+;≦;Y山十室三Ci‐‐…‐‘51により最終演
算結果が得られる。
X ratio =
...+;≦;The final calculation result is obtained by Y mountain, 10th room, 3 Ci--...-'51.

本発明においては、下位4バイトから上位4バイトに転
送するフリップ’フロップ10,11を用いることによ
り、連続的な加減算のオーバ・ヘッドを生ずることなく
8バイト演算を実行することができる。
In the present invention, by using flip-flops 10 and 11 that transfer data from the lower 4 bytes to the upper 4 bytes, 8-byte operations can be performed without the overhead of continuous addition and subtraction.

つまり、前記演算ループにおいて、第i回目のループで
伝達すべき下位からのキャリーを1サイクル前のキヤ1
」ーCi−1とするのである。すなわち、j−1 したがって、第n回ループの終了時点において、X…=
X地十迄;Y山十賓客Ci−‐…‐{71が得られ、前
記【5}式と第{7}式との差は、最終回の下位からの
キャリーCn−1だけ第の式の方が小さいだけである。
In other words, in the arithmetic loop, the carry from the lower order to be transmitted in the i-th loop is transferred to the carry 1 from the previous cycle.
”-Ci-1. That is, j-1 Therefore, at the end of the nth loop, X...=
From X ground to 10; Y mountain 10 guests Ci--...-{71 is obtained, and the difference between the above formula [5} and the {7} formula is that the carry Cn-1 from the bottom of the last round is is just smaller.

そこで、n回のループの後、XHn十1=XHn+Cn
−1……‘81を実行すれば、前記■式の演算ループの
上位4バイトの結果と等しい結果が得られる。
So, after n loops, XHn+1=XHn+Cn
-1...'81, a result equal to the result of the upper 4 bytes of the arithmetic loop of formula (2) can be obtained.

第6図の第1演算サイクル(ICYL)においては、1
マシン・サイクルで上位4バイトと下位4バイトの加算
器6,7により演算が実行され、演算結果が×レジスタ
4に設定される。
In the first calculation cycle (ICYL) in FIG.
In a machine cycle, the adders 6 and 7 for the upper 4 bytes and the lower 4 bytes perform calculations, and the calculation results are set in the x register 4.

この場合、上位4バイトの加算器6への下位4バイトか
らのキャリ−は、強制的に「0」にされる。
In this case, the carry from the lower 4 bytes to the adder 6 of the upper 4 bytes is forced to "0".

第1演算サイクル(ICYL)の終了時点で、下位4バ
イトから上位へのキヤリーはラッチ(FFIO)にセッ
トされ、第2演算サイクル(20YL)において上位4
バイトへの下位4バイトからのキャリーとして加算され
る。さらに、第2演算サイクル(20YL)では、演算
結果が×レジスタ4に、下位4バイトから上位4バイト
へのキヤリーがフリップ・フロツプ10なし、し11に
セットされる。以下、同じようにして、第n回目の演算
ループ終了時点では、Xレジスタ4の下位4バイトには
次式の正しい値が得られる。X机=X山十害;Yけ……
【91 一方、Xレジスタ4の上位4バイトには前記(7}式の
値が得られるが、この値は第nサイクルにおける下位4
バイトから上位バイトに対するキヤリー分だけ少ない。
At the end of the first operation cycle (ICYL), the carry from the lower 4 bytes to the upper order is set to the latch (FFIO), and in the second operation cycle (20YL), the carry from the lower 4 bytes to the upper
It is added as a carry from the lower 4 bytes to the byte. Further, in the second operation cycle (20YL), the operation result is set in the x register 4, and the carry from the lower 4 bytes to the upper 4 bytes is set in the flip-flops 10 and 11. Thereafter, in the same manner, at the end of the nth calculation loop, the correct value of the following equation is obtained in the lower four bytes of the X register 4. X machine = X mountain ten harms; Yke...
[91 On the other hand, the value of the above formula (7) is obtained in the upper 4 bytes of the X register 4, but this value is the lower 4 bytes in the nth cycle.
It is less by the carry amount from the byte to the upper byte.

そこで、第n+1演算サイクルにおいて、Xレジスタ4
の上位4バイトに対し、第nサイクル目のキャリーを加
算することにより上位4バイトの最終結果が得られる。
すなわち、最終回における加算は、上位4バイトと下位
4バイトの加算器6,7のY側入力を強制的に「0」と
し、×+0の演算を実行させ、このとき上位4バイトの
加算器6へのキヤリーとしてフリツプ・フロップ11の
内容を伝達すればよい。このようにして、加算器6,7
において、n回の演算ループをn+1回の加算を繰返す
ことにより実現できる。
Therefore, in the (n+1)th operation cycle, the X register 4
The final result of the upper 4 bytes is obtained by adding the carry of the nth cycle to the upper 4 bytes of .
That is, in the final addition, the Y-side inputs of the adders 6 and 7 of the upper 4 bytes and lower 4 bytes are forced to 0, and the operation of ×+0 is executed. The contents of the flip-flop 11 may be transmitted as a carry to the flip-flop 6. In this way, adders 6, 7
In this case, n calculation loops can be realized by repeating addition n+1 times.

このためには、第1サイクル目に、下位からのキャリー
を強制的に「0」とする制御手段と、最終サイクルにお
いてY側入力を強制的に「0」とし、×レジスタ4とフ
リツプ・フロップ11の内容を下位からのキャリーとし
てて上位4バイトの加算器6に入力できる制御手段があ
ればよい。なお、加算器6,7のXまたはY側入力に、
数ビットの左プレ・シフタと1G隼補正回路を設けるこ
とにより、2進数を1坊隼数に変換することができる。
To achieve this, a control means is required to forcibly set the carry from the lower order to "0" in the first cycle, and to forcibly set the Y-side input to "0" in the final cycle, It is sufficient if there is a control means that can input the contents of 11 as a carry from the lower order to the adder 6 of the upper 4 bytes. In addition, to the X or Y side input of adders 6 and 7,
By providing a several-bit left pre-shifter and a 1G Hayabusa correction circuit, a binary number can be converted to a 1-bit Hayabusa number.

この場合、下位から上位に行くプレ・シフタの出力に、
第2図に示すフリップ・フロップ10,11を設け、第
6図で説明したような制御を施せば簡単に実現できる。
このようにして、第1図に示すような機能分散型の演算
器において、実装的制約からGユニット3の加算器を近
接領域に配置することが難しい場合は、Gユニット3の
加算器に対し本発明を適用する一方、Fユニット2の加
算器には、1マシン・サイクルで所望のデータ幅の桁上
げを行うように設計する。
In this case, the output of the pre-shifter going from the lower to the upper
This can be easily realized by providing the flip-flops 10 and 11 shown in FIG. 2 and controlling as explained in FIG. 6.
In this way, in a functionally distributed arithmetic unit as shown in Figure 1, if it is difficult to place the adder of G unit 3 in a nearby area due to implementation constraints, the adder of G unit 3 can be While applying the present invention, the adder of F unit 2 is designed to perform carry of a desired data width in one machine cycle.

なお、Fユニット2に対する演算命令として乗除算、浮
動小数点命令を選定すると、Gユニット3で実行すべき
2進加減算は、殆んど4バイト程度となることが予想さ
れる。以上説明したように、本発明によれば、情報処理
装置のデータ幅に匹適する桁数の加算器のディレィ・タ
イムを所定のマシン・サイクル内で実現させることが困
難な場合において、処理装置の性能を劣化させることな
く、装置のデータ幅に等しい加算器を実現することがで
きる。なお、本発明は、機能分散型の演算器において、
特に効果が大であるが、これに限定されることなく、一
般に、プリント・パターンによる伝播遅延が大きい加算
器に適用すれば有効である。
Note that if multiplication/division and floating point instructions are selected as the operation instructions for the F unit 2, it is expected that the binary addition/subtraction to be executed by the G unit 3 will be approximately 4 bytes. As explained above, according to the present invention, when it is difficult to realize the delay time of an adder with a number of digits suitable for the data width of the information processing device within a predetermined machine cycle, It is possible to realize an adder with the same data width as the device without degrading performance. Note that the present invention provides a functionally distributed arithmetic unit,
This is particularly effective, but is not limited to this, and is generally effective when applied to adders with large propagation delays due to printed patterns.

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

第1図は機能分散型演算器の説明図、第2図は本発明の
実施例を示す加算器のブロック図、第3図および第4図
は第2図における論理演算と加減算の動作タイム・チャ
ート、第5図は第2図における比較命令の条件判定部の
ブロック図、第6図は第2図における連続加算の動作説
明図である。 1:演算器、2:第1の演算ユニット(Fユニット)、
3:第2の演算ユニット(Gユニット)、4:Xレジス
タ、5:Yレジスタ、6:上位4バイト加算器、7:下
位4バイト加算器、8,9:上位および下位出力レジス
夕、10:桁上げ伝達フリツプ・フロツプ、11:デイ
レイ・フリツプ・フロップ、12:条件判定部、13〜
16:反転回路、17〜21:アンド回路、22,23
:オア回路。 第1図 第2図 第3図 第4図 第5図 第6図
FIG. 1 is an explanatory diagram of a functionally distributed arithmetic unit, FIG. 2 is a block diagram of an adder showing an embodiment of the present invention, and FIGS. FIG. 5 is a block diagram of the condition determination section of the comparison instruction in FIG. 2, and FIG. 6 is an explanatory diagram of the continuous addition operation in FIG. 2. 1: arithmetic unit, 2: first arithmetic unit (F unit),
3: Second arithmetic unit (G unit), 4: X register, 5: Y register, 6: Upper 4-byte adder, 7: Lower 4-byte adder, 8, 9: Upper and lower output registers, 10 : Carry transmission flip-flop, 11: Delay flip-flop, 12: Condition judgment section, 13-
16: Inversion circuit, 17-21: AND circuit, 22, 23
:OR circuit. Figure 1 Figure 2 Figure 3 Figure 4 Figure 5 Figure 6

Claims (1)

【特許請求の範囲】[Claims] 1 入力データ長の上位部分を演算する上位加算器と、
下位部分を演算する下位加算器とからなり、各々1サイ
クルで演算結果を出力する2つの加算器、前記下位加算
器で生じた上位への桁上げを保持する第1のフリツプフ
ロツプ、該第1のフリツプフロツプの桁上げを次サイク
ルで前記上位加算器に与える第2のフリツプフロツプ、
および比較命令時に動作し、前記上位加算器での等価、
桁上げの有無、前記下位加算器での等価、桁上げの有無
を、それぞれ入力して判定する件判定手段を有し、加算
命令時には、第1のサイクルで下位を入力して前記下位
加算器で加算した後、第2サイクルで上位を入力して前
記上位加算器で加算するとともに、比較命令時には、上
位、下位を同時に減算動作させ、下位から上位に桁上げ
を伝搬することなく、条件判定手段で判定することを特
徴とする演算制御方式。
1. An upper adder that calculates the upper part of the input data length;
a low-order adder that calculates a low-order part; two adders each outputting a calculation result in one cycle; a first flip-flop that holds a carry to a high-order position generated in the low-order adder; a second flip-flop that provides a carry of the flip-flop to the upper adder in the next cycle;
and equality in the upper adder, which operates at the time of the comparison instruction,
It has a case determination means for inputting and determining the presence or absence of a carry, the equality in the lower adder, and the presence or absence of a carry, and when an addition command is issued, inputs the lower order in the first cycle and checks the lower adder. After addition, in the second cycle, the upper part is input and added by the upper adder, and at the time of a comparison instruction, the upper and lower parts are subtracted at the same time, and the condition judgment is performed without propagating the carry from the lower part to the upper part. An arithmetic control method characterized by making decisions using means.
JP54060720A 1979-05-17 1979-05-17 Arithmetic control method Expired JPS6029406B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP54060720A JPS6029406B2 (en) 1979-05-17 1979-05-17 Arithmetic control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP54060720A JPS6029406B2 (en) 1979-05-17 1979-05-17 Arithmetic control method

Publications (2)

Publication Number Publication Date
JPS55153051A JPS55153051A (en) 1980-11-28
JPS6029406B2 true JPS6029406B2 (en) 1985-07-10

Family

ID=13150391

Family Applications (1)

Application Number Title Priority Date Filing Date
JP54060720A Expired JPS6029406B2 (en) 1979-05-17 1979-05-17 Arithmetic control method

Country Status (1)

Country Link
JP (1) JPS6029406B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4754421A (en) * 1985-09-06 1988-06-28 Texas Instruments Incorporated Multiple precision multiplication device
JPH0776913B2 (en) * 1988-02-08 1995-08-16 株式会社東芝 Arithmetic logic circuit
JPH0784758A (en) * 1994-07-15 1995-03-31 Hitachi Ltd Processor

Also Published As

Publication number Publication date
JPS55153051A (en) 1980-11-28

Similar Documents

Publication Publication Date Title
US5473554A (en) CMOS multiplexor
US3723715A (en) Fast modulo threshold operator binary adder for multi-number additions
EP0100511B1 (en) Processor for fast multiplication
US5844830A (en) Executing computer instrucrions by circuits having different latencies
US4639886A (en) Arithmetic system having pipeline structure arithmetic means
US6138135A (en) Propagating NaNs during high precision calculations using lesser precision hardware
EP0551934A2 (en) Digital signal processor
US6411980B2 (en) Data split parallel shifter and parallel adder/subtractor
JPH02294819A (en) Floating point arithmetic processor
JPH06236257A (en) Method and apparatus for post-normalization at inside of floating-point execution unit in data processor
US4172288A (en) Binary or BCD adder with precorrected result
US5285406A (en) High speed mixed radix adder
US5301139A (en) Shifter circuit for multiple precision division
EP0135721B1 (en) High performance parallel vector processor
US6578063B1 (en) 5-to-2 binary adder
JPS5914770B2 (en) data processing equipment
US4065666A (en) Multiply-divide unit
US5363322A (en) Data processor with an integer multiplication function on a fractional multiplier
US6519621B1 (en) Arithmetic circuit for accumulative operation
CN113407235B (en) Operation circuit system and chip based on hardware acceleration
US5506800A (en) Self-checking complementary adder unit
JPS6227412B2 (en)
US5867413A (en) Fast method of floating-point multiplication and accumulation
JPS6029406B2 (en) Arithmetic control method
JPH07107664B2 (en) Multiplication circuit