Predicting a table of contents pointer value responsive to branching to a subroutine
First Claim
Patent Images
1. A computer-implemented method of facilitating processing within a computing environment, the computer-implemented method comprising:
- calling a subroutine from a calling module executing on a processor;
predicting, based on calling the subroutine, a value of a pointer to a reference data structure, the predicting being performed prior to executing a sequence of one or more instructions in the subroutine to compute the value of the pointer;
determining whether a current instruction in the subroutine corresponds to the sequence of one or more instructions to compute the value of the pointer;
inserting in the code, based on determining the current instruction corresponds to the sequence of one or more instructions to compute the value, a single check instruction to check the prediction of the value, the inserting replacing the sequence of one or more instructions, wherein instructions to compute the value of the pointer are replaced by the single check instruction; and
using the value that is predicted to access the reference data structure to obtain a variable value for a variable of the subroutine.
1 Assignment
0 Petitions
Accused Products
Abstract
Predicting a Table of Contents (TOC) pointer value responsive to branching to a subroutine. A subroutine is called from a calling module executing on a processor. Based on calling the subroutine, a value of a pointer to a reference data structure, such as a TOC, is predicted. The predicting is performed prior to executing a sequence of one or more instructions in the subroutine to compute the value. The value that is predicted is used to access the reference data structure to obtain a variable value for a variable of the subroutine.
174 Citations
10 Claims
-
1. A computer-implemented method of facilitating processing within a computing environment, the computer-implemented method comprising:
-
calling a subroutine from a calling module executing on a processor; predicting, based on calling the subroutine, a value of a pointer to a reference data structure, the predicting being performed prior to executing a sequence of one or more instructions in the subroutine to compute the value of the pointer; determining whether a current instruction in the subroutine corresponds to the sequence of one or more instructions to compute the value of the pointer; inserting in the code, based on determining the current instruction corresponds to the sequence of one or more instructions to compute the value, a single check instruction to check the prediction of the value, the inserting replacing the sequence of one or more instructions, wherein instructions to compute the value of the pointer are replaced by the single check instruction; and using the value that is predicted to access the reference data structure to obtain a variable value for a variable of the subroutine. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10)
-
Specification