IP Library Patent Application 14256020
Patent Application
App. No. 14/256,020

SYSTEMS AND METHODS FOR MANAGING BRANCH TARGET BUFFERS IN A MULTI-THREADED DATA PROCESSING SYSTEM

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 None
App. No.
14/256,020
Abstract

A data processing system includes a processor configured to execute processor instructions of a first thread and processor instructions of a second thread, a first branch target buffer (BTB) corresponding to the first thread, a second BTB corresponding to the second thread, storage circuitry configured to store a borrow enable indicator corresponding to the first thread which indicates whether borrowing is enabled for the first thread, and control circuitry configured to allocate an entry for a branch instruction executed within the first thread in the first branch target buffer but not the second branch target buffer if borrowing is not enabled by the borrow enable indicator and in the first branch target buffer or the second branch target buffer if borrowing is enabled by the borrow enable indicator and the second thread is not enabled.

Claims (38)

1 . A data processing system, comprising:

a processor configured to execute processor instructions of a first thread and processor instructions of a second thread;

a first branch target buffer corresponding to the first thread, the first branch target buffer having a plurality of entries, each entry configured to store a branch instruction address and a corresponding branch target address;

a second branch target buffer corresponding to the second thread, the second branch target buffer having a plurality of entries, each entry configured to store a branch instruction address and a corresponding branch target address;

storage circuitry configured to store a borrow enable indicator corresponding to the second branch target buffer which indicates whether borrowing from the second branch target buffer is enabled; and

control circuitry configured to allocate an entry for a branch instruction executed within the first thread in the first branch target buffer but not the second branch target buffer if borrowing is not enabled by the borrow enable indicator and in the first branch target buffer or the second branch target buffer if borrowing is enabled by the borrow enable indicator and the second thread is not enabled.

2 . The data processing system of claim 1 , wherein, if borrowing is enabled by the borrow enable indicator and the second thread is not enabled, the control circuitry is configured to allocate an entry for the branch instruction in the first branch target buffer if the first branch target buffer is less than a predetermined fullness level.

3 . The data processing system of claim 1 , wherein, if borrowing is enabled by the borrow enable indicator and the second thread is not enabled, the control circuitry is configured to allocate an entry for the branch instruction in the second branch target buffer.

4 . The data processing system of claim 1 , wherein, if borrowing is enabled by the borrow enable indicator and the second thread is not enabled, the control circuitry is configured to allocate an entry for the branch instruction in the second branch target buffer if the first branch target buffer is at least at a predetermined fullness level.

5 . The data processing system of claim 1 , wherein the control circuitry is further configured to allocate an entry for the branch instruction only in the first branch target buffer if borrowing is enabled by the borrow enable indicator and the second thread is enabled.

6 . The data processing system of claim 1 , further comprising a thread control unit configured to select an enabled thread from the first thread and the second thread for execution by the processor, wherein when the first thread is disabled, the thread control unit cannot select the first thread for execution and when the second thread is disabled, the thread control unit cannot select the second thread for execution.

7 . The data processing system of claim 1 , wherein the control circuitry is further configured to receive branch instruction addresses from the processor, and for each branch instruction address, determine whether the branch instruction hits or misses in each of the first and the second branch target buffer.

8 . The data processing system of claim 7 , wherein the control circuitry is further configured to, when the branch instruction hits an entry in only one of the first or the second branch target buffer, provide the branch target address from the entry which resulted in the hit to the processor if the entry indicates a branch taken prediction.

9 . The data processing system of claim 7 , wherein the control circuitry is further configured to, when the branch instruction hits an entry in the first branch target buffer and hits an entry in the second branch target buffer, determine which of the first or the second thread is currently executing on the processor and to provide the branch target address to the processor from the entry of the branch target buffer which corresponds to the currently executing thread if that entry indicates a branch taken prediction.

10 . The data processing system of claim 1 , wherein the borrow enable indicator indicates whether borrowing is enabled for the first thread from the second branch target buffer.

11 . The data processing system of claim 10 , wherein the storage circuitry is further configured to store a second borrow enable indicator corresponding to the first branch target buffer which indicates whether borrowing is enabled for the second thread from the first branch target buffer.

12 . The data processing system of claim 1 , wherein the branch instruction executed in the first thread corresponds to a branch instruction resolved as a taken branch by the processor.

13 . In a data processing system configured to execute processor instructions of a first thread and processor instructions of a second thread and having a first branch target buffer corresponding to the first thread and a second branch target buffer corresponding to the second thread, a method comprises:

receiving a branch instruction address corresponding to branch instruction being executed in the first thread;

when the second thread is disabled and borrowing from the second branch target buffer is enabled, determining whether to allocate an entry for the branch instruction in the first branch target buffer or the second branch target buffer; and

when borrowing from the second branch target buffer is not enabled, allocating an entry for the branch instruction in the first branch target buffer and not in the second branch target buffer.

14 . The method of claim 13 , wherein when the second thread is disabled and borrowing from the second branch target buffer is enabled, the determining whether to allocate an entry for the first branch instruction address in the first branch target buffer or the second branch target buffer is based on fullness level of the first branch target buffer.

15 . The method of claim 14 , wherein when the second thread is disabled and borrowing from the second branch target buffer is enabled, allocating an entry for the first branch instruction address in the first branch target buffer if the first branch target buffer is less than a predetermined fullness level and allocating an entry for the first branch instruction address in the second branch target buffer if the first branch target buffer is at least at the predetermined fullness level.

16 . The method of claim 13 , wherein prior to the determining and the allocating, the method further comprises:

performing a hit determination for the branch instruction address in the first branch target buffer and the second branch target buffer;

in response to a hit of an entry in only one of the first or the second branch target buffer, providing the branch target address from the entry which resulted in the hit if the entry indicates a branch taken prediction; and

in response to a hit of an entry in each of the first and the second branch target buffer, determining which of the first or the second thread is currently executing and providing the branch target entry from the entry of the branch target buffer which corresponds to the currently executing thread if that entry indicates a branch taken prediction.

17 . The method of claim 16 , further comprising receiving a thread identifier, wherein the determining which of the first or the second thread is currently executing is performed based on the thread identifier.

18 . The method of claim 13 , wherein prior to the determining and the allocating, the method further comprises:

determining that the branch instruction misses in each of the first branch target buffer and the second branch target buffer; and

resolving the branch instruction as a taken branch instruction.

19 . In a data processing system configured to execute processor instructions of a first thread and processor instructions of a second thread and having a first branch target buffer corresponding to the first thread and a second branch target buffer corresponding to the second thread, a method comprises:

receiving a branch instruction address corresponding to branch instruction being executed in the first thread;

when the second thread is disabled and borrowing from the second branch target buffer is enabled, allocating an entry for the branch instruction in the first branch target buffer if the first branch target buffer is less than a predetermined fullness level and allocating an entry for the branch instruction in the second branch target buffer if the first branch target buffer is at least at the predetermined fullness level; and

when borrowing from the second branch target buffer is not enabled, allocating an entry for the branch instruction in the first branch target buffer.

20 . The method of claim 19 , wherein prior to the allocating, the method further comprises:

determining that the branch instruction misses in each of the first branch target buffer and the second branch target buffer; and

resolving the branch instruction as a taken branch instruction.

Assignments (17)
CORRECTIVE ASSIGNMENT TO CORRECT THE REMOVE APPLICATION 11759915 AND REPLACE IT WITH APPLICATION 11759935 PREVIOUSLY RECORDED ON REEL 040925 FRAME 0001. ASSIGNOR(S) HEREBY CONFIRMS THE RELEASE OF SECURITY INTEREST. Recorded Feb 17, 2020
From: MORGAN STANLEY SENIOR FUNDING, INC.
To: NXP, B.V. F/K/A FREESCALE SEMICONDUCTOR, INC.
Reel/Frame 052917/0001 →
CORRECTIVE ASSIGNMENT TO CORRECT THE REMOVE APPLICATION 11759915 AND REPLACE IT WITH APPLICATION 11759935 PREVIOUSLY RECORDED ON REEL 040928 FRAME 0001. ASSIGNOR(S) HEREBY CONFIRMS THE RELEASE OF SECURITY INTEREST. Recorded Jan 17, 2020
From: MORGAN STANLEY SENIOR FUNDING, INC.
To: NXP B.V.
Reel/Frame 052915/0001 →
RELEASE OF SECURITY INTEREST Recorded Sep 10, 2019
From: MORGAN STANLEY SENIOR FUNDING, INC.
To: NXP B.V.
Reel/Frame 050744/0097 →
CORRECTIVE ASSIGNMENT TO CORRECT THE NATURE OF CONVEYANCE PREVIOUSLY RECORDED AT REEL: 040626 FRAME: 0683. ASSIGNOR(S) HEREBY CONFIRMS THE MERGER AND CHANGE OF NAME EFFECTIVE NOVEMBER 7, 2016. Recorded Jan 12, 2017
From: NXP SEMICONDUCTORS USA, INC. (MERGED INTO); FREESCALE SEMICONDUCTOR, INC. (UNDER)
To: NXP USA, INC.
Reel/Frame 041414/0883 →
CHANGE OF NAME Recorded Nov 16, 2016
From: FREESCALE SEMICONDUCTOR INC.
To: NXP USA, INC.
Reel/Frame 040626/0683 →
RELEASE OF SECURITY INTEREST Recorded Nov 7, 2016
From: MORGAN STANLEY SENIOR FUNDING, INC.
To: NXP B.V.
Reel/Frame 040928/0001 →
RELEASE OF SECURITY INTEREST Recorded Sep 21, 2016
From: MORGAN STANLEY SENIOR FUNDING, INC.
To: NXP, B.V., F/K/A FREESCALE SEMICONDUCTOR, INC.
Reel/Frame 040925/0001 →
CORRECTIVE ASSIGNMENT TO CORRECT THE REMOVE APPLICATION 14/258,829 AND REPLACE ITWITH 14/258,629 PREVIOUSLY RECORDED ON REEL 037444 FRAME 0082. ASSIGNOR(S) HEREBY CONFIRMS THE ASSIGNMENT AND ASSUMPTION OFSECURITY INTEREST IN PATENTS. Recorded Aug 10, 2016
From: CITIBANK, N.A.
To: MORGAN STANLEY SENIOR FUNDING, INC.
Reel/Frame 039639/0332 →
CORRECTIVE ASSIGNMENT OF INCORRECT APPLICATION 14/258,829 PREVIOUSLY RECORDED ON REEL 037444 FRAME 0109. ASSIGNOR(S) HEREBY CONFIRMS THE ASSIGNMENT AND ASSUMPTION OF SECURITY INTEREST IN PATENTS. Recorded Aug 10, 2016
From: CITIBANK, N.A.
To: MORGAN STANLEY SENIOR FUNDING, INC.
Reel/Frame 039639/0208 →
SUPPLEMENT TO THE SECURITY AGREEMENT Recorded Jun 16, 2016
From: FREESCALE SEMICONDUCTOR, INC.
To: MORGAN STANLEY SENIOR FUNDING, INC.
Reel/Frame 039138/0001 →
ASSIGNMENT AND ASSUMPTION OF SECURITY INTEREST IN PATENTS Recorded Jan 5, 2016
From: CITIBANK, N.A.
To: MORGAN STANLEY SENIOR FUNDING, INC.
Reel/Frame 037444/0109 →
ASSIGNMENT AND ASSUMPTION OF SECURITY INTEREST IN PATENTS Recorded Jan 5, 2016
From: CITIBANK, N.A.
To: MORGAN STANLEY SENIOR FUNDING, INC.
Reel/Frame 037444/0082 →
PATENT RELEASE Recorded Dec 21, 2015
From: CITIBANK, N.A., AS COLLATERAL AGENT
To: FREESCALE SEMICONDUCTOR, INC.
Reel/Frame 037357/0903 →
SUPPLEMENT TO IP SECURITY AGREEMENT Recorded Aug 1, 2014
From: FREESCALE SEMICONDUCTOR, INC.
To: CITIBANK, N.A., AS NOTES COLLATERAL AGENT
Reel/Frame 033460/0337 →
SUPPLEMENT TO IP SECURITY AGREEMENT Recorded Aug 1, 2014
From: FREESCALE SEMICONDUCTOR, INC.
To: CITIBANK, N.A., AS NOTES COLLATERAL AGENT
Reel/Frame 033462/0293 →
SUPPLEMENT TO IP SECURITY AGREEMENT Recorded Aug 1, 2014
From: FREESCALE SEMICONDUCTOR, INC.
To: CITIBANK, N.A., AS NOTES COLLATERAL AGENT
Reel/Frame 033462/0267 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Apr 18, 2014
From: SCOTT, JEFFREY W.; MOYER, WILLIAM C.; ROBERTSON, ALISTAIR P.
To: FREESCALE SEMICONDUCTOR, INC.
Reel/Frame 032706/0017 →