-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
I use OPA to atomically handle pointer put/get/swap operations. The data pointed at was written before putting it, and read after getting it, of course.
I investigated memory barriers, and am confused about whether OPA handles these, or not. There are barriers in the include files, but for pointers it is not clear whether they apply to the pointer alone, or to the data referenced.
It almost always makes sense to handle memory order issues for all pointer operations. The one exception is when code handles the pointer alone (which I've encountered in the example I point at).
- Is it right that OPA does not handle memory ordering of swaps that are being pointed-at?
- Is it an idea to add primitives that clearly help users to portable memory barriers for pointers used via OPA?
Metadata
Metadata
Assignees
Labels
No labels