×

Highly scalable tree-based trylock

  • US 9,400,818 B2
  • Filed: 09/16/2013
  • Issued: 07/26/2016
  • Est. Priority Date: 06/24/2013
  • Status: Expired due to Fees
First Claim
Patent Images

1. In a multiprocessor computer system having two or more processors operatively coupled to one or more memory devices, a tree-based trylock method that reduces contention on a root trylock, comprising:

  • providing a lock hierarchy in which plural trylocks are distributed among nodes of a tree-based node structure having a plurality of leaf nodes, one or more internal nodes, and a root node;

    assigning said processors to said leaf nodes in a distributed and balanced manner in order to minimize memory contention on said trylocks;

    implementing a trylock acquisition operation on a selected one of said processors for acquiring a root trylock associated with said root node;

    said trylock acquisition operation including attempting to acquire one of said trylocks at each node of said node structure that lies on a traversal path beginning at one of said leaf nodes, passing through one or more of said internal nodes, and ending at said root node;

    said trylock acquisition operation succeeding if each trylock on said traversal path is acquired, and failing if any trylock on said traversal path cannot be acquired; and

    performing a trylock housekeeping operation that releases all non-root trylocks visited by said trylock acquisition operation, such that if said trylock acquisition operation succeeds, only said root trylock will be remain acquired at the end of said operation, and if said trylock acquisition operation fails, none of said trylocks will be remain acquired at the end of said operation.

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