Scalable method for producer and consumer elimination
First Claim
1. A computer-implemented method, comprising:
- a producer process atomically storing a data value to a transfer location;
the producer process setting a status indicator for the transfer location to indicate a non-empty status;
wherein the producer process atomically stores the data value to the transfer location and sets the status indicator for the transfer location as a single atomic operation; and
the producer process setting the status indicator for the transfer location to indicate an empty status in response to a consumer process setting the status indicator to indicate a done status.
2 Assignments
0 Petitions
Accused Products
Abstract
Producers and consumer processes may synchronize and transfer data using a shared data structure. After locating a potential transfer location that indicates an EMPTY status, a producer may store data to be transferred in the transfer location. A producer may use a compare-and-swap (CAS) operation to store the transfer data to the transfer location. A consumer may subsequently read the transfer data from the transfer location and store, such as by using a CAS operation, a DONE status indicator in the transfer location. The producer may notice the DONE indication and may then set the status location back to EMPTY to indicate that the location is available for future transfers, by the same or a different producer. The producer may also monitor the transfer location and time out if no consumer has picked up the transfer data.
52 Citations
20 Claims
-
1. A computer-implemented method, comprising:
-
a producer process atomically storing a data value to a transfer location;
the producer process setting a status indicator for the transfer location to indicate a non-empty status;
wherein the producer process atomically stores the data value to the transfer location and sets the status indicator for the transfer location as a single atomic operation; and
the producer process setting the status indicator for the transfer location to indicate an empty status in response to a consumer process setting the status indicator to indicate a done status. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10)
-
-
11. A system, comprising:
-
a processor; and
a memory, wherein the memory comprising program instruction executable by the processor to implement;
a consumer process; and
a producer process, wherein the producer process is configured to;
atomically store a data value to a transfer location;
set a status indicator for the transfer location to indicate a non-empty status;
wherein the producer process is configured to atomically store the data value to the transfer location and to set the status indicator for the transfer location as a single atomic operation; and
set the status indicator for the transfer location to indicate an empty status in response to the consumer process setting the status indicator to indicate a done status. - View Dependent Claims (12, 13, 14, 15, 16, 17, 18, 19)
-
-
20. A computer accessible medium, comprising program instructions computer executable to implement:
-
a producer process atomically storing a data value to a transfer location;
the producer process setting a status indicator for the transfer location to indicate a non-empty status;
wherein the producer process atomically stores the data value to the transfer location and sets the status indicator for the transfer location as a single atomic operation; and
the producer process setting the status indicator for the transfer location to indicate an empty status in response to a consumer process setting the status indicator to indicate a done status.
-
Specification