Chained resource locking
AssigneeMicron Technology, Inc.
InventorsPatrick Estep, Tony M. Brewer
Life of this patent
Estimating the term…
Abstract
Devices and techniques for CHAINED RESOURCE LOCKING are described herein. Threads form a last-in-first-out (LIFO) queue on a resource lock to create a chained lock on the resource. A data store representing the lock for the resource holds the previous thread’s identifier, enabling a subsequent thread to wake the previous thread using the identifier when the subsequent thread releases the lock. Generally, the thread releasing the lock need not interact with the data store, reducing contention for the data store among many threads.
Claims30
A system comprising:
- a memory controller configured to maintain a datastore representing a lock of a resource;
- and
- a hybrid threading processor (HTP) configured to execute a first thread to:
- obtain a value from the datastore;
- pause based on the value corresponding to a thread identifier indicating that the resource is locked, the thread identifier corresponding to a second thread;
- execute using the resource based on a first wake message corresponding to the resource;
- and
- release the lock by sending a second wake message to the second thread based on the thread identifier to awake the second thread to use the resource.
An apparatus comprising:
- a network interface;
- and processing circuitry, in a hybrid thread processor (HTP), configured to execute a first thread to:
- obtain, using the network interface, a value from a datastore representing a lock of a resource;
- pause based on the value corresponding to a thread identifier indicating that the resource is locked, the thread identifier corresponding to a second thread;
- execute using the resource based on a first wake message corresponding to the resource;
- and
- release the lock by sending a second wake message, through the network interface, to the second thread based on the thread identifier to awake the second thread to use the resource.
Machine readable media including instructions that, when executed by processing circuitry, cause the processing circuitry to perform operations comprising:
- obtaining, by a first thread executing in processing circuitry, a value from a datastore representing a lock of a resource;
- pausing the first thread based on the value corresponding to a thread identifier indicating that the resource is locked, the thread identifier corresponding to a second thread;
- executing the first thread using the resource based on a first wake message corresponding to the resource;
- and
- releasing the lock by sending a second wake message, from the first thread, to the second thread based on the thread identifier to awake the second thread to use the resource.
Dependencies are inferred from the claim text.