JP2915131B2 - Data processing device - Google Patents

Data processing device

Info

Publication number
JP2915131B2
JP2915131B2 JP30242290A JP30242290A JP2915131B2 JP 2915131 B2 JP2915131 B2 JP 2915131B2 JP 30242290 A JP30242290 A JP 30242290A JP 30242290 A JP30242290 A JP 30242290A JP 2915131 B2 JP2915131 B2 JP 2915131B2
Authority
JP
Japan
Prior art keywords
register
instruction
stage
read
instructions
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 - Fee Related
Application number
JP30242290A
Other languages
Japanese (ja)
Other versions
JPH04175930A (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 JP30242290A priority Critical patent/JP2915131B2/en
Publication of JPH04175930A publication Critical patent/JPH04175930A/en
Application granted granted Critical
Publication of JP2915131B2 publication Critical patent/JP2915131B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は、マイクロプロセッサの如きデータ処理装置
に係わり、特に、並列処理RISCプロセッサの複数命令同
時実行の処理方式に関する。
Description: BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a data processing device such as a microprocessor, and more particularly, to a processing method for simultaneously executing a plurality of instructions in a parallel RISC processor.

〔従来の技術〕[Conventional technology]

従来の装置は、特開昭63−49843号公報に記載のよう
に、演算器の入力レジスタの入力はレジスタファイルの
出力ポートのみに接続し、演算器の出力は、演算器固有
の出力ポートのみに接続していた。尚、本願の先願では
あるが、特開平3−245223号公報に、第1、第2の演算
器へのデータを入力ラッチと出力ラッチのいずれかに選
択入力させるデータ依存判別回路が開示されている。し
かし、特開平3−245223号公報には、複数のバイパス経
路の優先順位決定手段については開示も示唆もされてい
ない。
In the conventional device, as described in JP-A-63-49843, the input of the input register of the arithmetic unit is connected only to the output port of the register file, and the output of the arithmetic unit is only the output port specific to the arithmetic unit. Was connected to. As a prior application of the present application, Japanese Patent Application Laid-Open No. 3-245223 discloses a data dependence discriminating circuit for selectively inputting data to the first and second arithmetic units to either an input latch or an output latch. ing. However, Japanese Patent Application Laid-Open No. 3-245223 does not disclose or suggest priority order determining means for a plurality of bypass paths.

〔発明が解決しようとする課題〕[Problems to be solved by the invention]

上記従来例では、命令を(1)レジスタ読出し、
(2)演算、(3)レジスタ書込みの3ステージに分け
て実行するパイプライン処理方式を採用する際、レジス
タ読出しのステージにある命令の読出しレジスタ番号
が、演算ステージにある命令の書込みレジスタ番号に一
致する場合について配慮されておらず、演算ステージに
ある命令の実行結果が、引き続く命令であるレジスタ読
出しステージにある命令のオペランドデータに反映され
ないという問題があった。
In the above conventional example, the instruction is (1) read from the register,
When a pipeline processing method is used in which execution is performed in three stages of (2) operation and (3) register write, the read register number of the instruction in the register read stage is changed to the write register number of the instruction in the operation stage. No consideration is given to the case of coincidence, and there has been a problem that the execution result of the instruction in the operation stage is not reflected in the operand data of the instruction in the register read stage, which is the subsequent instruction.

本発明の目的は、上記の場合のようにレジスタ番号が
一致しても、演算ステージにある命令の実行結果が、正
しく次の命令(つまり、レジスタ読出し(ステージにあ
る命令)に反映できる手段を提供することにある。
It is an object of the present invention to provide a means for enabling the execution result of an instruction in an operation stage to be correctly reflected in the next instruction (that is, register reading (instruction in a stage)) even if the register numbers match as in the above case. To provide.

本発明の他の目的は、上記の場合のようにレジスタ番
号が一致しても、デイレイサイクルを挿入することな
く、演算ステージにある命令の実行結果を正しく次の命
令に反映できる手段を提供することにある。
Another object of the present invention is to provide means for correctly reflecting the execution result of an instruction in an operation stage to the next instruction without inserting a delay cycle even if the register numbers match as in the above case. It is in.

本発明の更にまた他の目的は、上記の場合のようにレ
ジスタ番号が一致しても、デイレイサイクルを挿入する
ことなく、演算ステージにある複数の命令の実行結果
を、正しく次の複数の命令に反映できる手段を提供する
ことにある。
Still another object of the present invention is to correct the execution results of a plurality of instructions in the operation stage without inserting a delay cycle even if the register numbers match as in the above case, and to correctly execute the next plurality of instructions. It is to provide a means that can be reflected in the information.

〔課題を解決するための手段〕[Means for solving the problem]

上記目的を達成するために、演算器の入力レジスタの
入力は、レジスタファイルの出力ポートのみならず、演
算器の出力も接続されており、選択的にデータ入力がで
きるようにしたものである。
In order to achieve the above object, the input of the input register of the arithmetic unit is connected not only to the output port of the register file but also to the output of the arithmetic unit so that data can be selectively input.

また、レジスタ読出しステージにある命令の読出しレ
ジスタフィールドと、演算ステージにある命令の書込み
レジスタフィールドを比較する手段を設け、一致した場
合には、レジスタファイルからの読出しの代わりに、該
当する演算器の出力を直接、演算器の入力レジスタへセ
ットする手段を設けたものである。さらに、該レジスタ
読出しステージにある命令の読出しレジスタ番号が、該
演算ステージにある複数の命令の書込みレジスタ番号と
一致しているとき、該複数の命令のうち最新の演算結果
を示す命令に対応する演算器からの入力手段を優先的に
該入力レジスタへセットする優先順位決定手段を設けた
ものである。
Further, means for comparing the read register field of the instruction in the register read stage with the write register field of the instruction in the operation stage is provided, and when they match, instead of reading from the register file, A means for directly setting the output to the input register of the arithmetic unit is provided. Further, when the read register number of the instruction in the register read stage matches the write register number of a plurality of instructions in the operation stage, the instruction corresponding to the instruction indicating the latest operation result among the plurality of instructions. There is provided priority order determining means for preferentially setting input means from the arithmetic unit to the input register.

〔作用〕[Action]

並列に実行される複数(n個)の命令のうち、第i番
目の命令は、第i番目の演算器で演算されるものとす
る。
The i-th instruction among the plurality (n) of instructions executed in parallel is assumed to be operated by the i-th arithmetic unit.

レジスタ読出しステージにある複数の命令のうち第i
番目の命令(第1の命令)において、上記第1の命令の
読出しレジスタ番号が、演算ステージにあるn個の命令
の書込みレジスタ番号のどれとも一致しない場合は、レ
ジスタファイルから該当するレジスタ番号の内容を読出
して、第i番目の演算器の入力レジスタへセットする。
一方、演算ステージにあるn個の命令のうち第j番目の
命令(第2の命令)の書込みレジスタ番号と一致する場
合には、レジスタファイルからの読出しの代わりに、第
j番目の演算器の演算結果を、直接、第i番目の演算器
の入力レジスタへセットする。それによって、第1の命
令は、第2の命令の実行結果を正しく反映することがで
きるので、誤動作することはない。
I-th instruction among a plurality of instructions in the register read stage
In the second instruction (first instruction), if the read register number of the first instruction does not match any of the write register numbers of the n instructions in the operation stage, the corresponding register number is read from the register file. The contents are read out and set in the input register of the i-th computing unit.
On the other hand, when the write register number of the j-th instruction (the second instruction) among the n instructions in the operation stage matches, the readout from the register file is performed instead of reading from the register file. The operation result is directly set in the input register of the i-th operation unit. Thereby, the first instruction can correctly reflect the execution result of the second instruction, and does not malfunction.

また、演算ステージにある複数の命令の書込みレジス
タ番号が、一致しているときに、更にこのレジスタ番号
に、上記第1の命令の読出しレジスタ番号が一致した場
合には、レジスタ番号が一致した命令のうちで本来、最
も遅く実行されるはずの命令、つまり番号の最も大きい
命令(第3の命令)に対応する演算器の出力を選んで、
第i番目の演算器の入力レジスタへセットする。また、
レジスタファイルへの書込みにおいても、上記第3の命
令の実行結果が有効になるように、第3の命令の演算結
果のみを書込み、書込みレジスタ番号の一致している他
の命令の演算結果をレジスタファイルへ書込まないよう
にする。これにより、レジスタファイルの内容及び第1
の命令において、第3の命令の実行結果が有効となり、
誤動作することはない。
When the write register numbers of a plurality of instructions in the operation stage match, and when the read register number of the first instruction matches the register number, the instruction whose register number matches Of the instructions, the output of the arithmetic unit corresponding to the instruction that should be executed latest, that is, the instruction with the largest number (third instruction) is selected.
It is set in the input register of the ith arithmetic unit. Also,
In writing to the register file, only the operation result of the third instruction is written and the operation result of another instruction having the same write register number is written in the register so that the execution result of the third instruction becomes valid. Do not write to file. As a result, the contents of the register file and the first
, The execution result of the third instruction becomes valid,
There is no malfunction.

〔実施例〕〔Example〕

以下、本発明の一実施例を第1図を用いて説明する。 Hereinafter, an embodiment of the present invention will be described with reference to FIG.

第1図は本発明の一実施例である2つの命令を並列に
実行するプロセッサ100のブロック図である。
FIG. 1 is a block diagram of a processor 100 that executes two instructions in parallel according to an embodiment of the present invention.

プロセッサ100は主にレジスタファイル110、2つの演
算器120,130、命令レジスタ140,141,150,151,160,161、
及び命令バッファ180からなる。
The processor 100 mainly includes a register file 110, two operation units 120 and 130, instruction registers 140, 141, 150, 151, 160, and 161.
And an instruction buffer 180.

レジスタファイル110は、R0からR31までの32本のレジ
スタからなる。
The register file 110 includes 32 registers R0 to R31.

演算器120,130はそれぞれ、A側入力レジスタ121,13
1、及びB側入力レジスタ122,132に接続している。
Arithmetic units 120 and 130 are A-side input registers 121 and 13 respectively.
1 and B side input registers 122 and 132.

また、入力レジスタ121,122,131,132の入力ポートに
はセレクタ124,125,134,135が接続されている。
Selectors 124, 125, 134, and 135 are connected to input ports of the input registers 121, 122, 131, and 132, respectively.

セレクタ124は、レジスタファイルの読み出しポート1
11及び2つの演算器の出力126,136のうち1つを選択し
て、入力レジスタ121に入力する。
The selector 124 is a register file read port 1
11 and one of the outputs 126 and 136 of the two arithmetic units are selected and input to the input register 121.

セレクタ125は、レジスタファイルの読み出しポート1
12及び2つの演算器の出力126,136のうち1つを選択し
て、入力レジスタ122に入力する。
Selector 125 is the register file read port 1
12 and one of the outputs 126 and 136 of the two arithmetic units are selected and input to the input register 122.

セレクタ134は、レジスタファイルの読み出しポート1
13及び2つの演算器の出力126,136のうち1つを選択し
て、入力レジスタ131に入力する。
The selector 134 is a register file read port 1
13 and one of the outputs 126 and 136 of the two arithmetic units are selected and input to the input register 131.

セレクタ135は、レジスタファイルの読み出しポート1
14及び2つの演算器の出力126,136のうち1つを選択し
て、入力レジスタ132に入力する。
Selector 135 is a register file read port 1
14 and one of the outputs 126 and 136 of the two arithmetic units are selected and input to the input register 132.

命令レジスタ140,150,160は直列に接続されており、
命令バッファ180から転送された偶数番地の命令は、命
令レジスタ140,150,160を順に送られていく。
The instruction registers 140, 150, 160 are connected in series,
The even-numbered instruction transferred from the instruction buffer 180 is sequentially sent to the instruction registers 140, 150, and 160.

命令レジスタ141,151,161は直列に接続されており、
命令バッファ180から転送された奇数番地の命令は、命
令レジスタ141,151,161を順に送られていく。
The instruction registers 141, 151, 161 are connected in series,
The odd-numbered instruction transferred from the instruction buffer 180 is sequentially sent to the instruction registers 141, 151, and 161.

命令バッファ180は、メインメモリ又はキャッシュメ
モリから読み出された命令を一時的に蓄えている。
The instruction buffer 180 temporarily stores an instruction read from the main memory or the cache memory.

本実施例のプロセッサで扱う命令(例えば140)は、
4つのフィールドからなり、第1のフィールドは命令
(演算)の種類を示すOPコード部(140a)と第1のソー
スオペランド(演算器のA側入力)を示す第1ソース部
(140b)と第2のソースオペランド(演算器のB側入
力)を示す第2ソース部(140c)とデスティネーション
オペランド(演算器の出力先)を示すデスティネーショ
ン部(140d)からなる。
The instructions (for example, 140) handled by the processor of this embodiment are:
The first field includes an OP code section (140a) indicating the type of instruction (operation), a first source section (140b) indicating the first source operand (A-side input of the arithmetic unit), and a fourth field. A second source unit (140c) indicating the two source operands (B-side input of the arithmetic unit) and a destination unit (140d) indicating the destination operand (the output destination of the arithmetic unit).

本実施例のプロセッサは命令の実行を3つのステージ
に分割して、パイプライン的に処理している。
The processor of this embodiment divides the execution of an instruction into three stages and processes the instruction in a pipeline.

3つのステージとは、(1)レジスタの読み出しステ
ージ、(2)演算実行ステージ、(3)レジスタへの書
き込みステージの3つである。
The three stages are (1) a register read stage, (2) an operation execution stage, and (3) a register write stage.

命令レジスタ140,141は上記レジスタの読み出しステ
ージにある命令を保持し、命令レジスタ150,151は上記
演算実行ステージにある命令を保持し、命令レジスタ16
0,161は上記レジスタへの書き込みステージにある命令
を保持している。
The instruction registers 140 and 141 hold the instruction in the read stage of the register, the instruction registers 150 and 151 hold the instruction in the operation execution stage, and the instruction register 16
0,161 holds the instruction in the writing stage to the register.

以下、命令を実行する様子をサイクルごとに説明す
る。
Hereinafter, the execution of the instruction will be described for each cycle.

第1のサイクルでは、メモリから読み出された命令は
まず、命令バッファ180から命令レジスタ140及び141に
転送される。
In the first cycle, the instruction read from the memory is first transferred from the instruction buffer 180 to the instruction registers 140 and 141.

命令レジスタ140及び141にセットされた命令は、ソー
スオペランドをレジスタファイル110から読み出し、演
算器の入力レジスタ121,122,131,132にセットする。
The instructions set in the instruction registers 140 and 141 read the source operand from the register file 110 and set them in the input registers 121, 122, 131, and 132 of the arithmetic unit.

ここでレジスタファイルの読み出しポート111は命令
レジスタ140の第1ソース部140bで示されたレジスタ番
号のレジスタの内容を読み出し、レジスタファイルの読
み出しポート112は命令レジスタ140の第2ソース部140c
で示されたレジスタ番号のレジスタの内容を読み出し、
レジスタファイルの読み出しポート113は命令レジスタ1
41の第1ソース部141bで示されたレジスタ番号のレジス
タの内容を読み出し、レジスタファイルの読み出しポー
ト114は命令レジスタ141の第2ソース部141cで示された
レジスタ番号のレジスタの内容を読み出す。
Here, the register file read port 111 reads the contents of the register having the register number indicated by the first source section 140b of the instruction register 140, and the register file read port 112 reads the second source section 140c of the instruction register 140.
Read the contents of the register with the register number indicated by
Register file read port 113 is instruction register 1
The contents of the register with the register number indicated by the first source section 141b of 41 are read, and the register file read port 114 reads the contents of the register with the register number indicated by the second source section 141c of the instruction register 141.

第2のサイクルでは、命令レジスタ140及び141にセッ
トされた命令は、それぞれ命令レジスタ150及び151に転
送される。
In the second cycle, the instructions set in the instruction registers 140 and 141 are transferred to the instruction registers 150 and 151, respectively.

命令レジスタ150及び151にセットされた命令は、演算
器の入力レジスタ121,122,131,132にセットされたオペ
ランドデータを演算器120,130を用いて演算し、演算の
結果は出力レジスタ123,133にセットする。
The instructions set in the instruction registers 150 and 151 operate the operand data set in the input registers 121, 122, 131 and 132 of the operation units by using the operation units 120 and 130, and set the operation results in the output registers 123 and 133.

なおここで、演算器120は、命令レジスタ150のOPコー
ド部150aを解読するデコーダ152の出力信号により制御
され、演算器130は、命令レジスタ151のOPコード部151a
を解読するデコーダ153の出力信号により制御される。
Here, the arithmetic unit 120 is controlled by an output signal of a decoder 152 that decodes the OP code section 150a of the instruction register 150, and the arithmetic unit 130 is controlled by the OP code section 151a of the instruction register 151.
Is controlled by the output signal of the decoder 153 that decodes

第3のサイクルでは、命令レジスタ150及び151にセッ
トされた命令は、それぞれ命令レジスタ160及び161に転
送される。命令レジスタ160及び161にセットされた命令
は、命令の実行結果(出力レジスタ123,133の内容)を
レジスタファイルのデスティネーションオペランドへ書
き込む。なおここで、レジスタファイルの書き込みポー
ト115は命令レジスタ160のデスティネーション部160dで
示されたレジスタ番号のレジスタへ書き込み、レジスタ
ファイルの書き込みポート116は命令レジスタ161のデス
ティネーション部161dで示されたレジスタ番号のレジス
タへ書き込む。
In the third cycle, the instructions set in the instruction registers 150 and 151 are transferred to the instruction registers 160 and 161 respectively. The instruction set in the instruction registers 160 and 161 writes the execution result of the instruction (the contents of the output registers 123 and 133) to the destination operand of the register file. Here, the register file write port 115 writes to the register of the register number indicated by the destination section 160d of the instruction register 160, and the register file write port 116 is the register indicated by the destination section 161d of the instruction register 161. Write to the number register.

次に、本発明の特徴である比較器171,172,173,174,17
5,176,177,178について説明する。
Next, the comparators 171, 172, 173, 174, 17 which are features of the present invention.
5,176,177,178 will be described.

比較器171は、命令レジスタ140の第1ソース部140bと
命令レジスタ151のデスティネーション部151dとを比較
し、レジスタ番号が一致している場合は、セレクタ124
を制御して、レジスタファイルの読み出しポート111の
代わりに、演算器130の出力136を選択して入力レジスタ
121に入力する。
The comparator 171 compares the first source part 140b of the instruction register 140 with the destination part 151d of the instruction register 151, and when the register numbers match, the selector 124
By selecting the output 136 of the arithmetic unit 130 instead of the read port 111 of the register file
Enter 121.

比較器172は、命令レジスタ140の第1ソース部140bと
命令レジスタ150のデスティネーション部150dとを比較
し、レジスタ番号が一致している場合は、セレクタ124
を制御して、レジスタファイルの読み出しポート111の
代わりに、演算器120の出力126を選択して入力レジスタ
121に入力する。
The comparator 172 compares the first source part 140b of the instruction register 140 with the destination part 150d of the instruction register 150, and when the register numbers match, the selector 124
By selecting the output 126 of the computing unit 120 instead of the read port 111 of the register file
Enter 121.

なお上記の比較器171,172が共に一致を検出した場合
は、比較器171の制御を優先させる。優先回路190は上記
の処理を行うための回路である。
If both the comparators 171 and 172 detect coincidence, the control of the comparator 171 is prioritized. The priority circuit 190 is a circuit for performing the above processing.

比較器173は、命令レジスタ140の第2ソース部140cと
命令レジスタ151のデスティネーション部151dとを比較
し、レジスタ番号が一致している場合は、セレクタ125
を制御して、レジスタファイルの読み出しポート112の
代わりに、演算器130の出力136を選択して入力レジスタ
122に入力する。
The comparator 173 compares the second source section 140c of the instruction register 140 with the destination section 151d of the instruction register 151. If the register numbers match, the selector 125
To select the output 136 of the arithmetic unit 130 instead of the read port 112 of the register file,
Enter 122.

比較器174は、命令レジスタ140の第2ソース部140cと
命令レジスタ150のデスティネーション部150dとを比較
し、レジスタ番号が一致している場合は、セレクタ125
を制御して、レジスタファイルの読み出しポート112の
代わりに、演算器120の出力126を選択して入力レジスタ
122に入力する。
The comparator 174 compares the second source section 140c of the instruction register 140 with the destination section 150d of the instruction register 150. If the register numbers match, the selector 125
To select the output 126 of the computing unit 120 instead of the register file read port 112, and
Enter 122.

なお上記の比較器173,174が共に一致を検出した場合
は、比較器173の制御を優先させる。優先回路191は上記
の処理を行うための回路である。
If both the comparators 173 and 174 detect coincidence, the control of the comparator 173 is prioritized. The priority circuit 191 is a circuit for performing the above processing.

比較器175は、命令レジスタ141の第1ソース部141bと
命令レジスタ151のデスティネーション部151dとを比較
し、レジスタ番号が一致している場合は、セレクタ134
を制御して、レジスタファイルの読み出しポート113の
代わりに、演算器130の出力136を選択して入力レジスタ
131に入力する。
The comparator 175 compares the first source part 141b of the instruction register 141 with the destination part 151d of the instruction register 151, and when the register numbers match, the selector 134
To select the output 136 of the arithmetic unit 130 instead of the read port 113 of the register file,
Enter 131.

比較器176は、命令レジスタ141の第1ソース部141bと
命令レジスタ150のデスティネーション部150dとを比較
し、レジスタ番号が一致している場合は、セレクタ134
を制御して、レジスタファイルの読み出しポート113の
代わりに、演算器120の出力126を選択して入力レジスタ
131に入力する。
The comparator 176 compares the first source part 141b of the instruction register 141 with the destination part 150d of the instruction register 150, and when the register numbers match, the selector 134
To select the output 126 of the arithmetic unit 120 instead of the read port 113 of the register file, and
Enter 131.

なお上記の比較器175,176が共に一致を検出した場合
は、比較器175の制御を優先させる。優先回路192は上記
の処理を行うための回路である。
If both of the comparators 175 and 176 detect a match, the control of the comparator 175 is prioritized. The priority circuit 192 is a circuit for performing the above processing.

比較器177は、命令レジスタ141の第2ソース部141cと
命令レジスタ151のデスティネーション部151dとを比較
し、レジスタ番号が一致している場合は、セレクタ135
を制御して、レジスタファイルの読み出しポート114の
代わりに、演算器130の出力136を選択して入力レジスタ
132に入力する。
The comparator 177 compares the second source part 141c of the instruction register 141 with the destination part 151d of the instruction register 151, and when the register numbers match, the selector 135
To select the output 136 of the computing unit 130 instead of the register file read port 114
Enter in 132.

比較器178は、命令レジスタ141の第2ソース部141cと
命令レジスタ150のデスティネーション部150dとを比較
し、レジスタ番号が一致している場合は、セレクタ135
を制御して、レジスタファイルの読み出しポート114の
代わりに、演算器120の出力126を選択して入力レジスタ
132に入力する。
The comparator 178 compares the second source part 141c of the instruction register 141 with the destination part 150d of the instruction register 150, and when the register numbers match, the selector 135
By selecting the output 126 of the computing unit 120 instead of the register file read port 114, and
Enter in 132.

なお上記の比較器177,178が共に一致を検出した場合
は、比較器177の制御を優先させる。優先回路193は上記
の処理を行うための回路である。
If both the comparators 177 and 178 detect a match, the control of the comparator 177 is prioritized. The priority circuit 193 is a circuit for performing the above processing.

本実施例のレジスタファイル110では、書き込みポー
ト115及び116から或るレジスタに書き込んだデータは、
そのサイクルの読み出しにおいて、読み出しポート111,
112,113,114に反映している。つまり、書き込みポート1
15でR2レジスタへデータを書き込み、同一サイクルで読
み出しポート111からR2レジスタの内容を読み出したと
き、書き込みポート115から書き込んだデータが正し
く、読み出しポート111から読みだすことができる。こ
れは、レジスタファイル内にバイパス経路を設けても実
現できるが、1サイクルのうち、前半の1/2サイクルで
レジスタファイルへの書き込みを行い、後半の1/2サイ
クルでレジスタファイルの読み出しを行えば容易に実現
できる。
In the register file 110 of the present embodiment, data written to a certain register from the write ports 115 and 116 is
In the read of the cycle, the read port 111,
Reflected on 112,113,114. That is, write port 1
When data is written to the R2 register at 15 and the contents of the R2 register are read from the read port 111 in the same cycle, the data written from the write port 115 is correct and can be read from the read port 111. This can be achieved by providing a bypass path in the register file.However, in one cycle, writing to the register file is performed in the first half cycle, and reading of the register file is performed in the second half cycle. For example, it can be easily realized.

以上本実施例によれば、従来1つの命令を実行してい
たサイクル時間の中で、2つの命令を並列に実行するこ
とができる。
As described above, according to the present embodiment, two instructions can be executed in parallel in the cycle time in which one instruction was conventionally executed.

〔発明の効果〕〔The invention's effect〕

以上説明したように、本発明によれば、複数の演算器
の出力を直接,演算器の入力レジスタへセットするため
のバイパス手段を設けているので、レジスタ読出し,演
算実行,レジスタ書込みをそれぞれ1ステージとするパ
イプライン処理プロセッサにおいても、演算実行ステー
ジの命令の演算結果を次のサイクルの演算実行にも使用
することができるので、命令の高速処理が可能になる。
As described above, according to the present invention, the bypass means for directly setting the outputs of the plurality of arithmetic units to the input registers of the arithmetic units is provided. In a pipeline processor as a stage, the operation result of the instruction in the operation execution stage can also be used for the execution of the operation in the next cycle, so that the instruction can be processed at high speed.

また、レジスタ読出しステージの命令の読出しレジス
タ番号と、演算実行ステージの命令の書込みレジスタ番
号との比較する手段を有しているので、レジスタ番号が
一致した場合は、上記のバイパス手段を使って、演算結
果を直接、演算器の入力レジスタへセットするよう制御
できるので、レジスタ内の古い値を読出すことを防止
し、更に命令の高速実行が可能となる。
In addition, since there is a means for comparing the read register number of the instruction in the register read stage with the write register number of the instruction in the operation execution stage, if the register numbers match, the above bypass means is used. Since the operation result can be controlled so as to be directly set in the input register of the operation unit, it is possible to prevent reading out the old value in the register and to execute the instruction at high speed.

さらにまた、複数のバイパス経路の優先順位決定手段
を有しているので、演算実行ステージにある複数の命令
の書込みレジスタの番号と、読出しレジスタの番号が一
致しても、最新の演算出力を選択でき、古い値を読出す
ことを防止でき、更にまた、命令の高速実行が可能とな
る。
Furthermore, since there is a plurality of priority determining means for the bypass paths, even if the numbers of the write registers and the numbers of the read registers of the plurality of instructions in the operation execution stage match, the latest operation output is selected. Thus, reading of an old value can be prevented, and furthermore, high-speed execution of an instruction becomes possible.

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

第1図は本発明の一実施例であるデータ処理装置のブロ
ック図である。 124,125,134,135……バイパス入力セレクタ、126,136…
…演算器出力のバイパス経路、171,172,173,174,175,17
6,177,178……レジスタ番号比較器、190,191,192,193…
…バイパス経路優先順位決定回路。
FIG. 1 is a block diagram of a data processing apparatus according to one embodiment of the present invention. 124,125,134,135 …… Bypass input selector, 126,136…
… Bypass path for operation unit output, 171,172,173,174,175,17
6,177,178 …… Register number comparator, 190,191,192,193…
... A bypass route priority determining circuit.

フロントページの続き (56)参考文献 久我守弘(外3名)「『新風』プロセ ッサの依存解析機能付きレジスタファイ ル」,情報処理学会第40回(平成2年前 期)全国大会論文集,平成2年(1990 年)3月14日,p.1269−1270 (58)調査した分野(Int.Cl.6,DB名) G06F 9/38 Continued on the front page (56) References Morihiro Kuga (three outsiders), "Register File with Dependency Analysis Function of" Shinpu "Processor", Proc. Of the 40th IPSJ Annual Conference , March 14, 1990, p. 1269-1270 (58) Field surveyed (Int.Cl. 6 , DB name) G06F 9/38

Claims (3)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】レジスタ番号で管理された情報を保持する
レジスタファイルと、複数の命令を並列に実行する複数
の演算器とを有するデータ処理装置において、 上記データ処理装置で実行される複数の命令の各命令
は、読み出しレジスタ番号に対応する情報を上記レジス
タファイルから読み出す読み出しステージと、演算を実
行する演算実行ステージと、上記演算器の実行結果の情
報を書き込みレジスタ番号に対応付けて上記レジスタフ
ァイルに書き込む書き込みステージとからなる3つのス
テージを有し、 上記複数の演算器のそれぞれと上記レジスタファイルと
に接続され、上記レジスタファイルの出力と上記複数の
演算器の実行結果との何れかを選択的に上記演算器に入
力するセレクタ手段と、 上記演算実行ステージにある複数の命令の上記書き込み
レジスタ番号と、上記読み出しステージにある複数の命
令の上記読み出しレジスタ番号とを比較する手段と、 上記比較する手段が、上記読み出しステージにある命令
の上記読み出しレジスタ番号と上記演算実行ステージに
ある上記複数の命令の内の何れかの命令の上記書き込み
レジスタ番号との一致を検出した際、上記演算実行ステ
ージにある上記一致した命令に対応する実行結果のうち
最新の実行結果を上記読み出しステージにある上記一致
した命令を実行する演算器に入力するように上記セレク
ト手段を制御せしめる優先順位決定手段とを有すること
を特徴とするデータ処理装置。
1. A data processing apparatus comprising: a register file holding information managed by register numbers; and a plurality of arithmetic units for executing a plurality of instructions in parallel, wherein a plurality of instructions executed by the data processing apparatus are provided. Each instruction of the above is a read stage for reading information corresponding to a read register number from the register file, an operation execution stage for executing an operation, and information on an execution result of the arithmetic unit associated with the write register number in the register file. And a write stage for writing to the plurality of arithmetic units. Each of the plurality of arithmetic units is connected to the register file, and any one of an output of the register file and an execution result of the plurality of arithmetic units is selected. Selector means for inputting the instructions to the arithmetic unit, and a plurality of instructions in the arithmetic execution stage. Means for comparing the write register number with the read register number of a plurality of instructions in the read stage; and the comparing means in the read register number of the instruction in the read stage and the operation execution stage. When detecting a match of any one of the plurality of instructions with the write register number, the latest execution result among the execution results corresponding to the matched instruction in the operation execution stage is stored in the read stage. A data processing device comprising: a priority order determining unit that controls the selecting unit so as to input the matched instruction to an arithmetic unit that executes the instruction.
【請求項2】レジスタ番号で管理された情報を保持する
レジスタファイルと、複数の命令を並列に実行する複数
の演算器とを有するデータ処理装置において、 上記データ処理装置で実行される複数の命令の各命令
は、読み出しレジスタ番号に対応する情報を上記レジス
タファイルから読み出す読み出しステージと、演算を実
行する演算実行ステージと、上記演算器の実行結果の情
報を書き込みレジスタ番号に対応付けて上記レジスタフ
ァイルに書き込む書き込みステージとからなる3つのス
テージを有し、 上記複数の演算器のそれぞれと上記レジスタファイルと
に接続され、上記レジスタファイルの出力と上記複数の
演算器の実行結果との何れかを選択的に上記演算器に入
力するセレクタ手段と、 上記演算実行ステージにある複数の命令の上記書き込み
レジスタ番号と、上記読み出しステージにある複数の命
令の上記読み出しレジスタ番号とを比較する手段と、 上記比較する手段が、上記読み出しステージにある命令
の上記読み出しレジスタ番号と上記演算実行ステージに
ある上記複数の命令の内の何れかの命令の上記書き込み
レジスタ番号との一致を検出した際、上記演算実行ステ
ージにある上記一致した命令に対応する実行結果のうち
最新の実行結果を上記読み出しステージにある上記一致
した命令を実行する演算器に直接入力するように上記セ
レクト手段を制御せしめることにより上記レジスタファ
イルをバイパスする優先順位決定手段とを有することを
特徴とするデータ処理装置。
2. A data processing apparatus comprising: a register file for holding information managed by register numbers; and a plurality of arithmetic units for executing a plurality of instructions in parallel, wherein a plurality of instructions executed by the data processing apparatus are provided. Each instruction of the above is a read stage for reading information corresponding to a read register number from the register file, an operation execution stage for executing an operation, and information on an execution result of the arithmetic unit associated with the write register number in the register file. And a write stage for writing to the plurality of arithmetic units. Each of the plurality of arithmetic units is connected to the register file, and any one of an output of the register file and an execution result of the plurality of arithmetic units is selected. Selector means for inputting the instructions to the arithmetic unit, and a plurality of instructions in the arithmetic execution stage. Means for comparing the write register number with the read register number of a plurality of instructions in the read stage; and the comparing means in the read register number of the instruction in the read stage and the operation execution stage. When detecting a match of any one of the plurality of instructions with the write register number, the latest execution result among the execution results corresponding to the matched instruction in the operation execution stage is stored in the read stage. A data processing apparatus comprising: a priority determining unit that bypasses the register file by controlling the selecting unit so as to directly input the matched instruction to an arithmetic unit that executes the matched instruction.
【請求項3】上記複数の演算器の各演算器は、それぞれ
入力レジスタと出力レジスタとに接続され、 上記演算器の出力は、上記出力レジスタの入力と上記セ
レクタ手段とに接続されており、 上記出力レジスタの出力は上記レジスタファイルの入力
ポートに接続されており、 上記入力レジスタの出力は、上記演算器の入力に接続さ
れており、上記入力レジスタの入力は上記セレクタ手段
に接続されていることを特徴とする請求項1又は2に記
載のデータ処理装置。
3. An arithmetic unit of the plurality of arithmetic units is connected to an input register and an output register, respectively, and an output of the arithmetic unit is connected to an input of the output register and the selector. An output of the output register is connected to an input port of the register file, an output of the input register is connected to an input of the arithmetic unit, and an input of the input register is connected to the selector. The data processing device according to claim 1 or 2, wherein:
JP30242290A 1990-11-09 1990-11-09 Data processing device Expired - Fee Related JP2915131B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP30242290A JP2915131B2 (en) 1990-11-09 1990-11-09 Data processing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP30242290A JP2915131B2 (en) 1990-11-09 1990-11-09 Data processing device

Publications (2)

Publication Number Publication Date
JPH04175930A JPH04175930A (en) 1992-06-23
JP2915131B2 true JP2915131B2 (en) 1999-07-05

Family

ID=17908732

Family Applications (1)

Application Number Title Priority Date Filing Date
JP30242290A Expired - Fee Related JP2915131B2 (en) 1990-11-09 1990-11-09 Data processing device

Country Status (1)

Country Link
JP (1) JP2915131B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4999361B2 (en) * 2006-05-24 2012-08-15 三洋電機株式会社 Processing equipment

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
久我守弘(外3名)「『新風』プロセッサの依存解析機能付きレジスタファイル」,情報処理学会第40回(平成2年前期)全国大会論文集,平成2年(1990年)3月14日,p.1269−1270

Also Published As

Publication number Publication date
JPH04175930A (en) 1992-06-23

Similar Documents

Publication Publication Date Title
US5530817A (en) Very large instruction word type computer for performing a data transfer between register files through a signal line path
US5043868A (en) System for by-pass control in pipeline operation of computer
JP3098071B2 (en) Computer system for efficient execution of programs with conditional branches
EP0543415B1 (en) Controlling register read operations
US5636353A (en) Superscalar processor with direct result bypass between execution units having comparators in execution units for comparing operand and result addresses and activating results bypassing
US5764943A (en) Data path circuitry for processor having multiple instruction pipelines
US6145074A (en) Selecting register or previous instruction result bypass as source operand path based on bypass specifier field in succeeding instruction
US5778248A (en) Fast microprocessor stage bypass logic enable
KR101183270B1 (en) Method and data processor with reduced stalling due to operand dependencies
JPS60167028A (en) Cpu architecture for multidata path
US6101596A (en) Information processor for performing processing without register conflicts
US5274777A (en) Digital data processor executing a conditional instruction within a single machine cycle
JP2000066894A (en) Pipelined floating point store
US6704861B1 (en) Mechanism for executing computer instructions in parallel
JP2915131B2 (en) Data processing device
US7111152B1 (en) Computer system that operates in VLIW and superscalar modes and has selectable dependency control
US5931942A (en) Pipeline data processing apparatus of reduced circuit scale
US6233675B1 (en) Facility to allow fast execution of and, or, and test instructions
US5812845A (en) Method for generating an object code for a pipeline computer process to reduce swapping instruction set
EP1050800A1 (en) A pipelined execution unit
JP2553728B2 (en) Arithmetic unit
JP2581565B2 (en) Data processing device that executes guarded instructions
US5729729A (en) System for fast trap generation by creation of possible trap masks from early trap indicators and selecting one mask using late trap indicators
JPH07110769A (en) Vliw type computer
US6289439B1 (en) Method, device and microprocessor for performing an XOR clear without executing an XOR instruction

Legal Events

Date Code Title Description
FPAY Renewal fee payment (prs date is renewal date of database)

Year of fee payment: 9

Free format text: PAYMENT UNTIL: 20080416

FPAY Renewal fee payment (prs date is renewal date of database)

Year of fee payment: 10

Free format text: PAYMENT UNTIL: 20090416

LAPS Cancellation because of no payment of annual fees