IP Library Granted Patent US 10,261,798
Granted Patent B2
US 10,261,798 · App. 15/707,059 · Granted Apr 16, 2019

Indirect branch prediction

Inventor: Manouk Manoukian (Hemel Hempstead, GB)
Assignee: MIPS Tech, LLC
G06F9/3844G06F9/3806G06F9/3848
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,261,798
App. No.
15/707,059
Granted
Apr 16, 2019
Kind
B2
Abstract

Methods and indirect branch predictor logic units to predict the target addresses of indirect branch instructions. The method comprises storing in a table predicted target addresses for indirect branch instructions indexed by a combination of the indirect path history for previous indirect branch instructions and the taken/not-taken history for previous conditional branch instructions. When a new indirect branch instruction is received for prediction, the indirect path history and the taken/not-taken history are combined to generate an index for the indirect branch instruction. The generated index is then used to identify a predicted target address in the table. If the identified predicted target address is valid, then the target address of the indirect branch instruction is predicted to be the predicted target address.

Claims (61)

1. A method to update an indirect branch predicted target table used by a processor, the method comprising:

storing in an indirect branch predicted target table a plurality of predicted target addresses for indirect branch instructions;

receiving, at an update logic unit, information related to an executed indirect branch instruction, the information related to the executed indirect branch instruction comprising an actual target address for the executed indirect branch instruction and an address of the executed indirect branch instruction;

obtaining at the update logic unit a committed indirect path history and a committed taken and not-taken history, the committed indirect path history comprising at least a portion of actual target addresses for a plurality of previously executed indirect branch instructions, the committed taken and not-taken history comprising outcomes for a plurality of previously executed conditional branch instructions;

combining at the update logic unit the committed indirect path history and the committed taken and not-taken history to generate an index for the executed indirect branch instruction, wherein the combining comprises amending one of the committed indirect path history and the committed taken and not-taken history to comprise at least a portion of the address of the executed indirect branch instruction;

identifying a predicted target address of the indirect branch predicted target table using the index for the executed indirect branch instruction; and

replacing the predicted target address identified by the index for the executed indirect branch instruction with the actual target address for the executed indirect branch instruction.

2. The method according to claim 1 , wherein combining the committed indirect path history and the committed taken and not-taken history comprises performing a hashing function on at least a portion of the committed indirect path history and at least a portion of the committed taken and not-taken history.

3. The method according to claim 2 , wherein the hashing function is an exclusive-OR function.

4. The method according to claim 1 , wherein generating the index for the executed indirect branch instruction comprises combining only the committed indirect path history and the committed taken and not-taken history.

5. The method according to claim 1 , further comprising:

receiving at an index generator information identifying an indirect branch instruction to be executed;

obtaining at the index generator a running indirect path history and a running taken and not-taken history, the running indirect path history comprising at least a portion of predicted target addresses for a plurality of previously predicted indirect branch instructions, the running taken and not-taken history comprising outcomes for a plurality of previously predicted conditional branch instructions;

combining at the index generator the running indirect path history and the running taken and not-taken history to generate an index for the indirect branch instruction to be executed;

identifying a predicted target address in the indirect branch predicted target table using the index for the identified indirect branch instruction;

in response to determining the identified predicted target address is valid, predicting the target address of the indirect branch instruction to be executed to be the identified predicted target address.

6. The method according to claim 5 , further comprising in response to determining the identified predicted target address is not valid, stalling a fetch stage of the processor.

7. The method according to claim 5 , further comprising:

comparing, at the update logic unit, the actual target address for the executed indirect branch instruction to a predicted target address for the executed indirect branch instruction; and

in response to determining the actual target address and the predicted target address for the executed indirect branch instruction do not match, replacing the running indirect branch history with the committed indirect path history.

8. The method according to claim 5 , further comprising:

receiving, at a conditional branch predictor, information related to an executed conditional branch instruction, the information related to the executed conditional branch instruction comprising an actual outcome for the executed conditional branch instruction;

comparing, at the conditional branch predictor, the actual outcome for the executed conditional branch instruction to a predicted outcome for the executed conditional branch instruction; and

in response to determining the actual outcome and the predicted outcome for the executed indirect branch instruction do not match,

replacing the running taken and not-taken history with the committed taken and not-taken history.

9. An indirect branch predictor logic unit to update an indirect branch predicted target table used by a processor, the indirect branch predictor logic unit comprising:

an indirect branch predicted target table configured to store a plurality of predicted target addresses for indirect branch instructions;

an update logic unit in communication with the indirect branch predicted target table, the update logic unit configured to:

receive information related to an executed indirect branch instruction, the information related to the executed indirect branch instruction comprising an actual target address for the executed indirect branch instruction and an address of the executed indirect branch instruction;

obtain a committed indirect path history and a committed taken and not-taken history, the committed indirect path history comprising at least a portion of actual target addresses for a plurality of previously executed indirect branch instructions, the committed taken and not-taken history comprising outcomes for a plurality of previously executed conditional branch instructions;

combine the committed indirect path history and the committed taken and not-taken history to generate an index for the executed indirect branch instruction, wherein the combining comprises amending one of the committed indirect path history and the committed taken and not-taken history to comprise at least a portion of the address of the executed indirect branch instruction;

identify a predicted target address of the indirect branch predicted target table using the index for the executed indirect branch instruction; and

replace the predicted target address identified by the index for the executed indirect branch instruction with the actual target address for the executed indirect branch instruction.

10. The indirect branch predictor logic unit according to claim 9 , wherein combining the committed indirect path history and the committed taken and not-taken history comprises performing a hashing function on a least a portion of the committed indirect path history and at least a portion of the committed taken and not-taken history.

11. The indirect branch predictor logic unit according to claim 10 , wherein the hashing function is an exclusive-OR function.

12. The indirect branch predictor logic unit according to claim 9 , wherein the update logic unit is configured to generate the index for the executed indirect branch instruction by combining only the committed indirect path history and the committed taken and not-taken history.

13. The indirect branch predictor logic unit of claim 9 further comprising:

an index generator in communication with the indirect branch predicted target table, the index generator configured to:

receive information identifying an indirect branch instruction to be executed;

obtain a running indirect path history and a running taken and not-taken history, the running indirect path history comprising at least a portion of predicted target addresses for a plurality of previously predicted indirect branch instructions, the running taken and not-taken history comprising outcomes for a plurality of previously predicted conditional branch instructions; and

combine the running indirect path history and the running taken and not-taken history to generate an index for the indirect branch instruction to be executed; and

a decision logic unit in communication with the indirect branch predicted target table, the decision logic unit configured to:

identify a predicted target address of the indirect branch predicted target table using the index for the indirect branch instruction to be executed; and

in response to determining the predicted target address is valid, predict the target address of the indirect branch instruction to be executed to be the identified predicted target address.

14. The indirect branch predictor logic unit according to claim 13 , wherein the decision logic unit is further configured to, in response to determining the identified predicted target address is not valid, stall a fetch stage of the processor.

15. The indirect branch predictor logic unit according to claim 13 , wherein the update logic unit is further configured to:

compare the actual target address for the executed indirect branch instruction to a predicted target address for the executed indirect branch instruction; and

in response to determining the actual target address and the predicted target address for the executed indirect branch instruction do not match, replace the running indirect branch history with the committed indirect path history.

16. A processor comprising the indirect branch predictor logic unit according to claim 13 .

17. The processor of claim 16 , further comprising a conditional branch predictor configured to:

receive information related to an executed conditional branch instruction, the information related to the executed conditional branch instruction comprising an actual outcome for the executed conditional branch instruction;

compare the actual outcome for the executed conditional branch instruction to a predicted outcome for the executed conditional branch instruction; and

in response to determining the actual outcome and the predicted outcome for the executed conditional branch instruction do not match, replace the running taken and not-taken history with the committed taken and not-taken history.

18. A non-transitory computer readable storage medium having stored thereon computer readable program code for generating a processor comprising an indirect branch predictor logic unit to update an indirect branch predicted target table used by the processor, the indirect branch predictor logic unit comprising:

an indirect branch predicted target table configured to store a plurality of predicted target addresses for indirect branch instructions;

an update logic unit in communication with the indirect branch predicted target table, the update logic unit configured to:

receive information related to an executed indirect branch instruction, the information related to the executed indirect branch instruction comprising an actual target address for the executed indirect branch instruction and an address of the executed indirect branch instruction;

obtain a committed indirect path history and a committed taken and not-taken history, the committed indirect path history comprising at least a portion of actual target addresses for a plurality of previously executed indirect branch instructions, the committed taken and not-taken history comprising outcomes for a plurality of previously executed conditional branch instructions;

combine the committed indirect path history and the committed taken and not-taken history to generate an index for the executed indirect branch instruction, wherein the combining comprises amending one of the committed indirect path history and the committed taken and not-taken history to comprise at least a portion of the address of the executed indirect branch instruction;

identify a predicted target address of the indirect branch predicted target table using the index for the executed indirect branch instruction; and

replace the predicted target address identified by the index for the executed indirect branch instruction with the actual target address for the executed indirect branch instruction.

Assignments (7)
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 →
Priority Claims (1)
GB 1304504.2 · Mar 13, 2013 · national
Continuity (2)
Continuation 14169771 · Jan 31, 2014
Related Publication 20180004529A1 · Jan 4, 2018