Invention Grant
- Patent Title: Almost fair busy lock
-
Application No.: US15613673Application Date: 2017-06-05
-
Publication No.: US10169107B2Publication Date: 2019-01-01
- Inventor: Marco Greco
- Applicant: International Business Machines Corporation
- Applicant Address: US NY Armonk
- Assignee: International Business Machines Corporation
- Current Assignee: International Business Machines Corporation
- Current Assignee Address: US NY Armonk
- Agent Jared C. Chaney
- Priority: GB1420412.7 20141118
- Main IPC: G06F9/46
- IPC: G06F9/46 ; G06F9/52 ; G06F9/48

Abstract:
The present invention provides a method, a system, and a computer program product of preventing thread monitoring preemptions in an almost fair busy lock. In an exemplary embodiment, the method, the system, and the computer program product include (1) publishing a current state of a lock and a claim non-atomically to the lock by a next owning thread, the claim comprising a structure capable of being read and written only in a single memory access, (2) obtaining a ticket, where the claim comprises an identifier of a ticket obtained by the next owning thread, and an indication that the next owning thread is claiming the lock; (3) comparing the ticket obtained by the next owning thread with a current ticket; (4) preventing thread monitoring preemptions; and (5) responsive to a match between the ticket obtained by the next owning thread and the current ticket, non-atomically acquiring the lock.
Public/Granted literature
- US20170269973A1 ALMOST FAIR BUSY LOCK Public/Granted day:2017-09-21
Information query