Methods and Systems for Partially-Transacted Data Concurrency
First Claim
1. A method for protecting multi-threaded access to shared memory, said method comprising:
- a) providing, via a computing device comprising a processor and a memory, limited access to a shared memory resource, wherein said limited access is provided when one or more threads are entering a read operation on said shared memory resource, exiting a read operation on said shared memory resource and during at least a portion of a write operation on said shared memory resource; and
b) blocking, via said computing device, said access to said shared memory resource when one or more threads is exiting a write operation on said shared memory resource, wherein said exiting a write operation causes execution of a commit operation wherein data is written to said shared memory resource.
7 Assignments
0 Petitions
Accused Products
Abstract
Aspects of the present invention comprise systems and methods for protecting multi-threaded access to shared memory. Some aspects provide higher data concurrency than other methods. Some aspects relate to methods and systems that provide access to data for all threads during the first phases of one thread'"'"'s write operation. Some aspects provide all threads access to a particular data unit until one thread enters the commit phase of the write operation. Some aspects manage a computing data resource such that, when a thread enters the commit phase, all pending read requests are fulfilled, all pending write requests are allowed to proceed to commit phase at which point they are blocked, all new read and write requests are blocked and the commit phase is completed by updating the target data and releasing the blocked requests.
Some aspects provide improved concurrency by performing reduced cross-thread interference. Some aspects may be implemented at any level from hardware to high-level languages. Some aspects protect readers from accessing partial write results which avoids retry semantics and data corruption.
-
Citations
20 Claims
-
1. A method for protecting multi-threaded access to shared memory, said method comprising:
-
a) providing, via a computing device comprising a processor and a memory, limited access to a shared memory resource, wherein said limited access is provided when one or more threads are entering a read operation on said shared memory resource, exiting a read operation on said shared memory resource and during at least a portion of a write operation on said shared memory resource; and b) blocking, via said computing device, said access to said shared memory resource when one or more threads is exiting a write operation on said shared memory resource, wherein said exiting a write operation causes execution of a commit operation wherein data is written to said shared memory resource. - View Dependent Claims (2, 3, 4, 5, 6)
-
-
7. A method for protecting multi-threaded access to shared memory, said method comprising:
-
a) providing read access to a data element, Data 1, of a shared memory resource for a plurality of threads, said providing being performed by a computing device comprising a processor and memory; b) receiving, at said computing device, a write request for said data element, Data 1, from Thread A, which is one of said plurality of threads; c) creating, with said computing device, a new data element, Copy 1A, with an initial value copied from Data 1; d) granting exclusive write access for Copy 1A to Thread A, wherein said granting is performed by said computing device; e) maintaining read access to said plurality of threads, including Thread A, for Data 1 after receiving said write request from Thread A, wherein said maintaining is performed by said computing device; f) receiving a commit request from Thread A to exit a write process initiated by said write request by entering a commit phase wherein the value in Copy 1A will be written to Data 1 and made accessible to all threads by said computing device; g) blocking Thread A, with said computing device, until i) all pending read requests from other threads are fulfilled, and ii) all pending write requests from other threads have progressed to blocking; h) blocking any new read requests and write requests for Data 1 with said computing device; i) writing the value in Copy 1A to Data 1, with said computing device; j) unblocking all read requests after said writing with said computing device; and k) unblocking each write request in succession with said computing device. - View Dependent Claims (8, 9, 10, 11, 12, 13, 14)
-
-
15. An apparatus for protecting multi-threaded access to shared memory, said apparatus comprising:
a) a data manager comprising a processor and a shared memory resource, said data manager comprising; i) an access manager for providing read access to a data element, Data 1, of said shared memory resource to a plurality of threads; ii) a receiver for receiving a write request for said data element, Data 1, from Thread A, which is one of said plurality of threads; (1) wherein said data manager creates a new data element, Copy 1A, with an initial value copied from Data 1 in response to said receiving a write request; (2) wherein said data manager grants exclusive write access for Copy 1A to Thread A; (3) wherein said data manager maintains read access to said plurality of threads, including Thread A, for Data 1 after receiving said write request from Thread A; iii) a second receiver for receiving a commit request from Thread A, (1) wherein said data manager exits a write process initiated by said write request by entering a commit phase wherein the value in Copy 1A will be written to Data 1 and made accessible to all threads in response to said receiving a commit request; iv) a first blocker for blocking Thread A until (1) all pending read requests from other threads are fulfilled, and (2) all pending write requests from other threads have progressed to blocking; v) a second blocker for blocking any new read requests and write requests for Data 1; vi) a memory writer for writing the value in Copy 1A to Data 1; (1) wherein said first blocker and said second blocker unblock all read requests after said writing; and (2) wherein said first blocker and said second blocker unblock each write request in succession. - View Dependent Claims (16, 17, 18, 19, 20)
Specification