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
JPH0812599B2 - Data processing device - Google Patents
[go: Go Back, main page]

JPH0812599B2 - Data processing device - Google Patents

Data processing device

Info

Publication number
JPH0812599B2
JPH0812599B2 JP62333720A JP33372087A JPH0812599B2 JP H0812599 B2 JPH0812599 B2 JP H0812599B2 JP 62333720 A JP62333720 A JP 62333720A JP 33372087 A JP33372087 A JP 33372087A JP H0812599 B2 JPH0812599 B2 JP H0812599B2
Authority
JP
Japan
Prior art keywords
instruction
processing
branch
address
microinstruction
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 - Lifetime
Application number
JP62333720A
Other languages
Japanese (ja)
Other versions
JPH01175633A (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.)
Fujitsu Ltd
Original Assignee
Fujitsu 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 Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP62333720A priority Critical patent/JPH0812599B2/en
Publication of JPH01175633A publication Critical patent/JPH01175633A/en
Publication of JPH0812599B2 publication Critical patent/JPH0812599B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Advance Control (AREA)

Description

【発明の詳細な説明】 〔目 次〕 概要 産業上の利用分野 従来の技術(第3〜5図) 発明が解決しようとする問題点(第6図) 問題点を解決するための手段 作用 実施例 本発明の一実施例(第1、2図) 発明の効果 〔概 要〕 マイクロプログラム制御をパイプライン処理するデー
タ処理装置に関し、 条件分岐命令の処理中であってもパイプライン処理が
有効に行われ、処理速度の低下しないデータ処理装置を
提供することを目的とし、 条件分岐命令および該条件分岐命令の分岐先命令を含
む複数のマイクロ命令を格納し、アドレス指定により各
マイクロ命令が取り出される格納手段と、該格納手段か
ら一つのマイクロ命令が取り出されると、そのマイクロ
命令に続く次のマイクロ命令を指定する順次アドレスを
発生する第1のアドレス発生手段と、取り出されたマイ
クロ命令の命令種別を解読する解読手段と、解読された
命令種別が条件分岐命令のとき、条件の成立、非成立を
判定する処理を実行する実行手段と、条件分岐命令の分
岐先命令のアドレスを発生する第2のアドレス発生手段
と、条件の非成立時には第1のアドレス発生手段を選択
する一方、条件の成立時には第2のアドレス発生手段を
選択して格納手段にマイクロ命令取り出しのためのアド
レスを与える選択手段と、を備え、解読された命令種別
が条件分岐命令のとき、分岐条件の成立、非成立が判定
されるまでの間、第1のアドレス発生手段から発生され
る順次アドレスに基づいたマイクロ命令が実行され、分
岐条件が非成立の場合は、当該順次アドレスに基づいた
マイクロ命令の処理が続行されるとともに、分岐条件が
成立した場合には、前記第2のアドレス発生手段から発
生される、分岐先命令のアドレスに基づいたマイクロ命
令の処理がなされることを特徴とする。
Detailed Description of the Invention [Table of Contents] Outline Industrial field of application Conventional technology (Figs. 3 to 5) Problems to be solved by the invention (Fig. 6) Means for solving the problems Action Implementation Example One embodiment of the present invention (FIGS. 1 and 2) Effect of the invention [Overview] A data processing device for pipeline processing microprogram control, wherein pipeline processing is effective even during processing of a conditional branch instruction. A plurality of microinstructions including a conditional branch instruction and a branch destination instruction of the conditional branch instruction are stored, and each microinstruction is fetched by addressing for the purpose of providing a data processing device that does not reduce the processing speed. Storage means and, when one microinstruction is fetched from the storage means, first address generation for generating a sequential address designating the next microinstruction following the microinstruction Means, decoding means for decoding the instruction type of the fetched microinstruction, execution means for executing processing to determine whether or not the condition is satisfied when the decoded instruction type is a conditional branch instruction, and conditional branch instruction Second address generating means for generating the address of the branch destination instruction of 1) and the first address generating means when the condition is not satisfied, while the second address generating means is selected and stored in the storing means when the condition is satisfied. Selecting means for giving an address for fetching a microinstruction, and when the decoded instruction type is a conditional branch instruction, the first address generating means until the branch condition is satisfied or not is determined. If the micro instruction based on the generated sequential address is executed and the branch condition is not satisfied, the processing of the micro instruction based on the sequential address is continued and the If the conditions are satisfied, the generated from the second address generating means, characterized in that the processing of microinstructions based on the address of the branch destination instruction is carried out.

〔産業上の利用分野〕[Industrial applications]

本発明は、データ処理装置に関し、特に、マイクロプ
ログラム制御をパイプライン処理するデータ処理装置に
係り、条件分岐命令の非分岐時における処理の停滞を回
避したデータ処理装置に関する。
The present invention relates to a data processing device, and more particularly to a data processing device that pipelines microprogram control, and more particularly to a data processing device that avoids processing delay when a conditional branch instruction is not branched.

一般に、計算機等における処理は、複数の処理段階を
経て行われ、例えば、命令実行制御では、 (I)マイクロ命令の取り出し、 (II)解読、 (III)アドレス計算、 (IV)オペランド取り出し、 (V)実行、 といった多段階処理が行われる。これらの処理は、基本
的には、(I)→(II)……(V)の順序で逐次処理さ
れ、現在でも簡易なシステムではこのような逐次処理が
用いられている。しかし、このような逐次処理は処理速
度の点で問題がある。第3図は逐次処理の概念図であ
る。なお、同図において、処理Aは上述の(I)に相当
し、処理Bは(II)に相当し、処理Cは(III)に相当
し、処理Dは(IV)に相当し、処理Eは(V)に相当す
る。例えば、命令に続いて命令を処理した場合の処
理速度は次のとおりとなる。すなわち、命令は処理A
においてtA、処理BにおいてtB、処理CにおいてtC、処
理DにおいてtD、処理EにおいてtE、なる各処理遅れを
生じ、処理Aから処理Eまでの累計処理遅れTはtA+tB
+tC+tD+tEとなる。このことは命令の処理について
も同様であり、したがって、命令と命令の間にはT
〔時間〕の空白があき、近時の高速化要求に応えるため
には問題が大きい。
Generally, processing in a computer or the like is performed through a plurality of processing stages. For example, in instruction execution control, (I) fetching of micro instruction, (II) decoding, (III) address calculation, (IV) operand fetching, V) Execution, multi-step processing such as Basically, these processes are sequentially performed in the order of (I) → (II) ... (V), and such a sequential process is still used in a simple system even now. However, such sequential processing has a problem in processing speed. FIG. 3 is a conceptual diagram of sequential processing. In the figure, the process A corresponds to the above (I), the process B corresponds to the (II), the process C corresponds to the (III), the process D corresponds to the (IV), and the process E. Corresponds to (V). For example, the processing speed when an instruction is processed after the instruction is as follows. That is, the instruction is process A
In t A, t B in the process B, the process C t C, t D in the process D, t E in the process E, cause the processing delay made, total processing delay T from the processing A to the processing E is t A + t B
It becomes + t C + t D + t E. This is also true for the processing of instructions, so there is a T
There is a gap in [time], which is a big problem to meet the recent demand for high speed.

〔従来の技術〕[Conventional technology]

このような逐次処理の問題点を解決したものとしてパ
イプライン制御(Pipeline Control)が用いられる。第
4図はパイプライン処理を示す概念図である。同図にお
いて、処理Aで取り込まれた命令は次のサイクルで処
理Bに移され、同時に処理Aは次位の命令を取り込
む。そして、命令が処理Cに移ると、これに並行して
命令が処理Bに移されるとともに、処理Aは次次位の
命令を取り込んでいる。
Pipeline control is used as a solution to the problem of such sequential processing. FIG. 4 is a conceptual diagram showing pipeline processing. In the figure, the instruction fetched in the process A is moved to the process B in the next cycle, and at the same time, the process A fetches the next instruction. When the instruction moves to the process C, the instruction moves to the process B in parallel with this, and the process A fetches the next-higher-order instruction.

すなわち、このような処理A〜処理Eを並行に行うパ
イプライン制御にあっては、最初の命令の実行結果が
出るまでは、処理A〜処理Eを経なければならないの
で、逐次処理と同じ処理速度T(T=tA+tB+tC+tD
tE)となるが、命令以降では処理サイクル毎に実行結
果が得られ、仮にこのシステムが同期式の場合では、tA
=tB=tC=tD=tE=処理サイクル、であるから、その処
理遅れは一つの処理段階に相当する時間tに短縮され、
極めて高速な処理を行うことができる。
That is, in the pipeline control in which the processes A to E are performed in parallel, the processes A to E have to be performed until the execution result of the first instruction is obtained. Therefore, the same process as the sequential process is performed. Speed T (T = t A + t B + t C + t D
t E ), but after the instruction, the execution result is obtained for each processing cycle. If this system is synchronous, t A
= T B = t C = t D = t E = processing cycle, the processing delay is shortened to the time t corresponding to one processing stage,
It is possible to perform extremely high-speed processing.

また、マイクロプログラム制御においても、上述の命
令実行制御と同様にパイプライン制御が行われ、マイク
ロプログラム制御の各処理、すなわち、 (I′)マイクロ命令の取り出し (II′)解読 (III′)実行 (IV′)実行結果の格納 の各処理をパイプライン処理する。第5図はそのパイプ
ライン処理の概念図である。第5図において、処理1は
上記の(I′)に相当し、処理2は上記(II′)および
(III′)に相当し、処理3は上記(IV′)に相当す
る。
Also in the micro program control, pipeline control is performed similarly to the above-mentioned instruction execution control, and each process of the micro program control, that is, (I ') fetching of micro instruction (II') decoding (III ') execution (IV ') Pipeline each process of storing execution results. FIG. 5 is a conceptual diagram of the pipeline processing. In FIG. 5, treatment 1 corresponds to the above (I '), treatment 2 corresponds to the above (II') and (III '), and treatment 3 corresponds to the above (IV').

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

しかしながら、このような従来のパイプライン処理を
用いたデータ処理装置にあっては、処理3で命令が実行
されているとき、この命令に続く、次位の命令が処理2
で解読やアドレス計算処理を受けているとともに、次次
位の命令が処理1で取り込まれる構成となっていたた
め、例えば条件判定を伴う条件分岐命令(以下、単に分
岐命令という)が処理3で実行中の場合、この実行結果
(すなわち、判定結果)が得られるまでは、次位の命令
を処理するか(非分岐側処理)、あるいは分岐先の別の
命令を処理するか(分岐側処理)は確定していない。し
たがって、分岐命令が処理1から処理3まで移って結果
が出るまでは、次位および次次位の命令を処理すること
は無意味であり、通常、ノーオペレーション命令(NO
P)を分岐命令に続く次位、次次位の命令としている。
However, in such a conventional data processing device using pipeline processing, when an instruction is being executed in the process 3, the next instruction following this instruction is processed 2
In addition to the decoding and address calculation processing performed in step 1, the next-higher-order instruction is fetched in step 1. Therefore, for example, a conditional branch instruction with condition determination (hereinafter simply referred to as a branch instruction) is executed in step 3. If it is medium, whether to process the next instruction (non-branch side processing) or another branch destination instruction (branch side processing) until the execution result (that is, the determination result) is obtained. Has not been finalized. Therefore, it is meaningless to process the next and next instructions until the branch instruction moves from the processing 1 to the processing 3 to obtain a result, and normally, the no-operation instruction (NO
P) is the next and subsequent instruction following the branch instruction.

第6図は分岐命令の後にNOPを入れた従来のパイプラ
イン処理の概念図である。同図において、分岐命令Aの
条件判定は処理3の実行処理で行われ、条件非成立なら
ば、再び処理1でAを取り込み処理1〜3までを繰返し
て続行する。そして、条件が成立すると、マイクロ命令
のアドレスを切り換え、所定の分岐先命令を処理1で取
り込み、以降はこの分岐側処理を続行する。このよう
に、分岐命令Aの後には処理段階数に応じた複数のNOP
を介在させなければならないので、分岐命令の処理中は
実質的にパイプライン処理の効果が失われ、上述した逐
次処理とほぼ同程度の処理速度に低下するといった問題
点があった。
FIG. 6 is a conceptual diagram of conventional pipeline processing in which a NOP is inserted after a branch instruction. In the figure, the condition judgment of the branch instruction A is performed in the execution process of the process 3, and if the condition is not satisfied, the A is fetched again in the process 1 and the processes 1 to 3 are repeated and continued. Then, when the condition is satisfied, the address of the micro instruction is switched, a predetermined branch destination instruction is fetched in the process 1, and thereafter the branch side process is continued. Thus, after the branch instruction A, a plurality of NOPs corresponding to the number of processing stages are
Therefore, there is a problem that the effect of the pipeline processing is substantially lost during the processing of the branch instruction, and the processing speed is reduced to almost the same level as the above-mentioned sequential processing.

本発明はこのような問題点に鑑みてなされたもので、
条件分岐命令の処理中であっても、パイプライン処理が
有効に行われ、処理速度の低下しないデータ処理装置を
提供することを目的としている。
The present invention has been made in view of such problems,
An object of the present invention is to provide a data processing device in which pipeline processing is effectively performed even during processing of a conditional branch instruction and the processing speed does not decrease.

〔問題点を解決するための手段〕[Means for solving problems]

本発明では、上記目的を達成するために、条件分岐命
令および該条件分岐命令の分岐先命令を含む複数のマイ
クロ命令を格納し、アドレス指定により各マイクロ命令
が取り出される格納手段と、該格納手段から一つのマイ
クロ命令が取り出されると、そのマイクロ命令に続く次
のマイクロ命令を指定する順次アドレスを発生する第1
のアドレス発生手段と、取り出されたマイクロ命令の命
令種別を解読する解読手段と、解読された命令種別が条
件分岐命令のとき、条件の成立、非成立を判定する処理
を実行する実行手段と、条件分岐命令の分岐先命令のア
ドレスを発生する第2のアドレス発生手段と、条件の非
成立時には第1のアドレス発生手段を選択する一方、条
件の成立時には第2のアドレス発生手段を選択して格納
手段にマイクロ命令取り出しのためのアドレスを与える
選択手段と、を備え、解読された命令種別が条件分岐命
令のとき、分岐条件の成立、非成立が判定されるまでの
間、第1のアドレス発生手段から発生される順次アドレ
スに基づいたマイクロ命令が実行され、分岐条件が非成
立の場合は、当該順次アドレスに基づいたマイクロ命令
の処理が続行されるとともに、分岐条件が成立した場合
には、前記第2のアドレス発生手段から発生される、分
岐先命令のアドレスに基づいたマイクロ命令の処理がな
されることを特徴とする。
In order to achieve the above object, the present invention stores a plurality of microinstructions including a conditional branch instruction and a branch destination instruction of the conditional branch instruction, and stores each microinstruction by addressing, and the storing means. When a microinstruction is fetched from the first microinstruction, a first sequential address that specifies the next microinstruction following the microinstruction is generated.
Address generating means, decoding means for decoding the instruction type of the fetched microinstruction, and execution means for executing processing to determine whether or not the condition is satisfied when the decoded instruction type is a conditional branch instruction. The second address generating means for generating the address of the branch destination instruction of the conditional branch instruction and the first address generating means when the condition is not satisfied are selected, while the second address generating means is selected when the condition is satisfied. Selecting means for giving an address for fetching a microinstruction to the storing means, and when the decoded instruction type is a conditional branch instruction, the first address until the branch condition is determined to be satisfied or not satisfied. If the microinstruction based on the sequential address generated by the generating means is executed and the branch condition is not satisfied, the processing of the microinstruction based on the sequential address is continued. Together, if the branch condition is satisfied, the generated from the second address generating means, characterized in that the processing of microinstructions based on the address of the branch destination instruction is carried out.

〔作 用〕 本発明では、条件分岐命令の条件判定の結果が得られ
るまでの間、第1のアドレス発生手段からの順次アドレ
スにより非分岐側のマイクロ命令が連続して取り出され
る。
[Operation] In the present invention, until the result of the conditional judgment of the conditional branch instruction is obtained, the micro-instructions on the non-branch side are continuously fetched by the sequential addresses from the first address generating means.

したがって、条件分岐命令に続く命令の処理に空白が
ないので、パイプライン処理が有効に機能し、処理速度
の低下を招くことはない。
Therefore, since there is no blank in the processing of the instruction following the conditional branch instruction, the pipeline processing works effectively and the processing speed is not reduced.

また、条件成立時には、第2のアドレス発生手段から
のアドレスにより分岐側のマイクロ命令(分岐先命令)
が取り込まれ、必要な分岐処理が行われる。
When the condition is satisfied, the branch side micro instruction (branch destination instruction) is generated by the address from the second address generating means.
Is taken in and the necessary branching processing is performed.

〔実施例〕〔Example〕

以下、本発明を図面に基づいて説明する。 Hereinafter, the present invention will be described with reference to the drawings.

第1、2図は、本発明に係るデータ処理装置の一実施
例を示す図であり、マイクロプログラム制御をパイプラ
イン処理するネクストアドレス型のデータ処理装置に適
用した例である。
1 and 2 are diagrams showing an embodiment of a data processing device according to the present invention, which is an example applied to a next address type data processing device for pipeline processing of microprogram control.

まず、構成を説明する。第1図において、データ処理
装置1は、パイプライン処理におけるマイクロ命令の取
り出し処理を行う命令取り出し処理部2と、パイプライ
ン処理における命令取り出し処理以外の処理を行う実行
処理部3と、を含み、 命令取り出し処理部2は、マイクロROM4、マイクロRO
MBNA5、選択手段6およびディレイ回路7を含んで構成
されている。
First, the configuration will be described. In FIG. 1, a data processing device 1 includes an instruction fetch processing unit 2 for fetching microinstructions in pipeline processing, and an execution processing unit 3 for performing processing other than instruction fetch processing in pipeline processing. The instruction fetch processing unit 2 includes a micro ROM 4 and a micro RO.
The MBNA 5, the selecting means 6 and the delay circuit 7 are included.

マイクロROM4は格納手段および第1のアドレス発生手
段としての機能を有し、ROM(Read Only Memory)ある
いはPLA(Programmable Logic Array)などにより構成
され、多数のマイクロ命令MOからなるマイクロプログラ
ムを内部に格納するとともに、これら多数のマイクロ命
令MOの各々に対応してネクストアドレス情報NAを格納し
ている。マイクロROM4には、アドレス情報ADが入力さ
れ、アドレス情報ADのアドレス指定により一つのマイク
ロ命令MOが取り出されるとともに、取り出されたマイク
ロ命令MOに対応するネクストアドレス情報NAが出力され
る。なお、多数のマイクロ命令MOは、いわゆる条件分岐
命令およびこの条件分岐命令の分岐先命令を含んでい
る。
The micro ROM 4 has a function as a storage unit and a first address generation unit, is configured by a ROM (Read Only Memory) or a PLA (Programmable Logic Array), and stores a micro program including many micro instructions MO inside. In addition, the next address information NA is stored corresponding to each of these many micro instructions MO. Address information AD is input to the micro ROM 4, one micro instruction MO is fetched by addressing the address information AD, and next address information NA corresponding to the fetched micro instruction MO is output. The many micro instructions MO include so-called conditional branch instructions and branch destination instructions of these conditional branch instructions.

ここで、条件分岐命令は、所定の条件が成立するか否
かによって以降の分岐処理を決定する命令であり、例え
ば、掛算命令(MUL命令)や割算命令(DIV命令)あるい
はロードマルチレジスタ命令(LDM命令)などに代表さ
れる。例えば、A=n×mのMUL命令は、A=n+Aの
加算を一つのループとしてこれをmループ繰り返し、最
終的にA=n×mが得られたとき、条件成立として分岐
側処理を行う命令である。したがって、条件が非成立の
A≠n×mの間では、非分岐側処理を実行してA=n+
Aの加算を繰り返すから、一つのMUL命令では分岐側処
理が1回発生するのに対し、非分岐側処理はm回発生す
る。すなわち、この非分岐側処理を途切れることなく連
続して処理が可能であれば、パイプライン処理の効果を
有効に発揮することができる。
Here, the conditional branch instruction is an instruction that determines the subsequent branch processing depending on whether or not a predetermined condition is satisfied. For example, a multiplication instruction (MUL instruction), a division instruction (DIV instruction), or a load multi-register instruction. (LDM instruction) and so on. For example, the MUL instruction of A = n × m repeats this addition for m loops by adding A = n + A as one loop, and when A = n × m is finally obtained, the branch side processing is performed as the condition is satisfied. It is an instruction. Therefore, when A ≠ n × m where the condition is not satisfied, the non-branching side process is executed and A = n +
Since the addition of A is repeated, the branch side processing occurs once in one MUL instruction, whereas the non-branch side processing occurs m times. That is, if the non-branching side processing can be continuously processed without interruption, the effect of the pipeline processing can be effectively exhibited.

上述のネクストアドレス情報NAは、対応するマイクロ
命令MOの次に処理すべき非分岐側処理のマイクロ命令MO
の格納アドレスを示し、このネクストアドレス情報NA
は、後述の判定結果信号SJが非分岐側のとき、アドレス
情報ADとなってマイクロROM4に入力される。
The above-mentioned next address information NA is the microinstruction MO of the non-branch side processing to be processed next to the corresponding microinstruction MO.
Indicates the storage address of this, and the next address information NA
When the determination result signal S J described later is on the non-branching side, the address information AD is input to the micro ROM 4.

マイクロROMBNA5は、第2のアドレス発生手段として
の機能を有し、ROMあるいはPLAにより構成され、上記条
件分岐命令の分岐先命令を指定する分岐先アドレス情報
BNAが内部に格納されている。マイクロROMBNA5にはn処
理サイクル前のディレイアドレス情報AD-nが入力されて
おり、ディレイアドレス情報AD-nのアドレス指定に従っ
て分岐先アドレス情報BNAが出力される。
The micro ROMBNA5 has a function as a second address generating means, is constituted by a ROM or a PLA, and is branch destination address information for designating a branch destination instruction of the conditional branch instruction.
BNA is stored internally. The delay address information AD -n before n processing cycles is input to the micro ROM BNA5, and the branch destination address information BNA is output according to the address designation of the delay address information AD -n .

選択手段6は、上記第1のアドレス発生手段としての
マイクロROM4からのネクストアドレス情報NAが入力され
る入力端子6aと、第2のアドレス発生手段としてのマイ
クロROMBNA5からの分岐先アドレス情報BNAが入力される
入力端子6bと、後述の判定結果信号SJに従って分岐非成
立時に入力端子6aを選択し、また、分岐成立時に入力端
子6bを選択して、ネクストアドレス情報NAあるいは分岐
先アドレス情報BNAの何れか一方を取り出しアドレス情
報ADとして出力する出力端子6cと、を有している。
The selecting means 6 receives the input terminal 6a to which the next address information NA from the micro ROM 4 as the first address generating means is input, and the branch destination address information BNA from the micro ROM BNA5 as the second address generating means. The selected input terminal 6b and the branch destination address information BNA are selected by selecting the input terminal 6a when the branch is not established according to the determination result signal S J described later, and when the branch is established. The output terminal 6c outputs either one as the fetched address information AD.

ディレイ回路7は、例えばn段のラッチ回路からな
り、アドレス情報ADをn処理サイクルの間保持し、ディ
レイアドレス情報AD-nとして出力する。なお、ラッチの
段数nは1段であってもよい。
The delay circuit 7 comprises, for example, n stages of latch circuits, holds the address information AD for n processing cycles, and outputs it as delay address information AD -n . The number n of latch stages may be one.

実行処理部3は、解読手段および実行手段としての機
能を有し、命令取り出し処理部2で取り出されたマイク
ロ命令MOの命令種別を解読する処理、アドレスを計算す
る処理、オペランドを取り出す処理、命令を実行する処
理などを処理サイクル毎に並行して行う。また、実行処
理部3は、マイクロ命令MOの命令種別が条件分岐命令の
とき、与えられた条件の成立、非成立を判定する実行処
理を行い、その判定結果信号SJを出力する。なお、実行
処理部3には、図示しない複数の#φ〜#mまでのレジ
スタおよび少なくとも1つのカウンタが備えられている
とともに、データバスを介してメモリなどのI/Oが接続
され、命令の実行処理に従ってメモリおよびレジスタ間
のデータの授受や、カウンタ値の操作等が行われる。
The execution processing unit 3 has a function as a decoding unit and an execution unit, and decodes the instruction type of the microinstruction MO fetched by the instruction fetch processing unit 2, calculates an address, fetches an operand, and executes an instruction. And the like are executed in parallel for each processing cycle. Further, when the instruction type of the micro instruction MO is a conditional branch instruction, the execution processing unit 3 performs an execution process for determining whether or not a given condition is satisfied, and outputs the determination result signal S J. The execution processing unit 3 is provided with a plurality of registers # φ to #m and at least one counter (not shown), and is connected with an I / O such as a memory via a data bus to execute instructions. Data is exchanged between the memory and the register, and the counter value is manipulated according to the execution process.

次に、作用を説明する。 Next, the operation will be described.

第1図において、命令取り出し処理部2におけるマイ
クロ命令MOの取り出し動作は以下のようにして行われ
る。すなわち、所定のマイクロ命令MOが取り出される
と、このマイクロ命令MOに対応したネクストアドレス情
報NAが出力され、ネクストアドレス情報NAは選択手段6
の入力端子6aに加えられる。このとき、判定結果信号SJ
が非分岐側を示していれば、出力端子6cにはネクストア
ドレス情報NAがアドレス情報ADとして出力されている。
したがって、マイクロ命令MOの取り出し処理(以下、処
理1)においては、判定結果信号SJが非分岐側を示して
いる間、ネクストアドレス情報NAがアドレス情報ADとし
て再びマイクロROM4に加えられるといったループを繰り
返し、いわゆるネクストアドレス型のマイクロ命令取り
出し処理が行われて、処理サイクル毎にマイクロ命令MO
が連続して取り出されていく。
In FIG. 1, the fetch operation of the micro instruction MO in the instruction fetch processing section 2 is performed as follows. That is, when a predetermined microinstruction MO is taken out, the next address information NA corresponding to this microinstruction MO is output, and the next address information NA is selected by the selecting means 6.
Input terminal 6a. At this time, the judgment result signal S J
Indicates the non-branching side, the next address information NA is output to the output terminal 6c as the address information AD.
Therefore, in the fetch processing of the micro instruction MO (hereinafter, processing 1), while the determination result signal S J indicates the non-branch side, the next address information NA is added to the micro ROM 4 as the address information AD again. Repeatedly, the so-called next address type micro instruction fetch processing is performed, and the micro instruction MO is processed every processing cycle.
Are taken out continuously.

一方、実行処理部3における分岐条件の判定処理(以
下、処理3)の結果、分岐が成立したとき、この分岐成
立を示す判定結果情報SJに従って選択手段6は分岐先ア
ドレス情報BNAを選択し、この分岐先アドレス情報BNAを
アドレス情報ADとして出力する。したがって、マイクロ
ROM4からは分岐先アドレス情報BNAで指定された分岐先
命令が取り出され、実行処理部3は取り出された分岐先
命令に従って必要な処理を実行する。
On the other hand, when a branch condition is determined as a result of the branch condition determination process (hereinafter referred to as process 3) in the execution processing unit 3, the selection unit 6 selects the branch destination address information BNA according to the determination result information S J indicating that the branch condition is satisfied. , And outputs this branch destination address information BNA as address information AD. Therefore, micro
The branch destination instruction specified by the branch destination address information BNA is fetched from the ROM 4, and the execution processing unit 3 executes the necessary processing according to the fetched branch destination instruction.

第2図は例えばLDM命令処理時のパイプライン処理の
概念図である。第2図において、処理1はマイクロ命令
の取り出し処理を、処理2はマイクロ命令の解読処理お
よび一部の実行処理を、処理3はマイクロ命令の例えば
条件判定の実行処理をそれぞれ表し、また、四角枠内に
アルファベットA、B、XはLDM命令に相当するマイク
ロ命令を表している。例えば、Aはカウンタに初期値
(例えば、3)をセットする命令、Bはカウンタ値に対
応した番号のレジスタにメモリからのデータを格納する
とともに、カウンタをデクリメントする非分岐側命令、
Xは条件成立時にLDM命令の処理を終了する分岐先命令
である。
FIG. 2 is a conceptual diagram of pipeline processing during LDM instruction processing, for example. In FIG. 2, a process 1 represents a microinstruction fetching process, a process 2 represents a microinstruction decoding process and a partial execution process, a process 3 represents a microinstruction execution process such as condition determination, and a square box. The letters A, B, and X in the frame represent microinstructions corresponding to LDM instructions. For example, A is an instruction to set an initial value (for example, 3) to the counter, B is a non-branch side instruction to store the data from the memory in the register of the number corresponding to the counter value and to decrement the counter,
X is a branch target instruction that ends the processing of the LDM instruction when the condition is satisfied.

処理1において、実行処理部3からの判定結果信号SJ
が非分岐側を示しているので、ネクストアドレス情報NA
で指定されたマイクロ命令MOが処理サイクル毎に連続し
て取り込まれている。すなわち、Aの命令とこのAの命
令の右側に連続する各ループ毎のBの命令である。Aの
命令は、処理2において、カウンタ値を初期値(例えば
3)にセットする。Bの命令は、第1のループの処理2
において、メモリからデータを読み出すとともに、カウ
ンタ値をデクリメントし、処理部3において、読み出し
たデータをカウンタ値に対応する#2レジスタに格納す
る。そして、処理3においては、カウンタ値が“0"に到
達したか否かの判定を合わせて行い、到達の場合には判
定結果信号SJを分岐成立を示す信号として出力し、一
方、到達していない場合には、判定結果信号SJを非成立
を示す信号として出力する。すなわち、第1のループの
処理3においては、カウンタ値がまだ2であるから、分
岐が成立せず判定結果信号SJは非分岐を示す信号として
出力される。これにより、マイクロROM4からはネクスト
アドレス情報NAで指定された非分岐側のBの命令が取り
出され、第2のループが行われる。そして、第2のルー
プの処理2、3においても、第1のループと同様にカウ
ンタ値のデクリメント、データの格納および条件判定が
行われ、このようなループはカウンタ値が“0"に到達す
るまで繰り返して行われる。その結果、カウンタ値が
“0"となった時点で#φ〜#2のレジスタの全てにメモ
リからのデータが格納され、LDM命令の処理が完了する
こととなる。すなわち、第3のループの処理3でカウン
タ値が“0"となるので、この処理3で分岐のための条件
が成立し、分岐を示す判定結果信号SJが出力される。
In process 1, the determination result signal S J from the execution processing unit 3
Indicates the non-branching side, so the next address information NA
The micro-instruction MO specified by is continuously fetched every processing cycle. That is, it is the instruction of A and the instruction of B of each loop continuous to the right of this instruction of A. The instruction A sets the counter value to the initial value (for example, 3) in the process 2. The instruction of B is the processing 2 of the first loop.
In step 3, the data is read from the memory, the counter value is decremented, and the processing unit 3 stores the read data in the # 2 register corresponding to the counter value. Then, in the process 3, it is also determined whether or not the counter value has reached “0”, and when it has reached, the determination result signal S J is output as a signal indicating that the branch has been taken. If not, the determination result signal S J is output as a signal indicating non-establishment. That is, in the process 3 of the first loop, since the counter value is still 2, the branch is not taken and the determination result signal S J is output as a signal indicating non-branch. As a result, the instruction of B on the non-branch side specified by the next address information NA is fetched from the micro ROM 4, and the second loop is performed. Then, also in the processes 2 and 3 of the second loop, the counter value is decremented, the data is stored, and the condition is determined in the same manner as in the first loop, and in such a loop, the counter value reaches "0". Is repeated until. As a result, when the counter value becomes “0”, the data from the memory is stored in all the registers of # φ to # 2, and the processing of the LDM instruction is completed. That is, since the counter value becomes "0" in the process 3 of the third loop, the condition for the branch is satisfied in the process 3 and the determination result signal S J indicating the branch is output.

選択手段6はこの判定結果信号SJに従って分岐先アド
レス情報BNA側の入力端子6bを選択し、BNAをアドレス情
報ADとしてマイクロROM4に加え、マイクロROM4からは、
BNAで指定された分岐先の命令(Xの命令)が取り出さ
れる。そして、以降の処理は、このXの命令について行
われ、例えば、処理が中止されたり、あるいは他の処理
が開始される。なお、第3のループの処理3で分岐のた
めの条件が成立したとき、並行して行われている第4の
ループの処理2はキャンセルされ、無効となる。
The selecting means 6 selects the input terminal 6b on the side of the branch destination address information BNA in accordance with this determination result signal S J , adds the BNA as address information AD to the micro ROM 4, and from the micro ROM 4,
The branch destination instruction (X instruction) specified by the BNA is fetched. Then, the subsequent processing is performed with respect to this X instruction, and for example, the processing is stopped or another processing is started. When the condition for branching is satisfied in the process 3 of the third loop, the process 2 of the fourth loop which is being executed in parallel is canceled and becomes invalid.

このように本実施例では、処理3において、分岐条件
の成立、非成立の判定を行うとともに、この判定の結果
を示す判定結果信号SJを選択手段6に出力し、分岐非成
立時、ネクストアドレス情報NAを選択してマイクロROM4
に加える一方、分岐成立時、分岐先アドレス情報BNAを
選択してマイクロROM4に加えている。したがって、分岐
非成立時には、処理1におけるマイクロ命令MOの取り込
み動作が途切れることなく連続して行われ、パイプライ
ン処理の効果を有効に発揮して高速化を図ることができ
る。なお、分岐成立時には、NAからBNAへの切り換えに
よって1処理サイクル分の空白が生じるが、分岐成立は
複数ループのうちの一度であるから、非分岐時の高速化
効果に対して1処理サイクル分の空白は影響が小さく、
問題とならない。
As described above, in the present embodiment, in process 3, it is determined whether or not the branch condition is satisfied, and at the same time, the determination result signal S J indicating the result of this determination is output to the selecting means 6, and when the branch is not satisfied, the next condition is determined. Select address information NA and select micro ROM 4
On the other hand, when the branch is taken, the branch destination address information BNA is selected and added to the micro ROM 4. Therefore, when the branch is not taken, the fetch operation of the micro instruction MO in the process 1 is continuously performed without interruption, and the effect of the pipeline processing can be effectively exerted to increase the speed. When a branch is taken, switching from NA to BNA leaves a blank for one processing cycle. However, since the branch is taken only once in multiple loops, one processing cycle is required for the speed-up effect when not branching. Blanks have little effect,
It doesn't matter.

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

本発明によれば、条件分岐命令の処理中であっても、
パイプライン処理を有効に行うことができ、処理速度の
低下しないデータ処理装置を実現することができる。
According to the present invention, even during processing of a conditional branch instruction,
A pipeline processing can be effectively performed, and a data processing device in which the processing speed does not decrease can be realized.

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

第1、2図は本発明に係るデータ処理装置の一実施例を
示す図であり、 第1図はその要部のブロック図、 第2図はそのパイプライン処理の概念図、 第3〜6図は従来のデータ処理装置を説明する図であ
り、 第3図はその逐次処理を示す概念図、 第4図はその命令実行制御におけるパイプライン処理を
示す概念図、 第5図はそのマイクロプログラム制御におけるパイプラ
イン処理を示す概念図、 第6図はその問題点を説明するための概念図である。 3……実行処理部(解読手段、実行手段)、 4……マイクロROM(格納手段、第1のアドレス発生手
段)、 5……マイクロROMBNA(第2のアドレス発生手段)、 6……選択手段。
1 and 2 are diagrams showing an embodiment of a data processing apparatus according to the present invention, FIG. 1 is a block diagram of the main part thereof, FIG. 2 is a conceptual diagram of its pipeline processing, and 3 to 6 FIG. 3 is a diagram for explaining a conventional data processing device, FIG. 3 is a conceptual diagram showing its sequential processing, FIG. 4 is a conceptual diagram showing pipeline processing in its instruction execution control, and FIG. 5 is its microprogram. FIG. 6 is a conceptual diagram showing pipeline processing in control, and FIG. 6 is a conceptual diagram for explaining the problem. 3 ... Execution processing unit (decoding means, execution means), 4 ... Micro ROM (storage means, first address generation means), 5 ... Micro ROM BNA (second address generation means), 6 ... selection means .

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】条件分岐命令および該条件分岐命令の分岐
先命令を含む複数のマイクロ命令を格納し、アドレス指
定により各マイクロ命令が取り出される格納手段と、 該格納手段から一つのマイクロ命令が取り出されると、
そのマイクロ命令に続く次のマイクロ命令を指定する順
次アドレスを発生する第1のアドレス発生手段と、 取り出されたマイクロ命令の命令種別を解読する解読手
段と、 解読された命令種別が条件分岐命令のとき、条件の成
立、非成立を判定する処理を実行する実行手段と、 条件分岐命令の分岐先命令のアドレスを発生する第2の
アドレス発生手段と、 条件の非成立時には第1のアドレス発生手段を選択する
一方、条件の成立時には第2のアドレス発生手段を選択
して格納手段にマイクロ命令取り出しのためのアドレス
を与える選択手段と、を備え、 解読された命令種別が条件分岐命令のとき、分岐条件の
成立、非成立が判定されるまでの間、第1のアドレス発
生手段から発生される順次アドレスに基づいたマイクロ
命令が実行され、分岐条件が非成立の場合は、当該順次
アドレスに基づいたマイクロ命令の処理が続行されると
ともに、分岐条件が成立した場合には、前記第2のアド
レス発生手段から発生される、分岐先命令のアドレスに
基づいたマイクロ命令の処理がなされることを特徴とす
るデータ処理装置。
1. A storage means for storing a plurality of microinstructions including a conditional branch instruction and a branch destination instruction of the conditional branch instruction, and each microinstruction is fetched by addressing, and one microinstruction is fetched from the storage means. When
First address generating means for generating a sequential address designating the next microinstruction following the microinstruction, decoding means for decoding the instruction type of the fetched microinstruction, and the decoded instruction type is a conditional branch instruction. At this time, executing means for executing processing for judging whether the condition is satisfied or not, second address generating means for generating an address of a branch destination instruction of the conditional branch instruction, and first address generating means when the condition is not satisfied. On the other hand, when the condition is satisfied, the second address generating unit is selected and the storing unit is provided with an address for fetching the microinstruction, and when the decoded instruction type is a conditional branch instruction, Until the branch condition is determined to be satisfied or not satisfied, the microinstruction based on the sequential address generated by the first address generating means is executed, and When the condition is not satisfied, the processing of the micro instruction based on the sequential address is continued, and when the branch condition is satisfied, the address of the branch destination instruction generated from the second address generating means. A data processing device characterized in that processing of a microinstruction based on is performed.
JP62333720A 1987-12-29 1987-12-29 Data processing device Expired - Lifetime JPH0812599B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP62333720A JPH0812599B2 (en) 1987-12-29 1987-12-29 Data processing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP62333720A JPH0812599B2 (en) 1987-12-29 1987-12-29 Data processing device

Publications (2)

Publication Number Publication Date
JPH01175633A JPH01175633A (en) 1989-07-12
JPH0812599B2 true JPH0812599B2 (en) 1996-02-07

Family

ID=18269204

Family Applications (1)

Application Number Title Priority Date Filing Date
JP62333720A Expired - Lifetime JPH0812599B2 (en) 1987-12-29 1987-12-29 Data processing device

Country Status (1)

Country Link
JP (1) JPH0812599B2 (en)

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5423343A (en) * 1977-07-22 1979-02-21 Nec Corp Microprogram controller

Also Published As

Publication number Publication date
JPH01175633A (en) 1989-07-12

Similar Documents

Publication Publication Date Title
JP2848606B2 (en) Method and apparatus for modifying microinstructions using a macroinstruction pipeline
US4179731A (en) Microprogrammed control system
US4539635A (en) Pipelined digital processor arranged for conditional operation
JPH03218523A (en) Data processor
US4954947A (en) Instruction processor for processing branch instruction at high speed
JP3578883B2 (en) Data processing device
US5349671A (en) Microprocessor system generating instruction fetch addresses at high speed
US4598358A (en) Pipelined digital signal processor using a common data and control bus
US5185870A (en) System to determine if modification of first macroinstruction to execute in fewer clock cycles
US4812970A (en) Microprogram control system
EP0162929B1 (en) Method of controlling branching
JPH06332699A (en) Program processing method and computer system
US5479620A (en) Control unit modifying micro instructions for one cycle execution
JPH0812599B2 (en) Data processing device
JPH0218729B2 (en)
JP2583506B2 (en) Data processing device
JP2825315B2 (en) Information processing device
JPS6389930A (en) microprogram controller
JPH06131180A (en) Instruction processing system and instruction processor
JPS59160239A (en) information processing equipment
EP0862112A2 (en) Data processing system having an instruction pipeline
JPS6116334A (en) Data processor
JPS6160129A (en) Microprogram controller
KR100357175B1 (en) Digital signal processor
JPS6028014B2 (en) microprocessor