JP2010152843A - Circuit for estimating reliability of branch prediction and method thereof - Google Patents

Circuit for estimating reliability of branch prediction and method thereof Download PDF

Info

Publication number
JP2010152843A
JP2010152843A JP2008333049A JP2008333049A JP2010152843A JP 2010152843 A JP2010152843 A JP 2010152843A JP 2008333049 A JP2008333049 A JP 2008333049A JP 2008333049 A JP2008333049 A JP 2008333049A JP 2010152843 A JP2010152843 A JP 2010152843A
Authority
JP
Japan
Prior art keywords
reliability
prediction
branch
instruction
allowable threshold
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
Application number
JP2008333049A
Other languages
Japanese (ja)
Other versions
JP5387819B2 (en
Inventor
Yasuyuki Ninomiya
康之 二ノ宮
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.)
NEC Corp
Original Assignee
NEC Corp
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 NEC Corp filed Critical NEC Corp
Priority to JP2008333049A priority Critical patent/JP5387819B2/en
Publication of JP2010152843A publication Critical patent/JP2010152843A/en
Application granted granted Critical
Publication of JP5387819B2 publication Critical patent/JP5387819B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To estimate the reliability of branch prediction with high accuracy. <P>SOLUTION: The branch prediction reliability estimation circuit in a processor includes: an instruction processing pipeline 30 for performing pipeline processing of an input program; a branch predictor 40 for predicting a branch direction of a conditional branch instruction included in the program; and a pipeline gating circuit 20 for determining whether to permit speculation processing execution of an instruction in accordance with a prediction reliability to the conditional branch instruction. The branch prediction reliability estimation circuit is provided with: a reliability determining means for determining the reliability of the prediction from the prediction reliability to the conditional branch instruction; a reliability updating means for updating the reliability of the prediction to the conditional branch instruction; and an allowable threshold storage circuit 12 for storing an allowable threshold to be used to determine the reliability. The reliability determining means compares the allowable threshold input from the allowable threshold storage circuit 12 with the reliability to determine the reliability. <P>COPYRIGHT: (C)2010,JPO&INPIT

Description

本発明は、プロセッサ、特にパイプライン構造を持ち、かつ投機処理を行うプロセッサにおける分岐予測の信頼度見積もり回路及びその方法に関する。   The present invention relates to a branch prediction reliability estimation circuit and a method thereof in a processor, particularly a processor having a pipeline structure and performing speculative processing.

従来、プロセッサは命令レベル並列性を高めることで処理能力を向上させてきた。プロセッサのパイプライン構造は命令レベル並列性を得る為の方法の1つである。しかし、条件分岐命令は命令が実行させるまで後続の命令が不明なため、パイプライン構造による性能向上の妨げとなる。この問題を解決するために必要となるのが分岐予測器である。分岐予測器は条件分岐命令の分岐方向を予測し、プロセッサは分岐予測器の予測を元に投機的に後続の命令列を処理する。分岐予測器による予測が成功した場合、プロセッサは条件分岐命令による性能低下の影響を受けない。   Traditionally, processors have improved processing power by increasing instruction level parallelism. The pipeline structure of the processor is one way to obtain instruction level parallelism. However, the conditional branch instruction does not know the subsequent instruction until the instruction is executed, which hinders performance improvement by the pipeline structure. A branch predictor is required to solve this problem. The branch predictor predicts the branch direction of the conditional branch instruction, and the processor speculatively processes subsequent instruction sequences based on the prediction of the branch predictor. When the prediction by the branch predictor is successful, the processor is not affected by the performance degradation caused by the conditional branch instruction.

しかし、分岐予測器が予測に失敗すると間違って投機実行された命令列は実行が中止され、消去される。間違った命令の投機実行ために消費された電力は無駄となり、プロセッサの電力効率は低下してしまう。   However, if the branch predictor fails in prediction, the instruction sequence erroneously speculatively executed is stopped and deleted. The power consumed for speculative execution of the wrong instruction is wasted, and the power efficiency of the processor is reduced.

これに対し、パイプラインゲーティングと呼ばれる方法は予測の信頼性が低い条件分岐命令の投機処理を停止させる。無駄な投機実行を削減することによりプロセッサの電力効率を改善する。ただし、予測に成功する条件分岐命令を信頼できないと判断してその後続命令の投機処理を行わない場合、投機処理を行った場合と比較してプロセッサの処理時間が延び、電力効率向上の効果は薄れてしまう。このように、パイプラインゲーティングの効果は予測の信頼性の判定に依存しており、より高精度に信頼度を見積もる方法が必要とされている。   On the other hand, a method called pipeline gating stops speculative processing of a conditional branch instruction with low reliability of prediction. Improve processor power efficiency by reducing wasteful speculative execution. However, if the conditional branch instruction that succeeds in prediction is determined to be unreliable and the speculative processing of the subsequent instruction is not performed, the processing time of the processor is extended compared to the case where the speculative processing is performed, and the effect of improving the power efficiency It will fade. Thus, the effect of pipeline gating depends on the determination of the reliability of prediction, and a method for estimating the reliability with higher accuracy is required.

予測の信頼度を見積もる技術は、Jacobsen, Rotenberg, and Smith Confidence Estimator(JRS Estimator)と呼ばれる方法や、飽和型カウンタを持つ分岐予測器の内部状態を利用する方法で分岐予測の信頼度を見積もる方法が提案されている。   The technique for estimating the reliability of prediction is a method called Jacobsen, Rotenberg, and Smith Confidence Estimator (JRS Estimator), or a method of estimating the reliability of branch prediction by using the internal state of a branch predictor having a saturation counter. Has been proposed.

JRS Estimatorは、Correct/Incorrect Register History Table にnビットの1つないし複数の信頼度を記憶している。分岐予測が行われる時に1つの信頼度が選択され、Reduction Function と呼ばれる装置で選択された信頼度から信頼性の有無を判断する。非特許文献1では、複数の信頼度見積もり方法が試されているが、中でもリセッティングカウンタを用いた方法が最も高い見積もり精度を示すとしている。   The JRS Estimator stores n-bit reliability or reliability in the Correct / Incorrect Register History Table. When branch prediction is performed, one reliability is selected, and the presence or absence of reliability is determined from the reliability selected by a device called a reduction function. In Non-Patent Document 1, a plurality of reliability estimation methods have been tried. Among them, a method using a resetting counter shows the highest estimation accuracy.

リセッティングカウンタを用いた方法による信頼度の更新は、分岐予測器が予測に成功した場合に信頼度の値に1を加算し、予測に失敗した場合に信頼度の値を0に再設定する。   In the reliability update by the method using the reset counter, 1 is added to the reliability value when the branch predictor succeeds in prediction, and the reliability value is reset to 0 when the prediction fails.

信頼性は信頼度が閾値以上であれば信頼性がある、閾値未満であれば信頼性が無いと判定する。ただし、予測に失敗すると信頼度は最小値である0に再設定されるため、信頼度を閾値より大きい値に更新することは実装上の問題であり、信頼性を見積もる精度に影響を与えない。   The reliability is determined to be reliable if the reliability is equal to or higher than a threshold value, and not reliable if the reliability is less than the threshold value. However, if the prediction fails, the reliability is reset to the minimum value of 0. Therefore, updating the reliability to a value larger than the threshold is an implementation problem and does not affect the accuracy of estimating the reliability. .

図2はリセッティングカウンタを用いた方法による信頼度更新手段と信頼性判定手段の一例である。状態名である2進数は信頼度の値を表す。図2では7(111)、すなわち信頼度が最大値の時のみ、予測は信頼できると判定される。予測に成功した場合は信頼度に1が加算され、予測に失敗した場合は信頼度が0に再設定される。   FIG. 2 shows an example of reliability update means and reliability determination means by a method using a resetting counter. A binary number that is a state name represents a reliability value. In FIG. 2, it is determined that the prediction is reliable only when 7 (111), that is, when the reliability is the maximum value. If the prediction is successful, 1 is added to the reliability, and if the prediction fails, the reliability is reset to 0.

又、特許文献1には、飽和型カウンタを持つ分岐予測器を用いた方法が開示されているが、これは非特許文献1でリセッティングカウンタを用いた方法と比較された飽和型カウンタを用いた方法と原理は同じであり、信頼度の見積もり精度の点でリセッティングカウンタを用いた方法に劣る。
特表2008−529191号公報 E. Jacobsen, E. Rotenberg, and J. E.Smith; Assigning Confidence to Conditional Branch Predictions.1996. Proc. of 29th Annual International Symposium on Microarchitecture (MICRO-29)p.142-152
Patent Document 1 discloses a method using a branch predictor having a saturation counter, which uses a saturation counter compared to the method using a reset counter in Non-Patent Document 1. The method and principle are the same, and it is inferior to the method using a reset counter in terms of the accuracy of estimation of reliability.
Special table 2008-529191 gazette E. Jacobsen, E. Rotenberg, and JESmith; Assigning Confidence to Conditional Branch Predictions. 1996. Proc. Of 29th Annual International Symposium on Microarchitecture (MICRO-29) p.142-152

しかしながら、上記の関連する技術に係る発明は、信頼度の見積もり精度が低いという問題点がある。この問題点により、投機処理の誤停止を招き、プロセッサの処理速度を低下させてしまう。   However, the invention according to the related technique has a problem that the estimation accuracy of the reliability is low. Due to this problem, speculative processing is erroneously stopped and the processing speed of the processor is reduced.

その理由は、リセッティングカウンタを用いた方法が条件分岐命令の特異な振る舞いを許容できない点にある。リセッティングカウンタを用いた方法は、ある条件分岐命令に対する分岐予測が失敗すると信頼度は0に再設定される。このため、次にこの条件分岐命令に対する分岐予測が行われると予測は信頼できないと判定される。   The reason is that the method using the resetting counter cannot tolerate the specific behavior of the conditional branch instruction. In the method using the reset counter, the reliability is reset to 0 when the branch prediction for a certain conditional branch instruction fails. For this reason, when the next branch prediction for the conditional branch instruction is performed, it is determined that the prediction is not reliable.

しかし、プログラム内には一時的に特異な振る舞いをする条件分岐命令が多数存在する。例えば、プログラム内に数多く存在するループ処理は必ず最後にループを抜ける処理が必要となる。このループを抜ける処理はループを構築する条件分岐命令がループを行なう分岐方向とは逆の方向へ分岐することにより実現される。   However, there are many conditional branch instructions that temporarily behave in a program. For example, many loop processes existing in a program always require a process to exit the loop. The process of exiting the loop is realized by a conditional branch instruction for constructing the loop branching in a direction opposite to the branching direction in which the loop is performed.

このため、ループ処理は通常の分岐方向とは異なる、特異な分岐の振る舞いが起こると、リセッティングカウンタを用いた方法は信頼度を再設定する。しかし、この特異な振る舞いは一時的なものであり、予測は再び成功するようになる。予測に成功するにも関わらず、このループ処理を構成する条件分岐命令に対する予測が信頼を取り戻すには多くの信頼度の更新機会を要する。信頼性を取り戻すまでの間、プロセッサの投機処理が誤停止することでプロセッサの処理能力は低下する。   For this reason, in the loop processing, when a unique branching behavior different from the normal branching direction occurs, the method using the reset counter resets the reliability. However, this anomalous behavior is temporary and the prediction becomes successful again. Despite the success of the prediction, many prediction opportunities for reliability are required for the prediction of the conditional branch instructions constituting the loop processing to regain the trust. Until the reliability is restored, the speculative processing of the processor stops erroneously, so that the processing capacity of the processor decreases.

本発明は上記に鑑みてなされたものであり、関連技術に係る発明よりも高精度な分岐予測の信頼度見積もりを行なう分岐予測の信頼度見積もり回路及びその方法を提供することを目的とする。   The present invention has been made in view of the above, and an object of the present invention is to provide a branch prediction reliability estimation circuit and a method for performing branch prediction reliability estimation with higher accuracy than the related art.

上述の問題を解決するため、本発明に係る分岐予測の信頼度見積もり回路は、入力されたプログラムをパイプライン処理する命令処理パイプラインと、プログラム内に含まれる条件分岐命令の分岐方向を予測する分岐予測器と、前記条件分岐命令に対する予測の信頼性の有無に応じて命令の投機処理実行の可否を決めるパイプラインゲーティング回路と、を有するプロセッサにおける分岐予測の信頼度見積もり回路であって、前記条件分岐命令に対する予測の信頼度から該予測の信頼性の有無を判定する信頼性判定手段と、前記条件分岐命令に対する前記予測の前記信頼度を更新する信頼度更新手段と、前記信頼性の判定に用いる許容閾値を記憶する許容閾値記憶回路と、を備え、前記信頼性判定手段は、前記許容閾値記憶回路から入力された前記許容閾値と前記信頼度とを比較して前記信頼性の有無を判定することを特徴とする。   In order to solve the above-described problem, a branch prediction reliability estimation circuit according to the present invention predicts an instruction processing pipeline that pipelines an input program and a branch direction of a conditional branch instruction included in the program. A branch prediction reliability estimation circuit in a processor having a branch predictor and a pipeline gating circuit that determines whether or not to execute speculative processing according to the presence or absence of prediction reliability for the conditional branch instruction, Reliability determination means for determining the reliability of the prediction from the reliability of prediction for the conditional branch instruction; reliability update means for updating the reliability of the prediction for the conditional branch instruction; and And an allowable threshold value storage circuit for storing an allowable threshold value used for the determination, wherein the reliability determination means is input from the allowable threshold value storage circuit. And judging the presence or absence of said reliability by comparing the reliability and the tolerance threshold.

上述の問題を解決するため、本発明に係る分岐予測の信頼度見積もり方法は、入力されたプログラムをパイプライン処理する命令処理パイプラインと、プログラム内に含まれる条件分岐命令の分岐方向を予測する分岐予測器と、前記条件分岐命令に対する予測の信頼性の有無に応じて命令の投機処理実行の可否を決めるパイプラインゲーティング回路と、を有するプロセッサにおける分岐予測の信頼度見積もり方法であって、前記条件分岐命令に対する予測の信頼度から該予測の信頼性の有無を判定する際に用いる許容閾値を記憶する許容閾値記憶手順と、前記信頼性の有無を判定する信頼性判定手順と、前記条件分岐命令に対する前記予測の前記信頼度を更新する信頼度更新手順と、を備え、前記信頼性判定手順は、前記許容閾値記憶手順から入力された前記許容閾値と前記信頼度とを比較して前記信頼性の有無を判定することを特徴とする。   In order to solve the above-described problem, a branch prediction reliability estimation method according to the present invention predicts an instruction processing pipeline that pipelines an input program and a branch direction of a conditional branch instruction included in the program. A branch prediction reliability estimation method in a processor having a branch predictor and a pipeline gating circuit that determines whether or not to execute speculative processing of an instruction according to the presence or absence of prediction reliability for the conditional branch instruction, An allowable threshold value storing procedure for storing an allowable threshold value used when determining the presence or absence of the reliability of the prediction from the reliability of the prediction for the conditional branch instruction; a reliability determination procedure for determining the presence or absence of the reliability; and the condition A reliability update procedure for updating the reliability of the prediction for a branch instruction, and the reliability determination procedure includes the allowable threshold value storage procedure. Compared to et the inputted allowable threshold and the reliability and judging the presence or absence of the reliability.

本発明によれば、信頼性判定手段により、予測の一定の失敗を許容することで条件分岐命令の特異な分岐の振る舞いを許容し、正常な分岐の振る舞いに対しての予測の信頼性を正しく判定することができる。併せて、信頼度更新手段により、予測の失敗数が許容できない場合に信頼度を最も低い状態に再設定することで、信頼を一度失った条件分岐命令が短期間で信頼を取り戻すことを避けることにより、高精度な分岐予測の信頼度見積もりを行なう分岐予測の信頼度見積もり回路及びその方法を提供することができる。   According to the present invention, the reliability determination means allows a specific branching behavior of the conditional branch instruction by allowing a certain prediction failure, and corrects the prediction reliability for the normal branching behavior correctly. Can be determined. At the same time, by using the reliability update means, if the number of prediction failures is unacceptable, the reliability is reset to the lowest state, so that the conditional branch instruction that once lost the trust avoids regaining the trust in a short period of time. Accordingly, it is possible to provide a branch prediction reliability estimation circuit and a method thereof that perform highly accurate branch prediction reliability estimation.

[第1の実施の形態の構成]
図3を用いて本発明の第1の実施の形態を説明する。ここで、図3は、本発明の第1の実施の形態の構成を示すブロック図である。
[Configuration of First Embodiment]
A first embodiment of the present invention will be described with reference to FIG. Here, FIG. 3 is a block diagram showing the configuration of the first exemplary embodiment of the present invention.

図3によると、本発明の第1の実施の形態は、本発明の条件分岐命令に対する予測の信頼性を判定する手段と、条件分岐命令に対する予測の信頼度を更新する手段を有する信頼度見積もり回路10、信頼度記憶回路11、許容閾値記憶回路12、パイプラインゲーティング回路20、命令処理パイプライン30及び分岐予測器40を備える。   According to FIG. 3, the first embodiment of the present invention is a reliability estimation having means for determining the reliability of prediction for a conditional branch instruction of the present invention and means for updating the reliability of prediction for a conditional branch instruction. The circuit 10 includes a reliability storage circuit 11, an allowable threshold storage circuit 12, a pipeline gating circuit 20, an instruction processing pipeline 30, and a branch predictor 40.

命令処理パイプライン30は、プロセッサに入力された命令列を処理する装置であり、信頼度見積もり回路10、信頼度記憶回路11、パイプラインゲーティング回路20及び分岐予測器40と接続されている。   The instruction processing pipeline 30 is a device that processes an instruction sequence input to the processor, and is connected to the reliability estimation circuit 10, the reliability storage circuit 11, the pipeline gating circuit 20, and the branch predictor 40.

命令処理パイプライン30は条件分岐命令の入力時に分岐予測器40と信頼度記憶回路11とに条件分岐命令のアドレスを出力する。又、命令処理パイプライン30は、条件分岐命令の実行が完了した際にこの条件分岐命令のアドレスと分岐結果とを分岐予測器40と信頼度見積もり回路10とに出力する。   The instruction processing pipeline 30 outputs the address of the conditional branch instruction to the branch predictor 40 and the reliability storage circuit 11 when the conditional branch instruction is input. The instruction processing pipeline 30 outputs the address of the conditional branch instruction and the branch result to the branch predictor 40 and the reliability estimation circuit 10 when the execution of the conditional branch instruction is completed.

分岐予測器40は、命令処理パイプライン30接続されており、分岐の予測を行い、その結果を命令処理パイプライン30に出力する。又、分岐予測器40は、条件分岐命令の分岐結果が入力された際に予測の更新を行なう。   The branch predictor 40 is connected to the instruction processing pipeline 30, performs branch prediction, and outputs the result to the instruction processing pipeline 30. The branch predictor 40 updates the prediction when the branch result of the conditional branch instruction is input.

信頼度記憶回路11は、命令処理パイプライン30と、信頼度見積もり回路10とに接続されており、入力された条件分岐命令のアドレスから信頼度を読み出し、信頼度見積もり回路10に出力する。又、信頼度記憶回路11は、信頼度見積もり回路10から条件分岐命令のアドレスと更新された信頼度とを受け取り記憶する。   The reliability storage circuit 11 is connected to the instruction processing pipeline 30 and the reliability estimation circuit 10. The reliability storage circuit 11 reads the reliability from the address of the input conditional branch instruction and outputs the reliability to the reliability estimation circuit 10. The reliability storage circuit 11 receives and stores the conditional branch instruction address and the updated reliability from the reliability estimation circuit 10.

信頼度見積もり回路10は、信頼度記憶回路11、許容閾値記憶回路12、パイプラインゲーティング回路20及び命令処理パイプライン30と接続されており、信頼度記憶回路11から信頼度が入力されると、許容閾値記憶回路12から入力された許容閾値と信頼度とを比較して信頼性の有無を判定し、判定結果をパイプラインゲーティング装置20に出力する。又、信頼度見積もり回路10は、命令処理パイプライン30から実行された条件分岐命令のアドレスと分岐結果が入力された際に許容閾値記憶回路12から入力された許容閾値とを用いて信頼度を更新し、信頼度記憶回路11に出力する。   The reliability estimation circuit 10 is connected to the reliability storage circuit 11, the allowable threshold storage circuit 12, the pipeline gating circuit 20, and the instruction processing pipeline 30, and when the reliability is input from the reliability storage circuit 11. Then, the allowable threshold value input from the allowable threshold value storage circuit 12 is compared with the reliability to determine the presence or absence of reliability, and the determination result is output to the pipeline gating device 20. The reliability estimation circuit 10 calculates the reliability using the address of the conditional branch instruction executed from the instruction processing pipeline 30 and the allowable threshold value input from the allowable threshold value storage circuit 12 when the branch result is input. Update and output to the reliability storage circuit 11.

許容閾値記憶回路12は、信頼度見積もり回路10での信頼性の判定に用いる許容閾値を記憶する。   The allowable threshold value storage circuit 12 stores an allowable threshold value used for determination of reliability in the reliability estimation circuit 10.

パイプラインゲーティング回路20は、信頼度見積もり回路10及び命令処理パイプライン30と接続されており、信頼度見積もり回路10から入力された条件分岐命令の信頼性の情報と、命令処理パイプライン30から入力された実行された条件分岐命令との情報から命令処理パイプライン30による命令フェッチの停止と再開を制御する。   The pipeline gating circuit 20 is connected to the reliability estimation circuit 10 and the instruction processing pipeline 30, and the reliability information of the conditional branch instruction input from the reliability estimation circuit 10 and the instruction processing pipeline 30. Control of stop and restart of instruction fetch by the instruction processing pipeline 30 is performed based on the information about the executed conditional branch instruction.

[第1の実施の形態の動作]
図1は信頼度見積もり回路10で行なわれる信頼度更新手段及び信頼性判定手段の一例である。状態名である2進数は信頼度の値を表す。図1の許容閾値は4(100)であり、信頼度見積もり回路10は、例えば許容閾値記憶回路12から入力された信頼度が4(100)の場合は信頼できると判定し、許容閾値記憶回路12から入力された信頼度が3(011)の時は信頼できないと判定する。
[Operation of First Embodiment]
FIG. 1 shows an example of reliability update means and reliability determination means performed by the reliability estimation circuit 10. A binary number that is a state name represents a reliability value. The allowable threshold value in FIG. 1 is 4 (100), and the reliability estimation circuit 10 determines that the reliability is input when the reliability input from the allowable threshold value storage circuit 12 is 4 (100), for example. When the reliability input from 12 is 3 (011), it is determined that it is not reliable.

又、状態の更新を行なう時は、信頼度見積もり回路10は、例えば信頼度が5(101)で予測に成功した場合は信頼度を6(110)に更新して条件分岐命令のアドレスと共に許容閾値記憶回路12に出力し、信頼度が5(101)で予測に失敗した場合は信頼度を4(100)に更新して条件分岐命令のアドレスと共に許容閾値記憶回路12に出力し、信頼度が4(100)で予測に失敗した場合は信頼度を0(000)に再設定して条件分岐命令のアドレスと共に許容閾値記憶回路12に出力する。   When the state is updated, the reliability estimation circuit 10 updates the reliability to 6 (110), for example, when the reliability is 5 (101) and the prediction is successful, and allows the conditional branch instruction address. If the reliability is 5 (101) and the prediction fails, the reliability is updated to 4 (100) and output to the allowable threshold storage circuit 12 together with the address of the conditional branch instruction. If the prediction fails at 4 (100), the reliability is reset to 0 (000) and output to the allowable threshold value storage circuit 12 together with the address of the conditional branch instruction.

[他の実施の形態]
次に、本発明の第2の実施の形態について図面を参照して説明する。第1の実施の形態と同様の構成要素については図と同様の符号を付し、詳細な説明を省略する。ここで、図4は、第2の実施の形態の構成を示すブロック図である。
[Other embodiments]
Next, a second embodiment of the present invention will be described with reference to the drawings. Constituent elements similar to those in the first embodiment are denoted by the same reference numerals as those in the drawing, and detailed description thereof is omitted. Here, FIG. 4 is a block diagram showing a configuration of the second embodiment.

図4を参照すると、第2の実施の形態は、第1の実施の形態の分岐予測器の代わりに分岐予測記憶回路41を備える。   Referring to FIG. 4, the second embodiment includes a branch prediction storage circuit 41 in place of the branch predictor of the first embodiment.

分岐予測記憶回路41は1つ又は複数のエントリを持つテーブルであり、1つのエントリは1ビットで構成される。前記エントリは、例えば1ならば分岐成立、0ならば分岐不成立というように分岐の予測の方向を記憶している。   The branch prediction storage circuit 41 is a table having one or a plurality of entries, and one entry is composed of 1 bit. The entry stores the direction of branch prediction, for example, if the branch is 1, the branch is established, and if 0, the branch is not established.

分岐予測記憶回路41は信頼度見積もり回路10と、命令処理パイプライン30とに接続されており、命令処理パイプライン30から入力されたアドレスに応じて、読み出した分岐の予測を命令処理パイプライン30に出力する。   The branch prediction storage circuit 41 is connected to the reliability estimation circuit 10 and the instruction processing pipeline 30 and predicts the read branch according to the address input from the instruction processing pipeline 30. Output to.

命令処理パイプライン30は信頼度見積もり回路10に実行が完了した条件分岐命令のアドレスを出力する。   The instruction processing pipeline 30 outputs the address of the conditional branch instruction that has been executed to the reliability estimation circuit 10.

信頼度見積もり回路10は第1の実施の形態における接続に加えて、分岐予測記憶回路41に接続されている。信頼度見積もり回路10は、条件分岐命令に対する予測の信頼度から予測の信頼性の有無を判定し、入力されたアドレスと分岐結果とから信頼度と分岐の予測の方向とを更新する。信頼度見積もり回路10は信頼度が0で、かつ予測に失敗した場合に分岐予測の方向を反転し分岐予測記憶回路41に記憶する。   The reliability estimation circuit 10 is connected to the branch prediction storage circuit 41 in addition to the connection in the first embodiment. The reliability estimation circuit 10 determines the presence / absence of prediction reliability from the prediction reliability for the conditional branch instruction, and updates the reliability and the direction of branch prediction from the input address and branch result. When the reliability is 0 and the prediction fails, the reliability estimation circuit 10 reverses the direction of branch prediction and stores it in the branch prediction storage circuit 41.

すなわち、信頼度更新手段は、信頼度の値を増減させることで更新を行い、予測に成功した場合に信頼度を増加させ、予測に失敗かつ信頼度が許容閾値よりも高い場合に信頼度を減少させ、予測に失敗かつ許容閾値以下の場合に信頼度を最も低い値に設定する。   That is, the reliability update means updates the value by increasing or decreasing the reliability value, increases the reliability when the prediction is successful, and increases the reliability when the prediction fails and the reliability is higher than the allowable threshold. Decrease and set the reliability to the lowest value if prediction fails and is below the acceptable threshold.

信頼度を最も低い値に設定した後に予測を失敗したときは、分岐予測更新手段が分岐成立の場合から分岐不成立の場合又は分岐不成立の場合から分岐成立の場合にそれぞれ分岐の予測の方向を反転する。その後、信頼度更新手段は信頼度の値を増減させることで更新を行う。   When prediction fails after setting the reliability to the lowest value, the branch prediction update means reverses the direction of branch prediction when the branch is taken to when the branch is not taken, or when the branch is not taken and the branch is taken. To do. Thereafter, the reliability update means performs update by increasing or decreasing the value of reliability.

図6は第2の実施の形態における信頼度更新手段と信頼性判定手段の一例を示す図である。状態名は1ビットの分岐の予測の方向と3ビットの信頼度の値の組み合わせである。分岐の予測は分岐成立を1、分岐不成立を0で表している。分岐の予測は信頼度が0で、かつ予測に失敗した場合にのみ値が反転される。又、分岐の予測の値に応じて複数の前記許容閾値を使用する事も可能である。図6では、分岐成立と予測する場合の前記許容閾値を5(101)、分岐不成立と予測する場合の前記許容閾値を4(100)と設定している。   FIG. 6 is a diagram illustrating an example of the reliability update unit and the reliability determination unit in the second embodiment. The state name is a combination of a 1-bit branch prediction direction and a 3-bit reliability value. In the branch prediction, a branch establishment is represented by 1 and a branch failure is represented by 0. The branch prediction is inverted only when the reliability is 0 and the prediction fails. It is also possible to use a plurality of the allowable thresholds depending on the branch prediction value. In FIG. 6, the allowable threshold for predicting that a branch is taken is set to 5 (101), and the allowable threshold for predicting that a branch is not taken is set to 4 (100).

なお、分岐予測記憶回路41は信頼度記憶回路11と統合することができる。   The branch prediction storage circuit 41 can be integrated with the reliability storage circuit 11.

次に、本発明の第3の実施の形態について図面を参照して説明する。第1の実施の形態と同様の構成要素については図と同様の符号を付し、詳細な説明を省略する。ここで、図5は、第3の実施の形態の構成を示すブロック図である。   Next, a third embodiment of the present invention will be described with reference to the drawings. Constituent elements similar to those in the first embodiment are denoted by the same reference numerals as those in the drawing, and detailed description thereof is omitted. Here, FIG. 5 is a block diagram showing a configuration of the third embodiment.

図5を参照すると、第1の実施の形態の構造に加えて、許容閾値更新回路13と温度計測回路50とが設けられている。   Referring to FIG. 5, in addition to the structure of the first embodiment, an allowable threshold value update circuit 13 and a temperature measurement circuit 50 are provided.

温度計測回路50の情報は接続されている許容閾値更新回路13に逐次送信されている。   Information of the temperature measurement circuit 50 is sequentially transmitted to the connected allowable threshold value update circuit 13.

許容閾値更新回路13は温度が予め設定された温度閾値より高い場合に許容閾値記憶回路12から入力された前述の許容閾値の値を小さくし、許容閾値記憶回路12に出力する。なお、この温度閾値は複数でもよい。更新された許容閾値の値は信頼度見積もり回路10で使用される。   When the temperature is higher than a preset temperature threshold, the allowable threshold update circuit 13 decreases the above-described allowable threshold value input from the allowable threshold storage circuit 12 and outputs it to the allowable threshold storage circuit 12. The temperature threshold value may be plural. The updated allowable threshold value is used in the reliability estimation circuit 10.

前述の許容閾値を小さくすると信頼性があると判定される条件分岐命令が増え、フェッチが停止する回数が増加する。消費する電力が減り、プロセッサの温度を下げる効果が期待できる。   If the allowable threshold value is decreased, the number of conditional branch instructions that are determined to be reliable increases, and the number of times fetching stops increases. Power consumption is reduced, and the effect of lowering the processor temperature can be expected.

温度計回路50から許容閾値更新回路13に入力される信号は他のプロセッサからの減速命令や、システム上で動作するオペレーティングシステムやソフトウェアからの減速命令で代用できることを当業者は容易に想像できる。   Those skilled in the art can easily imagine that the signal input from the thermometer circuit 50 to the allowable threshold value update circuit 13 can be substituted by a deceleration command from another processor or a deceleration command from an operating system or software operating on the system.

又、信頼性見積もりの精度を向上させることで、パイプラインゲーティングによる投機処理の誤停止を削減する。この結果、プロセッサの性能低下を抑制し、電力効率を向上させることができる。信頼性が低いと判定される条件分岐命令の集合に予測に成功する条件分岐命令の含有率を減らし、処理速度の低下を抑える。   In addition, by improving the accuracy of reliability estimation, it is possible to reduce erroneous stoppage of speculative processing due to pipeline gating. As a result, it is possible to suppress the performance degradation of the processor and improve the power efficiency. The content rate of conditional branch instructions that are successfully predicted in a set of conditional branch instructions that are determined to be low in reliability is reduced, and a reduction in processing speed is suppressed.

本発明は、プロセッサ、特にパイプライン構造を持ち、かつ投機処理を行うプロセッサに適用することでプロセッサの電力効率を改善することができる。   The present invention can improve the power efficiency of a processor by applying it to a processor, particularly a processor having a pipeline structure and performing speculative processing.

第1の実施の形態の信頼度見積もり回路で行なわれる信頼度更新手段及び信頼性判定手段の一例を示す図である。It is a figure which shows an example of the reliability update means and reliability determination means which are performed by the reliability estimation circuit of 1st Embodiment. リセッティングカウンタを用いた方法による信頼度更新手段と信頼性判定手段の一例を示す図である。It is a figure which shows an example of the reliability update means by the method using a reset counter, and a reliability determination means. 第1の実施の形態の構成を示すブロック図である。It is a block diagram which shows the structure of 1st Embodiment. 第2の実施の形態の構成を示すブロック図である。It is a block diagram which shows the structure of 2nd Embodiment. 第3の実施の形態の構成を示すブロック図である。It is a block diagram which shows the structure of 3rd Embodiment. 第2の実施の形態における信頼度更新手段及び信頼性判定手段の一例を示す図である。It is a figure which shows an example of the reliability update means and reliability determination means in 2nd Embodiment.

符号の説明Explanation of symbols

10 信頼度見積もり回路
11 信頼度記憶回路
12 許容閾値記憶回路
13 許容閾値更新回路
20 パイプラインゲーティング回路
30 命令処理パイプライン
40 分岐予測器
41 分岐予測記憶回路
50 温度計測回路
DESCRIPTION OF SYMBOLS 10 Reliability estimation circuit 11 Reliability memory circuit 12 Allowable threshold memory circuit 13 Allowable threshold update circuit 20 Pipeline gating circuit 30 Instruction processing pipeline 40 Branch predictor 41 Branch prediction memory circuit 50 Temperature measurement circuit

Claims (16)

入力されたプログラムをパイプライン処理する命令処理パイプラインと、プログラム内に含まれる条件分岐命令の分岐方向を予測する分岐予測器と、前記条件分岐命令に対する予測の信頼性の有無に応じて命令の投機処理実行の可否を決めるパイプラインゲーティング回路と、を有するプロセッサにおける分岐予測の信頼度見積もり回路であって、
前記条件分岐命令に対する予測の信頼度から該予測の信頼性の有無を判定する信頼性判定手段と、
前記条件分岐命令に対する前記予測の前記信頼度を更新する信頼度更新手段と、
前記信頼性の判定に用いる許容閾値を記憶する許容閾値記憶回路と、
を備え、
前記信頼性判定手段は、前記許容閾値記憶回路から入力された前記許容閾値と前記信頼度とを比較して前記信頼性の有無を判定することを特徴とする分岐予測の信頼度見積もり回路。
An instruction processing pipeline that pipelines an input program, a branch predictor that predicts the branch direction of a conditional branch instruction included in the program, and an instruction depending on whether or not the prediction reliability of the conditional branch instruction is reliable A pipeline gating circuit that determines whether or not to execute speculative processing, and a reliability estimation circuit for branch prediction in a processor having:
Reliability determination means for determining the reliability of the prediction from the reliability of the prediction for the conditional branch instruction;
Reliability update means for updating the reliability of the prediction for the conditional branch instruction;
An allowable threshold value storage circuit for storing an allowable threshold value used for the determination of the reliability;
With
A reliability estimation circuit for branch prediction, wherein the reliability determination unit determines the presence or absence of the reliability by comparing the reliability with the allowable threshold value input from the allowable threshold value storage circuit.
前記信頼度更新手段は、前記信頼度の値を増減させることで更新を行い、前記予測に成功した場合に前記信頼度を増加させ、前記予測に失敗かつ前記信頼度が前記許容閾値よりも高い場合に前記信頼度を減少させ、前記予測に失敗かつ前記許容閾値以下の場合に前記信頼度を最も低い値に再設定することを特徴とする請求項1に記載の分岐予測の信頼度見積もり回路。   The reliability update means updates the value by increasing or decreasing the value of the reliability, increases the reliability when the prediction is successful, fails in the prediction, and the reliability is higher than the allowable threshold. 2. The branch prediction reliability estimation circuit according to claim 1, wherein the reliability is decreased, and the reliability is reset to a lowest value when the prediction fails and is equal to or less than the allowable threshold. . 前記信頼度更新手段は、前記予測に成功した場合に前記信頼度が最大値である場合を除いて前記信頼度を1増加させ、前記予測に失敗かつ前記信頼度が前記許容閾値よりも高い場合に信頼度を1減少させ、前記予測に失敗かつ前記信頼度が前記許容閾値以下の場合に前記信頼度を0に再設定することを特徴とする請求項2に記載の分岐予測の信頼度見積もり回路。   The reliability update unit increases the reliability by 1 except when the reliability is the maximum value when the prediction is successful, and the prediction fails and the reliability is higher than the allowable threshold. 3. The reliability estimation of branch prediction according to claim 2, wherein the reliability is decreased by 1, and the reliability is reset to 0 when the prediction fails and the reliability is equal to or less than the allowable threshold. circuit. 入力されたプログラムをパイプライン処理する命令処理パイプラインと、条件分岐命令に対する予測の信頼性の有無に応じて命令の投機処理実行の可否を決めるパイプラインゲーティング回路と、を有するプロセッサにおける分岐予測の信頼度見積もり回路であって、
前記命令処理パイプラインから入力されるアドレスと前記条件分岐命令の分岐結果とから前記条件分岐命令の分岐の予測の方向を分岐成立から分岐不成立又は分岐不成立から分岐成立へ更新する分岐予測更新手段と、
前記条件分岐命令に対する前記予測の信頼度から該予測の信頼性の有無を判定する信頼性判定手段と、
前記条件分岐命令に対する前記予測の前記信頼度を更新する信頼度更新手段と、
前記信頼性の判定に用いる許容閾値を記憶する許容閾値記憶回路と、
を備え、
前記信頼性判定手段は、前記許容閾値記憶回路から入力された前記許容閾値と前記信頼度とを比較して前記信頼性の有無を判定することを特徴とする分岐予測の信頼度見積もり回路。
Branch prediction in a processor having an instruction processing pipeline that pipelines an input program, and a pipeline gating circuit that determines whether or not to execute speculative processing of an instruction according to the presence or absence of prediction reliability for a conditional branch instruction The reliability estimation circuit of
Branch prediction update means for updating the branch prediction direction of the conditional branch instruction from branch establishment to branch failure or from branch failure to branch establishment from the address input from the instruction processing pipeline and the branch result of the conditional branch instruction; ,
Reliability determination means for determining the reliability of the prediction from the reliability of the prediction for the conditional branch instruction;
Reliability update means for updating the reliability of the prediction for the conditional branch instruction;
An allowable threshold value storage circuit for storing an allowable threshold value used for the determination of the reliability;
With
A reliability estimation circuit for branch prediction, wherein the reliability determination unit determines the presence or absence of the reliability by comparing the reliability with the allowable threshold value input from the allowable threshold value storage circuit.
前記信頼度更新手段は、分岐成立又は分岐不成立のそれぞれで、前記信頼度の値を増減させることで更新を行い、前記予測に成功した場合に前記信頼度を増加させ、前記予測に失敗かつ前記信頼度が前記許容閾値よりも高い場合に前記信頼度を減少させ、前記予測に失敗かつ前記許容閾値以下の場合に前記信頼度を最も低い値に再設定し、
前記分岐予測更新手段は、前記信頼度を最も低い値に再設定した後に前記予測を失敗したときは、前記分岐成立の場合から前記分岐不成立の場合又は前記分岐不成立の場合から前記分岐成立の場合にそれぞれ反転し、
前記信頼度更新手段は、該反転後に、前記信頼度の値を増減させることで前記信頼度の更新を行うことを特徴とする請求項4に記載の分岐予測の信頼度見積もり回路。
The reliability update means performs update by increasing or decreasing the reliability value in each of branch establishment or branch failure, increases the reliability when the prediction is successful, fails the prediction, and Decreasing the reliability when the reliability is higher than the allowable threshold, resetting the reliability to the lowest value when the prediction fails and below the allowable threshold,
The branch prediction update means, when the prediction fails after resetting the reliability to the lowest value, when the branch is established, when the branch is not established, or when the branch is established, and when the branch is established Invert each
5. The reliability estimation circuit for branch prediction according to claim 4, wherein the reliability update means updates the reliability by increasing or decreasing the reliability value after the inversion.
前記信頼度更新手段は、前記予測に成功した場合に前記信頼度が最大値である場合を除いて前記信頼度を1増加させ、前記予測に失敗かつ前記信頼度が前記許容閾値よりも高い場合に信頼度を1減少させ、前記予測に失敗かつ前記信頼度が前記許容閾値以下の場合に前記信頼度を0に再設定することを特徴とする請求項5に記載の分岐予測の信頼度見積もり回路。   When the prediction is successful, the reliability update unit increases the reliability by 1 except when the reliability is the maximum value, and the prediction fails and the reliability is higher than the allowable threshold. 6. The reliability estimation for branch prediction according to claim 5, wherein the reliability is decreased by 1, and the reliability is reset to 0 when the prediction fails and the reliability is equal to or less than the allowable threshold. circuit. 外部環境の変化を計測する計測手段と、
前記分岐命令の信頼性を判定する閾値の値を動的に変更する閾値更新手段と、
を備え、
前記閾値更新手段は、前記プロセッサの速度と消費電力を動的に制御することを特徴とする請求項1に記載の分岐予測の信頼度見積もり回路。
Measuring means for measuring changes in the external environment;
Threshold update means for dynamically changing a threshold value for determining the reliability of the branch instruction;
With
The branch prediction reliability estimation circuit according to claim 1, wherein the threshold update unit dynamically controls the speed and power consumption of the processor.
前記計測手段は、システムの温度を計測し、前記閾値更新手段は、前記計測手段から入力された温度から前記分岐命令の信頼性を判定する閾値の値を動的に変更することを特徴とする請求項7に記載の分岐予測の信頼度見積もり回路。   The measuring means measures the temperature of the system, and the threshold updating means dynamically changes a threshold value for determining the reliability of the branch instruction from the temperature input from the measuring means. The branch prediction reliability estimation circuit according to claim 7. 入力されたプログラムをパイプライン処理する命令処理パイプラインと、プログラム内に含まれる条件分岐命令の分岐方向を予測する分岐予測器と、前記条件分岐命令に対する予測の信頼性の有無に応じて命令の投機処理実行の可否を決めるパイプラインゲーティング回路と、を有するプロセッサにおける分岐予測の信頼度見積もり方法であって、
前記条件分岐命令に対する予測の信頼度から該予測の信頼性の有無を判定する際に用いる許容閾値を記憶する許容閾値記憶手順と、
前記信頼性の有無を判定する信頼性判定手順と、
前記条件分岐命令に対する前記予測の前記信頼度を更新する信頼度更新手順と、
を備え、
前記信頼性判定手順は、前記許容閾値記憶手順から入力された前記許容閾値と前記信頼度とを比較して前記信頼性の有無を判定することを特徴とする分岐予測の信頼度見積もり方法。
An instruction processing pipeline that pipelines an input program, a branch predictor that predicts the branch direction of a conditional branch instruction included in the program, and an instruction depending on whether or not the prediction reliability of the conditional branch instruction is reliable A pipeline gating circuit that determines whether or not to execute speculative processing, and a branch prediction reliability estimation method in a processor having:
An allowable threshold value storing procedure for storing an allowable threshold value used when determining the reliability of the prediction from the reliability of the prediction for the conditional branch instruction;
A reliability determination procedure for determining the presence or absence of the reliability;
A reliability update procedure for updating the reliability of the prediction for the conditional branch instruction;
With
The reliability estimation method of branch prediction, wherein the reliability determination procedure determines the presence or absence of the reliability by comparing the reliability with the allowable threshold value input from the allowable threshold value storage procedure.
前記信頼度更新手順は、前記信頼度の値を増減させることで更新を行い、前記予測に成功した場合に前記信頼度を増加させ、前記予測に失敗かつ前記信頼度が前記許容閾値よりも高い場合に前記信頼度を減少させ、前記予測に失敗かつ前記許容閾値以下の場合に前記信頼度を最も低い値に再設定することを特徴とする請求項9に記載の分岐予測の信頼度見積もり方法。   The reliability update procedure updates by increasing or decreasing the value of the reliability, increases the reliability when the prediction is successful, fails in the prediction, and the reliability is higher than the allowable threshold 10. The reliability estimation method for branch prediction according to claim 9, wherein the reliability is decreased in a case, and the reliability is reset to a lowest value when the prediction fails and is equal to or less than the allowable threshold. . 前記信頼度更新手順は、前記予測に成功した場合に前記信頼度が最大値である場合を除いて前記信頼度を1増加させ、前記予測に失敗かつ前記信頼度が前記許容閾値よりも高い場合に信頼度を1減少させ、前記予測に失敗かつ前記信頼度が前記許容閾値以下の場合に前記信頼度を0に再設定することを特徴とする請求項10に記載の分岐予測の信頼度見積もり方法。   The reliability update procedure increases the reliability by 1 except when the reliability is the maximum value when the prediction is successful, and the prediction fails and the reliability is higher than the allowable threshold. 11. The reliability estimation of branch prediction according to claim 10, wherein the reliability is decreased by 1, and the reliability is reset to 0 when the prediction fails and the reliability is equal to or less than the allowable threshold. Method. 入力されたプログラムをパイプライン処理する命令処理パイプラインと、条件分岐命令に対する予測の信頼性の有無に応じて命令の投機処理実行の可否を決めるパイプラインゲーティング回路と、を有するプロセッサにおける分岐予測の信頼度見積もり方法であって、
前記命令処理パイプラインから入力されるアドレスと前記条件分岐命令の分岐結果とから前記条件分岐命令の分岐の予測の方向を分岐成立から分岐不成立又は分岐不成立から分岐成立へ更新する分岐予測更新手順と、
前記条件分岐命令に対する予測の信頼度から該予測の信頼性の有無を判定する際に用いる許容閾値を記憶する許容閾値記憶手順と、
前記信頼性の有無を判定する信頼性判定手順と、
前記条件分岐命令に対する前記予測の前記信頼度を更新する信頼度更新手順と、
を備え、
前記信頼性判定手順は、前記許容閾値記憶手順から入力された前記許容閾値と前記信頼度とを比較して前記信頼性の有無を判定することを特徴とする分岐予測の信頼度見積もり方法。
Branch prediction in a processor having an instruction processing pipeline that pipelines an input program, and a pipeline gating circuit that determines whether or not to execute speculative processing of an instruction according to the presence or absence of prediction reliability for a conditional branch instruction The reliability estimation method of
A branch prediction update procedure for updating the branch prediction direction of the conditional branch instruction from branch establishment to branch failure or branch failure to branch establishment from the address input from the instruction processing pipeline and the branch result of the conditional branch instruction; ,
An allowable threshold value storing procedure for storing an allowable threshold value used when determining the reliability of the prediction from the reliability of the prediction for the conditional branch instruction;
A reliability determination procedure for determining the presence or absence of the reliability;
A reliability update procedure for updating the reliability of the prediction for the conditional branch instruction;
With
The reliability estimation method of branch prediction, wherein the reliability determination procedure determines the presence or absence of the reliability by comparing the reliability with the allowable threshold value input from the allowable threshold value storage procedure.
前記信頼度更新手順は、分岐成立又は分岐不成立のそれぞれで、前記信頼度の値を増減させることで更新を行い、前記予測に成功した場合に前記信頼度を増加させ、前記予測に失敗かつ前記信頼度が前記許容閾値よりも高い場合に前記信頼度を減少させ、前記予測に失敗かつ前記許容閾値以下の場合に前記信頼度を最も低い値に再設定し、
前記分岐予測更新手順は、前記信頼度を最も低い値に再設定した後に前記予測を失敗したときは、前記分岐成立の場合から前記分岐不成立の場合又は前記分岐不成立の場合から前記分岐成立の場合にそれぞれ反転し、
前記信頼度更新手順は、該反転後に、前記信頼度の値を増減させることで前記信頼度の更新を行うことを特徴とする請求項12に記載の分岐予測の信頼度見積もり方法。
The reliability update procedure is performed by increasing or decreasing the reliability value in each of branch establishment or branch failure, increasing the reliability when the prediction is successful, failing the prediction, and Decreasing the reliability when the reliability is higher than the allowable threshold, resetting the reliability to the lowest value when the prediction fails and below the allowable threshold,
In the branch prediction update procedure, when the prediction fails after resetting the reliability to the lowest value, the case where the branch is taken from the case where the branch is taken or the case where the branch is taken from the case where the branch is not taken Invert each
13. The reliability estimation method for branch prediction according to claim 12, wherein, in the reliability update procedure, after the inversion, the reliability is updated by increasing or decreasing the reliability value.
前記信頼度更新手順は、前記予測に成功した場合に前記信頼度が最大値である場合を除いて前記信頼度を1増加させ、前記予測に失敗かつ前記信頼度が前記許容閾値よりも高い場合に信頼度を1減少させ、前予測に失敗かつ前信頼度が前記許容閾値以下の場合に前記信頼度を0に再設定することを特徴とする請求項13に記載の分岐予測の信頼度見積もり方法。   The reliability update procedure increases the reliability by 1 except when the reliability is the maximum value when the prediction is successful, and the prediction fails and the reliability is higher than the allowable threshold. 14. The reliability estimation of branch prediction according to claim 13, wherein the reliability is decreased by 1, and the reliability is reset to 0 when the previous prediction fails and the previous reliability is less than or equal to the allowable threshold. Method. 外部環境の変化を計測する計測手順と、
前記分岐命令の信頼性を判定する閾値の値を動的に変更する閾値更新手順と、
を備え、
前記閾値更新手順は、前記プロセッサの速度と消費電力を動的に制御することを特徴とする請求項9に記載の分岐予測の信頼度見積もり方法。
A measurement procedure for measuring changes in the external environment;
A threshold update procedure for dynamically changing a threshold value for determining the reliability of the branch instruction;
With
The branch prediction reliability estimation method according to claim 9, wherein the threshold update procedure dynamically controls the speed and power consumption of the processor.
前記計測手順は、システムの温度を計測し、前記閾値更新手順は、前記計測手順から入力された温度から前記分岐命令の信頼性を判定する閾値の値を動的に変更することを特徴とする請求項15に記載の分岐予測の信頼度見積もり方法。   The measurement procedure measures a system temperature, and the threshold update procedure dynamically changes a threshold value for determining the reliability of the branch instruction from the temperature input from the measurement procedure. The branch prediction reliability estimation method according to claim 15.
JP2008333049A 2008-12-26 2008-12-26 Reliability estimation circuit and method for branch prediction Expired - Fee Related JP5387819B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2008333049A JP5387819B2 (en) 2008-12-26 2008-12-26 Reliability estimation circuit and method for branch prediction

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2008333049A JP5387819B2 (en) 2008-12-26 2008-12-26 Reliability estimation circuit and method for branch prediction

Publications (2)

Publication Number Publication Date
JP2010152843A true JP2010152843A (en) 2010-07-08
JP5387819B2 JP5387819B2 (en) 2014-01-15

Family

ID=42571822

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2008333049A Expired - Fee Related JP5387819B2 (en) 2008-12-26 2008-12-26 Reliability estimation circuit and method for branch prediction

Country Status (1)

Country Link
JP (1) JP5387819B2 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013254484A (en) * 2012-04-02 2013-12-19 Apple Inc Improving performance of vector partitioning loops
US9348589B2 (en) 2013-03-19 2016-05-24 Apple Inc. Enhanced predicate registers having predicates corresponding to element widths
US9389860B2 (en) 2012-04-02 2016-07-12 Apple Inc. Prediction optimizations for Macroscalar vector partitioning loops
US9817663B2 (en) 2013-03-19 2017-11-14 Apple Inc. Enhanced Macroscalar predicate operations
JP7430173B2 (en) 2018-08-29 2024-02-09 アドバンスト・マイクロ・ディバイシズ・インコーポレイテッド branch trust throttle

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000322257A (en) * 1999-05-10 2000-11-24 Nec Corp Speculative execution control method for conditional branch instruction
JP2001014162A (en) * 1999-07-02 2001-01-19 Matsushita Electric Ind Co Ltd Branch predicting method and data processor
JP2001236225A (en) * 2000-02-22 2001-08-31 Fujitsu Ltd Arithmetic unit and branch predicting method and information processor
JP2002182906A (en) * 2000-12-15 2002-06-28 Nec Corp Instruction executing method, its device, branching predicting method and its device
JP2008529191A (en) * 2005-02-03 2008-07-31 クゥアルコム・インコーポレイテッド Power efficient instruction prefetch mechanism
WO2008122662A1 (en) * 2007-04-10 2008-10-16 International Business Machines Corporation Method and apparatus for conserving power by throttling instruction fetching when a processor encounters low confidence branches in an information handling system

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000322257A (en) * 1999-05-10 2000-11-24 Nec Corp Speculative execution control method for conditional branch instruction
JP2001014162A (en) * 1999-07-02 2001-01-19 Matsushita Electric Ind Co Ltd Branch predicting method and data processor
JP2001236225A (en) * 2000-02-22 2001-08-31 Fujitsu Ltd Arithmetic unit and branch predicting method and information processor
JP2002182906A (en) * 2000-12-15 2002-06-28 Nec Corp Instruction executing method, its device, branching predicting method and its device
JP2008529191A (en) * 2005-02-03 2008-07-31 クゥアルコム・インコーポレイテッド Power efficient instruction prefetch mechanism
WO2008122662A1 (en) * 2007-04-10 2008-10-16 International Business Machines Corporation Method and apparatus for conserving power by throttling instruction fetching when a processor encounters low confidence branches in an information handling system
JP2010524107A (en) * 2007-04-10 2010-07-15 インターナショナル・ビジネス・マシーンズ・コーポレーション Method for reducing power consumption by processor, processor, and information processing system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
JPN7010002757; S.Manne et al.: '"Pipeline gating: speculation control for energy reduction"' Proceedings of the 25th annual international symposium on Computer architecture (ISCA '98) Volume 26 , Issue 3, 1998, Pages: 132 - 141, ACM *

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013254484A (en) * 2012-04-02 2013-12-19 Apple Inc Improving performance of vector partitioning loops
US9116686B2 (en) 2012-04-02 2015-08-25 Apple Inc. Selective suppression of branch prediction in vector partitioning loops until dependency vector is available for predicate generating instruction
US9389860B2 (en) 2012-04-02 2016-07-12 Apple Inc. Prediction optimizations for Macroscalar vector partitioning loops
US9348589B2 (en) 2013-03-19 2016-05-24 Apple Inc. Enhanced predicate registers having predicates corresponding to element widths
US9817663B2 (en) 2013-03-19 2017-11-14 Apple Inc. Enhanced Macroscalar predicate operations
JP7430173B2 (en) 2018-08-29 2024-02-09 アドバンスト・マイクロ・ディバイシズ・インコーポレイテッド branch trust throttle

Also Published As

Publication number Publication date
JP5387819B2 (en) 2014-01-15

Similar Documents

Publication Publication Date Title
JP5221546B2 (en) Method and apparatus for resolving simultaneously predicted branch instructions
JP5387819B2 (en) Reliability estimation circuit and method for branch prediction
JP7301955B2 (en) Promoting or Suppressing Loop Mode in Processors Using Loop End Prediction
JPH11282677A (en) Method for predicting branch instruction in microprocessor
US7844806B2 (en) Global history branch prediction updating responsive to taken branches
JP4009248B2 (en) Branch prediction apparatus and branch prediction method
JP2009528637A (en) Method and apparatus for repairing a link stack
WO2012127666A1 (en) Arithmetic processing device, information processing device, and arithmetic processing method
JP4213181B2 (en) Branch prediction apparatus, method thereof, and processor
KR20210084625A (en) Loop End Predictor
US20170039072A1 (en) Method for branch prediction
JP2008262437A (en) Processor system and exception handling method
KR100980076B1 (en) System and method for branch prediction with low-power consumption
CN112740175A (en) Load path history based branch prediction
JP2020119504A (en) Branch predictor
JP5209390B2 (en) Information processing apparatus and instruction fetch control method
CN113032011B (en) Method and system for executing cyclic program in data flow architecture
US20230108825A1 (en) Control of branch prediction for zero-overhead loop
US7849299B2 (en) Microprocessor system for simultaneously accessing multiple branch history table entries using a single port
JP2006040173A (en) Branch prediction device and method
US10324727B2 (en) Memory dependence prediction
JP4728877B2 (en) Microprocessor and pipeline control method
US20230350686A1 (en) Logic circuit and method for checking and updating program counter values in pipeline architecture
US20140281440A1 (en) Precalculating the direct branch partial target address during missprediction correction process
JP2009069960A (en) Branch prediction device, branch prediction method and microprocessor

Legal Events

Date Code Title Description
RD03 Notification of appointment of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7423

Effective date: 20100720

RD04 Notification of resignation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7424

Effective date: 20100720

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20110831

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20130419

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20130425

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20130621

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20130911

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20130924

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

LAPS Cancellation because of no payment of annual fees