Run-time instrumentation sampling in transactional-execution mode
First Claim
1. A computer implemented method for implementing run-time instrumentation sampling in transactional-execution mode, the method comprising:
- determining, by a processor, that the processor is configured to execute instructions of an instruction stream in a transactional-execution mode, the instructions defining a transaction;
interlocking completion of storage operations of the instructions to prevent instruction-directed storage until completion of the transaction;
collecting run-time instrumentation events in a collection buffer while in the transactional-execution mode, the collection buffer located within the processor, wherein the run-time instrumentation events are events recognized by the processor during execution of the instructions;
recognizing a sample point during execution of the instructions while in the transactional-execution mode, the sample point corresponding to an instruction executed inside of the transaction;
run-time-instrumentation-directed storing, upon successful completion of the transaction, run-time instrumentation information obtained at the sample point; and
performing the run-time-instrumentation-directed storing as a non-transactional store of a reporting group based on the run-time instrumentation events in the collection buffer to a run-time instrumentation program buffer in a main memory.
1 Assignment
0 Petitions
Accused Products
Abstract
Embodiments of the invention relate to implementing run-time instrumentation sampling in transactional-execution mode. An aspect of the invention includes a method for implementing run-time instrumentation sampling in transactional-execution mode. The method includes determining, by a processor, that the processor is configured to execute instructions of an instruction stream in a transactional-execution mode, the instructions defining a transaction. The method also includes interlocking completion of storage operations of the instructions to prevent instruction-directed storage until completion of the transaction. The method further includes recognizing a sample point during execution of the instructions while in the transactional-execution mode. The method additionally includes run-time-instrumentation-directed storing, upon successful completion of the transaction, run-time instrumentation information obtained at the sample point.
137 Citations
8 Claims
-
1. A computer implemented method for implementing run-time instrumentation sampling in transactional-execution mode, the method comprising:
-
determining, by a processor, that the processor is configured to execute instructions of an instruction stream in a transactional-execution mode, the instructions defining a transaction; interlocking completion of storage operations of the instructions to prevent instruction-directed storage until completion of the transaction; collecting run-time instrumentation events in a collection buffer while in the transactional-execution mode, the collection buffer located within the processor, wherein the run-time instrumentation events are events recognized by the processor during execution of the instructions; recognizing a sample point during execution of the instructions while in the transactional-execution mode, the sample point corresponding to an instruction executed inside of the transaction; run-time-instrumentation-directed storing, upon successful completion of the transaction, run-time instrumentation information obtained at the sample point; and performing the run-time-instrumentation-directed storing as a non-transactional store of a reporting group based on the run-time instrumentation events in the collection buffer to a run-time instrumentation program buffer in a main memory. - View Dependent Claims (2, 3, 4, 6, 7, 8)
-
-
5. A computer implemented method for implementing run-time instrumentation sampling in transactional-execution mode, the method comprising:
-
determining, by a processor, that the processor is configured to execute instructions of an instruction stream in a transactional-execution mode, the instructions defining a transaction; storing a copy of a program buffer current address pointing to a current location in a run-time instrumentation program buffer upon a transition from a non-transactional-execution mode to the transactional-execution mode; interlocking completion of storage operations of the instructions to prevent instruction-directed storage until completion of the transaction; recognizing a sample point during execution of the instructions while in the transactional-execution mode; run-time-instrumentation-directed storing, upon successful completion of the transaction, run-time instrumentation information obtained at the sample point; performing the run-time-instrumentation-directed storing as a non-transactional store of a reporting group written to the program buffer current address; updating the program buffer current address based on the storing the reporting group; detecting a transaction abort event associated with the transaction; restoring the program buffer current address to the copy of the program buffer current address upon detecting the transaction abort event; and storing a transaction abort record associated with the transaction abort event in a next reporting group in the run-time instrumentation program buffer.
-
Specification