Lock leasing method for solving deadlock
First Claim
1. A method for resolving deadlock in a multi-threaded computing system, the method comprising:
- leasing, by a first thread, a lock held by the first thread to a second thread different from the first thread, wherein leasing the lock comprises transferring control of the lock to the second thread while the first thread retains ownership of the lock; and
receiving, by the first thread, the control of the lock back from the second thread after the second thread has finished using the lock.
1 Assignment
0 Petitions
Accused Products
Abstract
A method for resolving deadlock in a multi-threaded computing system using a novel lock lease is disclosed. A first thread leases a lock held by the first thread to a second thread different from the first thread. The leasing transfers control of the lock to the second thread while the first thread retains ownership of the lock. To lease the lock: (1) the second thread applies for the lease from the first thread; (2) the first thread grants the lease; (3) the first thread waits for the second thread to complete a task; (4) the second thread terminates the lease; (5) the first thread confirms termination of the lease. The first thread receives control of the lock back from the second thread after the second thread has finished using resources controlled by the lock. The second thread also can sublease the lock to a third thread.
8 Citations
22 Claims
-
1. A method for resolving deadlock in a multi-threaded computing system, the method comprising:
-
leasing, by a first thread, a lock held by the first thread to a second thread different from the first thread, wherein leasing the lock comprises transferring control of the lock to the second thread while the first thread retains ownership of the lock; and receiving, by the first thread, the control of the lock back from the second thread after the second thread has finished using the lock. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10)
-
-
11. An electronic device for resolving deadlock in a multi-threaded computing system, the electronic device comprising:
a processor configured to; lease, by a first thread, a lock held by the first thread to a second thread different from the first thread, wherein the lease enables the second thread to use one or more resources controlled by the lock while the first thread continues to own the lock; and return the use of the one or more resources controlled by the lock back to the first thread after the second thread has finished using the one or more resources controlled by the lock. - View Dependent Claims (12, 13, 14, 15, 16)
-
17. A non-transitory computer readable medium storing instructions that, when executed by a processor included in a computing device, cause the computing device to resolve deadlock in a multi-threaded computing system, by carrying out the steps that include:
-
leasing, by a first thread, a lock held by the first thread to a second thread different from the first thread, wherein leasing the lock comprises transferring control of the lock to the second thread, while the first thread retains ownership of the lock and does not use one or more resources controlled by the lock during leasing the lock; and receiving, by the first thread, the control of the lock back from the second thread after the second thread has finished using the one or more resources controlled by the lock. - View Dependent Claims (18, 19, 20, 21, 22)
-
Specification