Transactional lock elision with delayed lock checking
First Claim
Patent Images
1. A computer program product for transactional lock elision, the computer program product comprising:
- a computer readable hardware storage device containing computer executable program code stored thereon, the computer executable program code comprising;
computer executable program code for initiating a transactional lock elision transaction containing a critical section;
computer executable program code for executing the transactional lock elision transaction including the critical section;
computer executable program code for checking a status of a lock prior to a commit point in the transactional lock elision transaction executing, wherein the checking the status occurs after processing the critical section;
computer executable program code for determining whether the status of the lock checked is free;
computer executable program code responsive to a determination the lock checked is free, for committing a result of the transactional lock elision transaction;
computer executable program code for calculating a cost associated with checking the lock;
computer executable program code for analyzing the cost using an expression of Probability(lock_read_early/late_by_THREAD1
collides_with_lock_held_by_THREAD2)*(overhead_failing_TLE_transaction+wasted_work_done_inside_TLE_transaction); and
computer executable program code for identifying one of a lock read early or a lock read late using a result of the cost analyzing.
1 Assignment
0 Petitions
Accused Products
Abstract
Avoiding data conflicts includes initiating a transactional lock elision transaction containing a critical section, executing the transactional lock elision transaction including the critical section, and checking a status of a lock prior to a commit point in the transactional lock elision transaction executing, wherein the checking the status occurs after processing the critical section. A determination of whether the status of the lock checked is free is made and, responsive to a determination the lock checked is free, a result of the transactional lock elision transaction is committed.
10 Citations
11 Claims
-
1. A computer program product for transactional lock elision, the computer program product comprising:
a computer readable hardware storage device containing computer executable program code stored thereon, the computer executable program code comprising; computer executable program code for initiating a transactional lock elision transaction containing a critical section; computer executable program code for executing the transactional lock elision transaction including the critical section; computer executable program code for checking a status of a lock prior to a commit point in the transactional lock elision transaction executing, wherein the checking the status occurs after processing the critical section; computer executable program code for determining whether the status of the lock checked is free; computer executable program code responsive to a determination the lock checked is free, for committing a result of the transactional lock elision transaction; computer executable program code for calculating a cost associated with checking the lock; computer executable program code for analyzing the cost using an expression of Probability(lock_read_early/late_by_THREAD1
collides_with_lock_held_by_THREAD2)*(overhead_failing_TLE_transaction+wasted_work_done_inside_TLE_transaction); andcomputer executable program code for identifying one of a lock read early or a lock read late using a result of the cost analyzing. - View Dependent Claims (2, 3, 4, 5, 6)
-
7. An apparatus for transactional lock elision, comprising:
- a hardware processor unit connected to a communications fabric, wherein the processor unit executes computer executable program code to direct the apparatus to;
initiate a transactional lock elision transaction containing a critical section;
execute the transactional lock elision transaction including the critical section;check a status of a lock prior to a commit point in the transactional lock elision transaction executing, wherein the checking the status occurs after processing the critical section; determine whether the status of the lock checked is free; response to a determination the lock checked is free, commit a result of the transactional lock elision transaction; calculate a cost associated with checking the lock; analyze the cost using an expression of
Probability(lock_read_early/late_by_THREAD1 collides_with_lock_held_by_THREAD2)*(overhead_failing_TLE_transaction+wasted_work_done_inside_TLE_transaction);and identify one of a lock read early or a lock read late using result of the cost analyzing. - View Dependent Claims (8, 9, 10, 11)
- a hardware processor unit connected to a communications fabric, wherein the processor unit executes computer executable program code to direct the apparatus to;
-
11. The apparatus of claim 7, wherein
a time window from reading the lock early to a commit time is greater than a time window from reading the lock late, wherein a probability of conflict on the lock in deferred locking is less than the probability of conflict on the lock in conventional locking.
Specification