JPH02254541A - Control system for conditional branch instruction - Google Patents
Control system for conditional branch instructionInfo
- Publication number
- JPH02254541A JPH02254541A JP7715089A JP7715089A JPH02254541A JP H02254541 A JPH02254541 A JP H02254541A JP 7715089 A JP7715089 A JP 7715089A JP 7715089 A JP7715089 A JP 7715089A JP H02254541 A JPH02254541 A JP H02254541A
- Authority
- JP
- Japan
- Prior art keywords
- instruction
- address
- branch
- register
- condition
- 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.)
- Granted
Links
Landscapes
- Advance Control (AREA)
Abstract
Description
【発明の詳細な説明】
[e&要]
アドレス計n機構を備えた計算機の条件分岐命令の制御
方式に関し、
条件分岐成立時の実行サイクル数を最小限に抑えて高速
化することを目的とし、
条件分岐命令の解読時に計算された分岐先アドレスを、
条件判定に必要なオペランドアドレスを格納する他のレ
ジスタ群の中の1つを使用することで共用し、分岐条件
の判定と分岐条件成立時の分岐先アドレスの命令アドレ
スへのコピーを同一サイクルで行なうように構成する。[Detailed description of the invention] [e&required] Regarding a control method for conditional branch instructions in a computer equipped with an address counter n mechanism, the purpose of this invention is to minimize the number of execution cycles when a conditional branch is established and speed it up. The branch destination address calculated when decoding the conditional branch instruction is
By using one of the other registers that stores the operand address necessary for condition judgment, it is shared, and the judgment of the branch condition and the copying of the branch destination address to the instruction address when the branch condition is met can be performed in the same cycle. Configure it to do so.
[産業上の利用分野コ
本発明は、アドレス計算機構を備えた計算機における条
件分岐命令の制御方式に関する。[Industrial Field of Application] The present invention relates to a control system for conditional branch instructions in a computer equipped with an address calculation mechanism.
近年、コンピュータシステムの高速化の要求に伴い、命
令の解釈・実行の方法としてパイプライン制御が一般的
になっているが、パイプの流れを乱す条件分岐命令が高
速化のネックとなっており、実行サイクル数を可能な限
り低減することが望まれる。In recent years, with the demand for faster computer systems, pipeline control has become common as a method for interpreting and executing instructions, but conditional branch instructions that disrupt the flow of pipes have become a bottleneck to speeding up. It is desirable to reduce the number of execution cycles as much as possible.
[従来の技術]
近年、コンピュータシステムの高速化の要求に対応して
行なわれているパイプライン制御とは、命令の解釈・実
行をいくつかのステージに分け、各ステージ機構は、あ
る命令の実行後、この命令の全ステージでの実行終了を
待たずに、次の命令を当該ステージで実行する方式であ
るが、条件分岐命令、即ち、命令の実行結果によって分
岐先が変わる命令、例えば命令中で示されるアドレスの
メモリ内容によって分岐・非分岐が確定する分岐命令に
ついては、条件分岐命令が終了しなければ次に解釈・実
行すべき命令が確定しないため、その間、パイプライン
制御が止ってしまい、高速化のネックとなっている。[Prior Art] Pipeline control, which has been implemented in recent years in response to the demand for faster computer systems, divides the interpretation and execution of instructions into several stages, and each stage mechanism handles the execution of a certain instruction. After that, the next instruction is executed at that stage without waiting for the completion of execution at all stages of this instruction. Regarding branch instructions where branching or non-branching is determined depending on the memory contents of the address indicated by , which is a bottleneck in speeding up the process.
第5図に従来方式の構成図を示す。FIG. 5 shows a configuration diagram of the conventional system.
第5図において、1はメモリ6からフェッチした命令を
バッファリングする命令バッファ、2はフェッチされた
命令を解釈する命令デコーダ、3は汎用レジスタや実行
中の命令アドレスからオペランドや分岐先アドレスを計
算するアドレス計算部である。4はアドレスレジスタで
おり、命令用アドレスレジスタ4−1、第1オペランド
用アドレスレジスタ4−2、第2オペランド用アドレス
レジスタ4−3、及び命令分岐用アドレスレジスタ4−
4の4種を備える。In Figure 5, 1 is an instruction buffer that buffers instructions fetched from memory 6, 2 is an instruction decoder that interprets the fetched instructions, and 3 is a computer that calculates operands and branch destination addresses from general-purpose registers and the address of the instruction being executed. This is the address calculation section. 4 is an address register, which includes an instruction address register 4-1, a first operand address register 4-2, a second operand address register 4-3, and an instruction branch address register 4-1.
Equipped with 4 types of 4.
また、5は命令実行部でおり、命令デコーダ2のデコー
ド結果に従ってオペランドリードヤライト、各種演算を
行なう。更に6は主記憶としてのメモリである。Further, 5 is an instruction execution unit, which performs operand read/write and various operations according to the decoding result of the instruction decoder 2. Furthermore, 6 is a memory as a main memory.
次に第6図のタイミング説明図を参照して動作を説明す
る。Next, the operation will be explained with reference to the timing explanatory diagram of FIG.
命令バッファ1はメモリ6から命令アドレスレジスタ4
−1によってアドレスされる命令をフェッチしバッファ
リングしている。命令デコーダ2はデコード結果が条件
分岐命令であった場合、アドレス計算部3に条件判定に
必要なオペランドのアドレス計算を指示する。アドレス
計算部3で計算されたオペランドアドレスは第1、第2
オペランドアドレスレジスタ4−2.4−3のいずれか
に一方にセットされる。Instruction buffer 1 is transferred from memory 6 to instruction address register 4.
The instruction addressed by -1 is fetched and buffered. If the decoded result is a conditional branch instruction, the instruction decoder 2 instructs the address calculation unit 3 to calculate the address of an operand necessary for condition determination. The operand addresses calculated by the address calculation unit 3 are the first and second operand addresses.
One of the operand address registers 4-2 and 4-3 is set.
次に命令デコーダ2は分岐条件が成立した場合にフェッ
チすべき命令のアドレス、即ち、分岐先アドレスの計算
をアドレス計算部”3に指示し、計算結果は専用の命令
分岐先アドレスレジスタ4−4にセットされる。Next, the instruction decoder 2 instructs the address calculation unit "3 to calculate the address of the instruction to be fetched when the branch condition is met, that is, the branch destination address, and the calculation result is stored in the dedicated instruction branch destination address register 4-4. is set to
以上のアドレス計算が終了すると、分岐命令が成立しな
いことを仮定して命令アドレスレジスタ4−1をカウン
トアツプし、命令バッファ1に対しカウントアツプされ
た命令アドレスで指定される次の命令をフェッチする。When the above address calculation is completed, assuming that the branch instruction is not taken, the instruction address register 4-1 is counted up, and the next instruction specified by the counted up instruction address is fetched from the instruction buffer 1. .
一方、命令実行部5は分岐条件の判定に必要なオペラン
ドアドレスが確定した時点でメモリ6上のオペランドを
リードし、次に分岐条件の成立の有無を判定する。On the other hand, the instruction execution unit 5 reads the operand on the memory 6 when the operand address necessary for determining the branch condition is determined, and then determines whether the branch condition is met.
分岐条件が成立していなかった場合、そのとき命令バッ
ファ1にバッファリングされている次の命令のデコード
以降の動作が実行される。If the branch condition is not satisfied, the operations after decoding the next instruction buffered in the instruction buffer 1 at that time are executed.
逆に分岐条件が成立していた場合には、命令分岐先アド
レスレジスタ4−4の値を命令アドレスレジスタ4−1
に格納し、分岐先命令のフェッチから再実行する。Conversely, if the branch condition is met, the value of the instruction branch destination address register 4-4 is transferred to the instruction address register 4-1.
and re-execute from fetching the branch destination instruction.
[課題を解決するための手段]
しかしながら、このような従来の条件分岐命令の制御方
式にあっては、分岐先のアドレス計算結果を格納する専
用レジスタ4−4を必要とし、また分岐条件の成立を判
定した場合に、命令分岐先アドレスを格納した専用レジ
スタの値を命令アドレスレジスタに格納した後に、命令
フェッチから再実行するために実行サイクル数が多くな
る問題があった。[Means for Solving the Problems] However, in such a conventional conditional branch instruction control method, a dedicated register 4-4 is required to store the calculation result of the branch destination address, and When determining this, there is a problem in that the number of execution cycles increases because the instruction is fetched and re-executed after the value of the dedicated register storing the instruction branch destination address is stored in the instruction address register.
本発明は、このような従来の問題点に鑑みてなされたも
ので、条件分岐命令成立時の実行サイクル数を最小限に
抑えて高速化する条件分岐命令の制御方式を提供するこ
とを目的とする。The present invention has been made in view of these conventional problems, and an object of the present invention is to provide a control method for conditional branch instructions that minimizes the number of execution cycles when a conditional branch instruction is established and increases speed. do.
[課題を解決するための手段] 第1図は本発明の原理説明図である。[Means to solve the problem] FIG. 1 is a diagram explaining the principle of the present invention.
まず本発明は、条件分岐命令を解読した場合に、分岐条
件の判定に必要なオペランドアドレスAを計算してレジ
スタにセットし、次に分岐条件成立時にフェッチすべき
命令の分岐先アドレスBを計算してレジスタにセットし
、一方、分岐条件の判定に必要なオペランドアドレスA
が確定した時点でメモリ上のオペランドをリードして分
岐条件成立の有無を判定し、分岐条件不成立時にはカウ
ントアツプされた命令アドレスCにより次の命令をフェ
ッチし、逆に、分岐条件成立時には分岐先アドレスBを
命令アドレスとして命令をフェッチする条件分岐命令の
制御方式を対象とする。First, when a conditional branch instruction is decoded, the present invention calculates the operand address A necessary for determining the branch condition and sets it in a register, and then calculates the branch destination address B of the instruction to be fetched when the branch condition is met. and set it in the register, and on the other hand, the operand address A necessary for determining the branch condition.
When the branch condition is established, the operand on the memory is read to determine whether the branch condition is met, and if the branch condition is not met, the next instruction is fetched using the incremented instruction address C, and conversely, when the branch condition is met, the branch destination is The subject is a control method for a conditional branch instruction that fetches an instruction using address B as the instruction address.
このような条件分岐命令の制御方式について本発明にあ
っては、分岐先アドレスBを格納する1ノジスタを前記
オペランドアドレスAを格納する少なくとも2つのレジ
スタ4−2.4−3のいずれかと共用すると共に、分岐
条件の判定と分岐条件成立時の分岐先アドレスBの命令
アドレスCへのコピーを同一サイクルで行なうようにし
たものである。Regarding the control system for such conditional branch instructions, in the present invention, one register storing the branch destination address B is shared with one of at least two registers 4-2 and 4-3 storing the operand address A. In addition, the determination of the branch condition and the copying of the branch destination address B to the instruction address C when the branch condition is satisfied are performed in the same cycle.
[作用]
このような構成を備えた本発明による条件分岐命令の制
御方式にあっては、命令の分岐先アドレスを専用のレジ
スタに格納せずに空き状態におる少なくとも2つのオペ
ランドレジスタのいずれかに格納して共用し、かつ、分
岐条件の判定と分岐条件成立時のオペランドレジスタか
ら命令レジスタへの分岐先アドレスのコピーを同一サイ
クルで行なうようにしたため、ハード量の削減が可能で
あり、また専用レジスタを設けていたことによる従来の
専用レジスタから命令レジスタへの分岐先アドレスのセ
ットサイクルが不要となり、条件成立時の実行サイクル
数を最小限に抑えて高速化を図ることができる。[Operation] In the conditional branch instruction control method according to the present invention having such a configuration, the branch destination address of the instruction is not stored in a dedicated register, but is stored in one of at least two operand registers in an empty state. Since the branch condition is judged and the branch destination address is copied from the operand register to the instruction register in the same cycle, the amount of hardware can be reduced. The provision of a dedicated register eliminates the need for a cycle for setting a branch destination address from a conventional dedicated register to an instruction register, and it is possible to minimize the number of execution cycles when a condition is met and increase speed.
[実施例コ
第2図は本発明の一実施例を示した実施例構成図でおる
。Embodiment FIG. 2 is a block diagram of an embodiment of the present invention.
第2図において、1はメモリ6からフェッチした命令を
バッファリングする命令バッファ、2は命令バッファ1
にフェッチされた命令を解除する命令デコード部、3は
汎用レジスタや実行中の命令アドレスからオペランドや
分岐先アドレスを計算するアドレス計算部、4はアドレ
スレジスタであり、本発明にあっては命令用アドレスレ
ジスタ4−1、第1オペランド用アドレスレジスタ4−
2及び第2オペランド用アドレスレジスタ4−3の3種
を備え、従来のように分岐用アドレスレジスタは設けて
いない。5は命令実行部であり、命令デコード部2によ
る命令のデコード結果に従ってオペランドリードやライ
ト、各種の演算を行なう。更に、6は主記憶としてのメ
モリである。In FIG. 2, 1 is an instruction buffer for buffering instructions fetched from the memory 6, and 2 is an instruction buffer 1.
3 is an address calculation unit that calculates operands and branch destination addresses from general-purpose registers and the address of the instruction being executed; 4 is an address register; Address register 4-1, address register 4-1 for first operand
There are three types of address registers 4-3 for operands 2 and 4-3 for second operands, and no address register for branching is provided as in the conventional art. Reference numeral 5 denotes an instruction execution section, which performs operand reading, writing, and various operations according to the instruction decoding result by the instruction decoding section 2. Furthermore, 6 is a memory as a main memory.
このような第2図に示した本発明の実施例にあっては、
条件分岐命令に対し第3図の分岐命令動作タイミング説
明図に示す制御を行なう。In the embodiment of the present invention shown in FIG. 2,
Control shown in the branch instruction operation timing explanatory diagram of FIG. 3 is performed for the conditional branch instruction.
まず、命令バッファ1はメモリ6から命令アドレスレジ
スタ4−1によってアドレスされる命令をフェッチして
バッフ7リングしている。命令デコード部2はデコード
結果が条件分岐命令であった場合、アドレス計算部3に
対し条件判定に必要なメモリ6のオペランドのアドレス
計算を指示する。このアドレス計算部3によるオペラン
ドのアドレス計算結果は、第1及び第2オペランドアド
レスレジスタ4−2または4−3のいずれか一方にセッ
トされる。First, the instruction buffer 1 fetches the instruction addressed by the instruction address register 4-1 from the memory 6 and buffers it. If the decoded result is a conditional branch instruction, the instruction decoding unit 2 instructs the address calculation unit 3 to calculate the address of the operand in the memory 6 necessary for condition determination. The result of the operand address calculation by the address calculation unit 3 is set in either the first or second operand address register 4-2 or 4-3.
続いて、命令デコード部2はアドレス計算部3に対し分
岐条件が成立した場合にフェッチすべき命令のアドレス
の計算を指示する。このアドレス計算に得られた分岐先
アドレスは、第1及び第2のオペランドアドレスレジス
タ4−2または4−3のうち、この命令実行時において
オペランドアドレスとして使用されていない側のレジス
タにセットされる。Subsequently, the instruction decoding unit 2 instructs the address calculation unit 3 to calculate the address of the instruction to be fetched when the branch condition is satisfied. The branch destination address obtained by this address calculation is set in the register of the first and second operand address registers 4-2 or 4-3 that is not used as an operand address at the time of execution of this instruction. .
以上のアドレス計算を終了すると、分岐条件が成立しな
いことを仮定して命令アドレスレジスタ4−1はカウン
トアツプし、命令バッファ1はカウントアツプされた命
令アドレスによる次の命令をフェッチする。When the above address calculation is completed, the instruction address register 4-1 counts up assuming that the branch condition is not satisfied, and the instruction buffer 1 fetches the next instruction based on the counted up instruction address.
一方、命令実行部5はオペランドアドレスが確定した時
点でメモリ6上のオペランドをリードし、次に分岐条件
を判定する。分岐条件が成立していなかった場合、その
とき命令バッファ1にバッファリングされている命令の
デコード以降の動作が実行される。逆に分岐条件が成立
していた場合、この分岐条件の判定と同一サイクル中に
オペランドアドレスレジスタ4−2または4−3のいず
れか一方に格納されていた命令分岐先アドレスの値を命
令アドレスレジスタ4−1にコピーし、次に命令フェッ
チから再実行するようになる。On the other hand, the instruction execution unit 5 reads the operand on the memory 6 when the operand address is determined, and then determines the branch condition. If the branch condition is not satisfied, the operations after decoding the instruction buffered in the instruction buffer 1 at that time are executed. Conversely, if the branch condition is satisfied, the value of the instruction branch destination address stored in either operand address register 4-2 or 4-3 during the same cycle as the judgment of this branch condition is stored in the instruction address register. 4-1, and then re-executes from instruction fetch.
ここで、第3図に示す本発明による分岐命令の動作タイ
ミングと第6図に示した従来の動作タイミンクを対比し
てみると、(b)に示す分岐条件が成立しなかった場合
については実行サイクル数は同じであるが、(a)の分
岐条件が成立した場合については、第6図の従来例にあ
ってはオペランドフェッチ、分岐条件判定及び命令アド
レスセットの3サイクルを必要としたものが、第3図の
本発明にあってはオペランドフェッチ条件判定及び命令
アドレスセットの2サイクルで済ますことができる。Now, if we compare the operation timing of the branch instruction according to the present invention shown in FIG. 3 with the conventional operation timing shown in FIG. The number of cycles is the same, but when the branch condition in (a) is satisfied, the conventional example shown in Figure 6 requires three cycles for operand fetch, branch condition determination, and instruction address set. According to the present invention shown in FIG. 3, only two cycles are required for determining the operand fetch condition and setting the instruction address.
次に、第2図の実施例について条件分岐命令の1つであ
るTH命令(Test Half Word ) ヲ例
にとって具体的に説明する。Next, the embodiment of FIG. 2 will be specifically explained using a TH instruction (Test Half Word), which is one of the conditional branch instructions.
TH命令のフォーマット構成は第4図に示すように、O
Pコードが96となる4バイト長の命令である。このT
H命令において、2バイト目のベース部B(2ビツト)
によって指示されるレジスタ値及びインデックス部X(
2ビツト)によって指示されるレジスタ値及び2〜3バ
イト目となる命令中で直接、指示されるディスプレイス
メント(12ビツト)を加算して得られるアドレスのメ
モリ上のハーフワード(16ビツト)を参照する。The format structure of the TH instruction is as shown in Figure 4.
This is a 4-byte long instruction with a P code of 96. This T
In the H instruction, the base part B (2 bits) of the 2nd byte
The register value and index part X (
Refers to the halfword (16 bits) in the memory of the address obtained by adding the register value indicated by the 2nd and 3rd bytes (12 bits) and the displacement (12 bits) indicated directly in the instruction. do.
このメモリ上のハーフワードの値が分岐条件となってお
り、分岐条件を示す値がOならば、この命令が格納され
ているアドレスに命令中で直接指示されるアドレスAd
r(,8ビツト)を加算したアドレスに分岐する。The halfword value in this memory is the branch condition, and if the value indicating the branch condition is O, the address where this instruction is stored is the address Ad directly specified in the instruction.
Branch to the address to which r (, 8 bits) is added.
逆に分岐条件の値がO以外であったならば、この命令が
格納されているアドレスに命令長4を加算したアドレス
に加算されている値が次の命令となる。Conversely, if the value of the branch condition is other than O, the value added to the address where this instruction is stored plus the instruction length 4 becomes the next instruction.
このようなTH命令について、第2図による制御を具体
的に説明すると、次のようになる。なお、第2図におけ
る数値は16進表現としている。Regarding such a TH command, the control shown in FIG. 2 will be explained in detail as follows. Note that the numerical values in FIG. 2 are expressed in hexadecimal.
今、メモリ6上のアドレスaに第4図に示したTH命令
が入っており、命令アドレスレジスタ4−1はアドレス
aの値を保持しているものとする。It is now assumed that the TH instruction shown in FIG. 4 is stored at address a on memory 6, and that instruction address register 4-1 holds the value of address a.
まず、このとき命令用アドレスレジスタ4−1にセット
されているアドレスaから始まるメモリ6上の4バイト
データが命令バッファ1にフェッチされる。命令デコー
ド部2は先頭1バイトの値96からこの命令がTH命令
であることをデコードし、アドレス計算部3に対し第1
オペランドアドレスCの計算を指示する。First, 4-byte data on the memory 6 starting from the address a set in the instruction address register 4-1 at this time is fetched into the instruction buffer 1. The instruction decoding unit 2 decodes that this instruction is a TH instruction from the value 96 of the first byte, and sends the first instruction to the address calculation unit 3.
Instructs calculation of operand address C.
アドレス計算部3はOPコードに続く2バイトの値62
00から第ルジスタの値及び第2のレジスタの値、更に
命令中で直接指示されるディプレイスメントの値200
を加算して第1オペランドアドレスの値Cを求め、この
計算されたオペランドアドレスCの値を第1オペランド
用レジスタ4−2に格納する。The address calculation unit 3 is the 2-byte value 62 following the OP code.
00 to the value of the first register, the value of the second register, and the displacement value 200 directly specified in the instruction.
is added to obtain the value C of the first operand address, and the calculated value of the operand address C is stored in the first operand register 4-2.
次に、残り1バイトのAdr値31と、そのときの命令
アドレス用レジスタ4−1の値aとを加算して(a+3
1)を求め、この(a+31>を分岐条件が成立した場
合にフェッチすべき命令アドレスとして第2オペランド
用アドレスレジスタ4−3に格納する。Next, the remaining 1 byte of Adr value 31 and the value a of the instruction address register 4-1 at that time are added (a+3
1) and stores this (a+31> in the second operand address register 4-3 as the instruction address to be fetched when the branch condition is satisfied.
以上のアドレス計算及びレジスタセットを終了すると、
命令アドレス用レジスタ4−1は命令長4だけカウント
アツプして(a+4>となり、命令バッフ?1はアドレ
ス(a+4>の命令XXをフェッチする。After completing the above address calculation and register setting,
The instruction address register 4-1 counts up by the instruction length 4 and becomes (a+4>), and the instruction buffer 1 fetches the instruction XX at the address (a+4>).
一方、命令実行部5は第1オペランド用アドレスレジス
タ4−2に格納された値Cによってアドレスされるメモ
リ6上のオペランドYYYYをリードし、次に分岐条件
を判定する。On the other hand, the instruction execution unit 5 reads the operand YYYY on the memory 6 addressed by the value C stored in the first operand address register 4-2, and then determines the branch condition.
ここで、オペランドYYYYの値がO以外ならば分岐条
件不成立であることから、そのとき命令バッファ1にフ
ェッチされている命令X×のデコード以降の動作が実行
される。Here, if the value of the operand YYYY is other than O, the branch condition is not satisfied, so the operations after the decoding of the instruction X× fetched into the instruction buffer 1 at that time are executed.
逆にオペランドYYYYの値がOならば分岐条件成立と
判定し、同一サイクル中に第2オペランド用アドレスl
ノジスタ4−3に格納されている命令分岐先アドレスの
値(a+31>を命令用アドレスレジスタ4−1にコピ
ーし、アドレス(a+31)に存在するデータZZを次
の命令としてフェッチして再実行する。Conversely, if the value of operand YYYY is O, it is determined that the branch condition is satisfied, and the address l for the second operand is set during the same cycle.
Copy the instruction branch destination address value (a+31> stored in the register 4-3 to the instruction address register 4-1, fetch the data ZZ existing at address (a+31) as the next instruction, and re-execute it. .
尚、上記の実施例はTH命令の具体例を例にとるもので
あったが、本発明はこれに限定されず、適宜の条件分岐
命令につきそのまま適用できる。It should be noted that, although the above-described embodiment takes a specific example of the TH instruction, the present invention is not limited thereto, and can be applied as is to any appropriate conditional branch instruction.
[発明の効果]
以上説明してきたように本発明によれば、分岐先のアド
レス計算結果を格納する専用レジスタを必要としないた
め、ハード量の削減が可能である。[Effects of the Invention] As described above, according to the present invention, there is no need for a dedicated register for storing the calculation result of a branch destination address, so that the amount of hardware can be reduced.
また、分岐条件の判定と分岐条件成立の分岐先アドレス
の命令アドレスへのコピーを同一サイクルで行なうこと
ができ、条件分岐命令の実行サイクル数を最少限に抑え
、パイプライン制御のネックとなっている条件分岐命令
による負担を軽減して、より高速化を図ることができる
。In addition, it is possible to determine the branch condition and copy the branch destination address when the branch condition is met to the instruction address in the same cycle, minimizing the number of execution cycles for conditional branch instructions, which can become a bottleneck in pipeline control. It is possible to reduce the burden caused by conditional branch instructions and achieve higher speeds.
第1図は本発明の原理説明図:
第2図は本発明の実施例構成図:
第3図は本発明の分岐動作タイミング説明図;第4図は
本発明の対象となるTH命令フ汁−マット説明図;
第5図は従来方式の構成図:
第6図は従来方式の動作タイミング説明図である。
図中、
1:命令バッファ
2:命令デコード部
3ニアドレス計算部
4ニアドレスレジスタ
4−1:命令用アドレスレジスタ(FA)4−2=第1
オペランド用アドレスレジスタ(DA)4−3=第2オ
ペランド用アドレスレジスタ(SA)5:命令実行部
6:メモリFig. 1 is a diagram explaining the principle of the present invention; Fig. 2 is a diagram illustrating the configuration of an embodiment of the present invention; Fig. 3 is a diagram illustrating the branch operation timing of the present invention; - Mat explanatory diagram; FIG. 5 is a configuration diagram of the conventional system; FIG. 6 is an explanatory diagram of the operation timing of the conventional system. In the figure, 1: Instruction buffer 2: Instruction decoding section 3 Near address calculation section 4 Near address register 4-1: Instruction address register (FA) 4-2 = 1st
Operand address register (DA) 4-3 = 2nd operand address register (SA) 5: Instruction execution unit 6: Memory
Claims (1)
に必要なオペランドアドレス(A)を計算してレジスタ
にセットし、次に分岐条件成立時にフェッチすべき命令
の分岐先アドレス(B)を計算してレジスタにセットし
、 一方、分岐条件の判定に必要な前記オペランドアドレス
(A)が確定した時点でメモリ上のオペランドをリード
して分岐条件成立の有無を判定し、分岐条件不成立時に
はカウントアップされた命令アドレス(C)により次の
命令をフェッチし、分岐条件設立時には前記分岐先アド
レス(B)を命令アドレス(C)として命令をフェッチ
する条件分岐命令の制御方式に於いて、 前記分岐先アドレス(B)を格納するレジスタを前記オ
ペランドアドレス(A)を格納する少なくとも2つのレ
ジスタ(4−2、4−3)のいずれかと共用すると共に
、又は前記分岐条件の判定と分岐条件成立時の分岐先ア
ドレス(B)の命令アドレス(C)へのコピーを同一サ
イクルで行なうことを特徴とする条件分岐命令の制御方
式。(1) When a conditional branch instruction is decoded, calculate the operand address (A) necessary for determining the branch condition, set it in a register, and then set the branch destination address (B) of the instruction to be fetched when the branch condition is met. On the other hand, when the operand address (A) necessary for determining the branch condition is determined, the operand on the memory is read to determine whether the branch condition is met, and if the branch condition is not met, the In the conditional branch instruction control method, the next instruction is fetched according to the incremented instruction address (C), and when a branch condition is established, the instruction is fetched using the branch destination address (B) as the instruction address (C). The register storing the branch destination address (B) is shared with one of the at least two registers (4-2, 4-3) storing the operand address (A), or the branch condition is judged and the branch condition is met. A control method for a conditional branch instruction, characterized in that a branch destination address (B) is copied to an instruction address (C) in the same cycle.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP1077150A JP2550408B2 (en) | 1989-03-29 | 1989-03-29 | Conditional branch instruction control method |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP1077150A JP2550408B2 (en) | 1989-03-29 | 1989-03-29 | Conditional branch instruction control method |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JPH02254541A true JPH02254541A (en) | 1990-10-15 |
| JP2550408B2 JP2550408B2 (en) | 1996-11-06 |
Family
ID=13625764
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP1077150A Expired - Lifetime JP2550408B2 (en) | 1989-03-29 | 1989-03-29 | Conditional branch instruction control method |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP2550408B2 (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US6003127A (en) * | 1995-10-04 | 1999-12-14 | Nippondenso Co., Ltd. | Pipeline processing apparatus for reducing delays in the performance of processing operations |
-
1989
- 1989-03-29 JP JP1077150A patent/JP2550408B2/en not_active Expired - Lifetime
Cited By (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US6003127A (en) * | 1995-10-04 | 1999-12-14 | Nippondenso Co., Ltd. | Pipeline processing apparatus for reducing delays in the performance of processing operations |
| US6308263B1 (en) | 1995-10-04 | 2001-10-23 | Nippondenso Co., Ltd. | Pipeline processing apparatus for reducing delays in the performance of processing operations |
Also Published As
| Publication number | Publication date |
|---|---|
| JP2550408B2 (en) | 1996-11-06 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JPH0283735A (en) | Instruction prefetching device | |
| JP2620511B2 (en) | Data processor | |
| JPH0348537B2 (en) | ||
| JPH0248732A (en) | Instruction pipeline microprocessor | |
| JPH04188229A (en) | floating point arithmetic processing unit | |
| JP3834145B2 (en) | Data processing apparatus having a microprocessor having a nestable delay branch instruction and a method of operating the microprocessor | |
| JPH0743648B2 (en) | Information processing equipment | |
| JPH02287626A (en) | Pipeline system branch instruction controller | |
| JPH02254541A (en) | Control system for conditional branch instruction | |
| JP2553200B2 (en) | Information processing device | |
| JP2814683B2 (en) | Instruction processing unit | |
| JPH0326862B2 (en) | ||
| JP2812610B2 (en) | Pipeline control method | |
| JP2503223B2 (en) | Prior control method | |
| JPH0419575B2 (en) | ||
| JP2819733B2 (en) | Information processing device | |
| JPS6047618B2 (en) | information processing equipment | |
| JP2597744B2 (en) | Branch control method | |
| JP2545594B2 (en) | Operand data prefetching method | |
| JPH07219771A (en) | Instruction processor | |
| JPH01271842A (en) | Information processor | |
| JPH0228724A (en) | Branch instruction control method | |
| JPS6354632A (en) | Instruction reading out and controlling system for electronic computer | |
| JPS586972B2 (en) | information processing equipment | |
| JPS61100836A (en) | Movement command logical comparison command processing method |