×

Method and computer program product for reducing lock contention in a multiple instruction execution stream processing environment

  • US 6,119,115 A
  • Filed: 03/12/1998
  • Issued: 09/12/2000
  • Est. Priority Date: 03/12/1998
  • Status: Expired due to Term
First Claim
Patent Images

1. In a computing environment containing a database, wherein an object contained in a portion of the database may be accessed by multiple streams of executable instructions, wherein a reference count technique is used to track use of the object by the multiple streams, and wherein access to the portion of the database and therefore access to the object is controlled by a global lock that must be acquired by an executable stream in order to use the object, a computer program product for reducing lock contention for the global lock between the multiple streams of executable instructions that require use of the object, said lock contention causing wasted CPU processing cycles which otherwise occur when a stream is waiting to acquire the global lock when the global lock is already in use by a different stream, said computer program product reducing lock contention by minimizing excess global lock acquisitions without constraints in global lock acquisitions with other locks, the computer program product comprising:

  • a computer-readable medium; and

    computer-executable instructions contained on said computer-readable medium for performing the following;

    a specific act of assigning to the object a first reference count and a second reference count;

    a specific act of selecting a lock to control access to the second reference count;

    a specific act of when a stream of executable instructions seeks to use the object, while the global lock is held, locating the object in the database and incrementing the first reference count assigned to the object; and

    a specific act of after the stream of executable instructions is finished using the object, while the selected lock is held, incrementing the second reference count assigned to the object and comparing the first and second reference counts assigned to the object, and if the first and second reference counts are equal, deleting the object and releasing the selected lock if necessary at some point after the comparison is made between the first and second reference counts.

View all claims
  • 2 Assignments
Timeline View
Assignment View
    ×
    ×