IP Library Granted Patent US 10,318,304
Granted Patent B2
US 10,318,304 · App. 14/809,187 · Granted Jun 11, 2019

Conditional branch prediction using a long history

View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 10,318,304
App. No.
14/809,187
Granted
Jun 11, 2019
Kind
B2
Abstract

Methods and conditional branch predictors for predicting an outcome of a conditional branch instruction in a program executed by a processor using a long conditional branch history include generating a first index from a first portion of the conditional branch history and a second index from a second portion of the conditional branch history. The first index is then used to identify an entry in a first pattern history table including first prediction information; and the second index is used to identify an entry in a second pattern history table including second prediction information. The outcome of the conditional branch is predicted based on the first and second prediction information.

Claims (43)

1. A method of predicting an outcome of a conditional branch instruction in a program executed by a processor, the method comprising:

generating, at a first index generation module, a first index from a first portion of a conditional branch history, the conditional branch history comprising history information for a plurality of previously predicted conditional branch instructions, the first portion comprising a first subset of the history information in the conditional branch history;

identifying an entry in a first pattern history table using the first index, the entry in the first pattern history table comprising first prediction information determined as a function of the first subset of the history information in the conditional branch history, the first prediction information comprising a first prediction and information identifying a strength of the first prediction;

generating, at a second index generation module, a second index from a second portion of the conditional branch history, the second portion comprising a second subset of the history information in the conditional branch history, the second subset being different from the first subset;

identifying an entry in a second pattern history table using the second index, the entry in the second pattern history table comprising second prediction information determined as a function of the second subset of the history information in the conditional branch history, the second prediction information comprising a second prediction and information identifying a strength of the second prediction; and

predicting, using a decision logic unit, the outcome of the conditional branch instruction by selecting one of the first prediction and the second prediction as the predicted outcome based on the first and second prediction information.

2. A conditional branch predictor logic unit configured to predict an outcome of a conditional branch instruction in a program executed by a processor, the conditional branch predictor logic unit comprising:

a first index generation module configured to generate a first index from a first portion of a conditional branch history, the conditional branch history comprising history information for a plurality of previously predicted conditional branch instructions, the first portion comprising a first subset of the history information in the conditional branch history;

a second index generation module configured to generate a second index from a second portion of the conditional branch history, the second portion comprising a second subset of the history information in the conditional branch history, the second subset being different from the first subset; and

a decision logic unit configured to:

identify an entry in a first pattern history table using the first index, the entry in the first pattern history table comprising first prediction information determined as a function of the first subset of the history information in the conditional branch history, the first prediction information comprising a first prediction and information identifying a strength of the first prediction;

identify an entry in a second pattern history table using the second index, the entry in the second pattern history table comprising second prediction information determined as a function of the second subset of the history information in the conditional branch history, the second prediction information comprising a second prediction and information identifying a strength of the second prediction; and

predict the outcome of the conditional branch instruction by selecting one of the first prediction and the second prediction as the predicted outcome based on the first and second prediction information.

3. The conditional branch predictor logic unit of claim 2 , wherein the decision logic unit is further configured to select the first prediction as the predicted outcome when the information identifying the strength of the first prediction indicates the strength of the first prediction is greater than a predetermined threshold.

4. The conditional branch predictor logic unit of claim 2 , wherein the decision logic unit is further configured to select the first prediction as the predicted outcome when the information identifying the strength of the first prediction and the information identifying the strength of the second prediction indicate the first prediction is stronger than the second prediction.

5. The conditional branch predictor logic unit of claim 2 , wherein the decision logic unit is further configured to store a snapshot of the conditional branch history and an indication of which of the first and second predictions was selected as the predicted outcome in association with information identifying the conditional branch instruction.

6. The conditional branch predictor logic unit of claim 5 , wherein the decision logic unit is further configured to store the snapshot of the conditional branch history and the indication of which of the first and second predictions was selected as the predicted outcome in a re-order buffer.

7. The conditional branch predictor logic unit of claim 5 , further comprising an update logic unit configured to:

receive information identifying an executed conditional branch instruction and information indicating whether the executed conditional branch was taken; and

update at least one of the first pattern history table and the second pattern history table based on the information identifying the executed conditional branch instruction and the information indicating whether the executed conditional branch was taken.

8. The conditional branch predictor logic unit of claim 7 , wherein the update logic unit is further configured to: in response to receiving the information identifying the executed conditional branch instruction, obtain the snapshot of the conditional branch history and the indication of which of the first and second predictions was selected as the predicted outcome associated with the executed conditional branch instruction.

9. The conditional branch predictor logic unit of claim 8 , wherein the update logic unit is further configured to update at least one of the first pattern history table and the second pattern history table by:

generating a third index from a first portion of the snapshot of the conditional branch history;

identifying an entry in the first pattern history table using the third index, the entry in the first pattern history table comprising third prediction information;

updating the third prediction information of the entry in the first pattern history table based on the information indicating whether the executed conditional branch was taken;

generating a fourth index from a second portion of the snapshot of the conditional branch history;

identifying an entry in the second pattern history table using the fourth index, the entry in the second pattern history table comprising fourth prediction information; and

updating the fourth prediction information of the entry in the second pattern history table based on the information indicating whether the executed conditional branch was taken.

10. The conditional branch predictor logic unit of claim 9 , wherein the update logic unit is further configured to analyze the indication of which of the first and second predictions was selected as the predicted outcome to determine which of the first and second predictions was selected as the predicted outcome; in response to determining that the first prediction was selected as the predicted outcome, only update the first pattern history table; and in response to determining that the second prediction was selected as the predicted outcome, only update the second pattern history table.

11. The conditional branch predictor logic unit of claim 9 , wherein each of the third prediction information and the fourth prediction information comprises a saturating counter and the update logic unit is further configured to update prediction information in a pattern history table by incrementing the saturating counter if the information indicating whether the executed conditional branch was taken indicates the branch was taken, and decrementing the saturating counter if the information indicating whether the executed conditional branch was taken indicates the branch was not taken.

12. The conditional branch predictor logic unit of claim 2 , wherein the first subset of history information comprises more information than the second subset of history information.

13. The conditional branch predictor logic unit of claim 2 , wherein each of the first subset of history information and the second subset of history information comprises a contiguous set of information.

14. The conditional branch predictor logic unit of claim 2 , wherein the first index generation module is configured to generate the first index by combining the first portion of the conditional branch history and an address of the conditional branch instruction.

15. The conditional branch predictor logic unit of claim 14 , wherein the first index generation module is configured to combine the first portion of the conditional branch history and the address of the conditional branch instruction by performing a hashing function on the first portion of the conditional branch history and at least a portion of the address of the conditional branch instruction.

16. The conditional branch predictor logic unit of claim 2 , wherein the second index generation module is configured to generate the second index by combining the second portion of the conditional branch history and an address of the conditional branch instruction.

17. The conditional branch predictor logic unit of claim 16 , wherein the second index generation module is configured to combine the second portion of the conditional branch history and the address of the conditional branch instruction by performing a hashing function on the second portion of the conditional branch history and at least a portion of the address of the conditional branch instruction.

18. A processor including a conditional branch predictor logic unit configured to predict an outcome of a conditional branch instruction in a program executed by the processor, the conditional branch predictor logic unit comprising:

a first index generation module configured to generate a first index from a first portion of a conditional branch history, the conditional branch history comprising history information for a plurality of previously predicted conditional branch instructions, the first portion comprising a first subset of the history information in the conditional branch history;

a second index generation module configured to generate a second index from a second portion of the conditional branch history, the second portion comprising a second subset of the history information in the conditional branch history, the second subset being different from the first subset; and

a decision logic unit configured to:

identify an entry in a first pattern history table using the first index, the entry in the first pattern history table comprising first prediction information determined as a function of the first subset of the history information in the conditional branch history, the first prediction information comprising a first prediction and information identifying a strength of the first prediction;

identify an entry in a second pattern history table using the second index, the entry in the second pattern history table comprising second prediction information determined as a function of the second subset of the history information in the conditional branch history, the second prediction information comprising a second prediction and information identifying a strength of the second prediction; and

predict the outcome of the conditional branch instruction by selecting one of the first prediction and the second prediction as the predicted outcome based on the first and second prediction information.

Assignments (8)
RELEASE OF SECURITY INTEREST Recorded Dec 29, 2022
From: CAPITAL FINANCE ADMINISTRATION, LLC, AS ADMINISTRATIVE AGENT
To: MIPS TECH, LLC; WAVE COMPUTING INC.
Reel/Frame 062251/0251 →
SECURITY INTEREST Recorded Jun 14, 2021
From: MIPS TECH, LLC; WAVE COMPUTING, INC.
To: CAPITAL FINANCE ADMINISTRATION, LLC
Reel/Frame 056558/0903 →
RELEASE OF SECURITY INTEREST Recorded Jun 14, 2021
From: WAVE COMPUTING LIQUIDATING TRUST
To: MIPS TECH, INC.; HELLOSOFT, INC.; WAVE COMPUTING (UK) LIMITED; IMAGINATION TECHNOLOGIES, INC.; CAUSTIC GRAPHICS, INC.; MIPS TECH, LLC; WAVE COMPUTING, INC.
Reel/Frame 056589/0606 →
SECURITY INTEREST Recorded Feb 26, 2021
From: WAVE COMPUTING, INC.; MIPS TECH, LLC; MIPS TECH, INC.; HELLOSOFT, INC.; WAVE COMPUTING (UK) LIMITED; IMAGINATION TECHNOLOGIES, INC.; CAUSTIC GRAPHICS, INC.
To: WAVE COMPUTING LIQUIDATING TRUST
Reel/Frame 055429/0532 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Apr 19, 2018
From: MIPS TECH LIMITED
To: MIPS TECH, LLC
Reel/Frame 045593/0166 →
CHANGE OF NAME Recorded Jan 26, 2018
From: HELLOSOFT LIMITED
To: MIPS TECH LIMITED
Reel/Frame 045168/0922 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jan 24, 2018
From: IMAGINATION TECHNOLOGIES LIMITED
To: HELLOSOFT LIMITED
Reel/Frame 045136/0975 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jul 25, 2015
From: MANOUKIAN, MANOUK VARTAN
To: IMAGINATION TECHNOLOGIES LIMITED
Reel/Frame 036178/0919 →