×

Almost fair busy lock

  • US 10,169,107 B2
  • Filed: 06/05/2017
  • Issued: 01/01/2019
  • Est. Priority Date: 11/18/2014
  • Status: Active Grant
First Claim
Patent Images

1. A method comprising:

  • publishing a current state of a lock and a claim non-atomically to the lock by a next owning thread, in an ordered set of threads, that has requested to own the lock, the claim comprising a structure capable of being read and written only in a single memory access,obtaining, by each thread in the ordered set of threads, a ticket,wherein 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;

    comparing the ticket obtained by the next owning thread with a current ticket;

    responsive to a match between the ticket obtained by the next owning thread and the current ticket, preventing thread monitoring preemptions; and

    responsive to a match between the ticket obtained by the next owning thread and the current ticket, non-atomically acquiring the lock.

View all claims
  • 1 Assignment
Timeline View
Assignment View
    ×
    ×