Conditional atomic operations in single instruction multiple data processors
First Claim
1. A method comprising:
- in response to a request to execute conditionally a first atomic operation for a plurality of threads at a processor;
selecting, at the processor, a first thread of the plurality of threads to execute a second atomic operation, wherein the second atomic operation is a conditional operation whose completion depends on contents of a memory location targeted by the second atomic operation; and
executing, at the processor, the second atomic operation at the first thread.
1 Assignment
0 Petitions
Accused Products
Abstract
A conditional fetch-and-phi operation tests a memory location to determine if the memory locations stores a specified value and, if so, modifies the value at the memory location. The conditional fetch-and-phi operation can be implemented so that it can be concurrently executed by a plurality of concurrently executing threads, such as the threads of wavefront at a GPU. To execute the conditional fetch-and-phi operation, one of the concurrently executing threads is selected to execute a compare-and-swap (CAS) operation at the memory location, while the other threads await the results. The CAS operation tests the value at the memory location and, if the CAS operation is successful, the value is passed to each of the concurrently executing threads.
6 Citations
20 Claims
-
1. A method comprising:
-
in response to a request to execute conditionally a first atomic operation for a plurality of threads at a processor; selecting, at the processor, a first thread of the plurality of threads to execute a second atomic operation, wherein the second atomic operation is a conditional operation whose completion depends on contents of a memory location targeted by the second atomic operation; and executing, at the processor, the second atomic operation at the first thread. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8)
-
-
9. A method, comprising:
-
receiving a request to execute a fetch-and-phi operation for each of a plurality of threads concurrently executing at a processor; and in response to the request to execute the fetch-and-phi operation, executing, at the processor, a compare-and-swap (CAS) operation whose completion depends on contents of a memory location targeted by the CAS operation at a selected one of the plurality of concurrently executing threads. - View Dependent Claims (10, 11, 12, 13)
-
-
14. A non-transitory computer readable storage medium embodying a set of executable instructions, the set of executable instructions to manipulate at least one processor to:
-
in response to a request to execute conditionally a first atomic operation for a plurality of threads at a processor, the first atomic operation being a non-conditional operation; select a first thread of the plurality of threads; and execute a second atomic operation at the first thread, wherein the second atomic operation is a conditional operation whose completion depends on contents of a memory location targeted by the second atomic operation. - View Dependent Claims (15, 16, 17, 18, 19, 20)
-
Specification