IP Library › Granted Patent US 10,896,030
Granted Patent B2
US 10,896,030 · App. 15/708,199 · Granted Jan 19, 2021

Code generation relating to providing table of contents pointer values

Inventors: Michael K. Gschwind (Chappaqua, NY); Valentina Salapura (Chappaqua, NY)
Assignee: INTERNATIONAL BUSINESS MACHINES CORPORATION
G06F8/434
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,896,030
App. No.
15/708,199
Granted
Jan 19, 2021
Kind
B2
Abstract

Code generation relating to providing table of contents (TOC) pointer values. Code to be compiled is obtained by a processor. Based on obtaining the code, a determination is made as to whether the code is to access a reference data structure. Based on determining the code is to access the reference data structure, other code is included in the code to provide a pointer to the reference data structure. The other code includes an architectural definition to provide the pointer to the reference data structure.

Claims (40)

1. A computer program product for facilitating processing within a computing environment, the computer program product comprising:

at least one computer readable storage medium readable by at least one processing circuit and storing instructions for performing a method comprising:

obtaining, by a processor, code to be decoded;

determining, based on obtaining the code, whether the code accesses a reference data structure; and

including within the code, based on determining the code accesses the reference data structure, other code providing a pointer to the reference data structure, the other code including an architectural definition providing the pointer to the reference data structure, wherein the other code comprises a set register instruction that loads a defined register with a value of the pointer to the reference data structure, the set register instruction comprising an operation code indicating the set register operation and a field used to specify the defined register that is loaded with the value of the pointer, and wherein the including, within the code, the other code providing the pointer to the reference data structure comprises:

scanning the code for an instruction sequence to compute the value of the pointer to the reference data structure and to place the value that is computed in the defined register; and

replacing the instruction sequence with the set register instruction such that the set register instruction is used to load the defined register with the value of the pointer to the reference data structure instead of computing the value using the instruction sequence.

2. The computer program product of claim 1 , wherein the set register instruction loads the defined register specified using the field of the set register instruction with the value of the pointer to the reference data structure for a code sequence, wherein the code sequence corresponds to code following an address of the set register instruction.

3. The computer program product of claim 2 , wherein based on executing the set register instruction a look-up of a data structure is performed to determine the value of the pointer.

4. The computer program product of claim 3 , wherein the data structure comprises a reference data structure pointer cache.

5. The computer program product of claim 3 , wherein the data structure comprises a table populated with reference data structure pointer values.

6. The computer program product of claim 1 , wherein the method further comprises:

determining that a reference data structure pointer register is to be reinitialized with another pointer; and

reinitializing the reference data structure pointer register with the other pointer using the other code.

7. The computer program product of claim 6 , wherein the reinitializing is performed absent saving the other pointer on a stack and reloading the other pointer from the stack.

8. A computer system for facilitating processing within a computing environment, the computer system comprising:

a memory; and

a processor in communication with the memory, wherein the computer system is configured to perform a method, said method comprising:

obtaining, by a processor, code to be decoded;

determining, based on obtaining the code, whether the code accesses a reference data structure; and

including within the code, based on determining the code accesses the reference data structure, other code providing a pointer to the reference data structure, the other code including an architectural definition providing the pointer to the reference data structure, wherein the other code comprises a set register instruction that loads a defined register with a value of the pointer to the reference data structure, the set register instruction comprising an operation code indicating the set register operation and a field used to specify the defined register that is loaded with the value of the pointer, and wherein the including, within the code, the other code providing the pointer to the reference data structure comprises:

scanning the code for an instruction sequence to compute the value of the pointer to the reference data structure and to place the value that is computed in the defined register; and

replacing the instruction sequence with the set register instruction such that the set register instruction is used to load the defined register with the value of the pointer to the reference data structure instead of computing the value using the instruction sequence.

9. The computer system of claim 8 , wherein the set register instruction loads the defined register specified using the field of the set register instruction with the value of the pointer to the reference data structure for a code sequence, wherein the code sequence corresponds to code following an address of the set register instruction.

10. The computer system of claim 9 , wherein based on executing the set register instruction a look-up of a data structure is performed to determine the value of the pointer.

11. The computer system of claim 10 , wherein the data structure comprises a reference data structure pointer cache.

12. The computer system of claim 10 , wherein the data structure comprises a table populated with reference data structure pointer values.

13. The computer system of claim 8 , wherein the method further comprises:

determining that a reference data structure pointer register is to be reinitialized with another pointer; and

reinitializing the reference data structure pointer register with the other pointer using the other code.

14. The computer system of claim 13 , wherein the reinitializing is performed absent saving the other pointer on a stack and reloading the other pointer from the stack.

15. A computer program product for facilitating processing within a computing environment, the computer program product comprising:

at least one computer readable storage medium readable by at least one processing circuit and storing instructions for performing a method comprising:

obtaining, by a processor, code to be decoded;

determining, based on obtaining the code, whether the code accesses a reference data structure; and

including within the code, based on determining the code accesses the reference data structure, other code to provide a pointer to the reference data structure, the other code including an architectural definition providing the pointer to the reference data structure in a defined register, and wherein the other code provides the pointer by performing a look-up of a value for the pointer, as defined by the architectural definition, and wherein the including, within the code, the other code to provide the pointer to the reference data structure comprises:

scanning the code for an instruction sequence to compute the value of the pointer to the reference data structure and to place the value that is computed in the defined register; and

replacing the instruction sequence with the architectural definition such that the architectural definition is used to load the defined register with the value of the pointer to the reference data structure instead of computing the value using the instruction sequence.

16. The computer program product of claim 15 , wherein the other code comprises an operation to use a virtual register to obtain the value for the pointer.

17. The computer program product of claim 15 , wherein the other code comprises a set register instruction to load the defined register with the value of the pointer to the reference data structure.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Sep 19, 2017
From: GSCHWIND, MICHAEL K.; SALAPURA, VALENTINA
To: INTERNATIONAL BUSINESS MACHINES CORPORATION
Reel/Frame 043622/0382 →
Continuity (1)
Related Publication 20190087162A1 · Mar 21, 2019