Changes in kernel/generic/include/atomic.h [efed95a3:b2ec5cf] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/include/atomic.h
refed95a3 rb2ec5cf 39 39 #include <typedefs.h> 40 40 #include <stdatomic.h> 41 42 /*43 * Shorthand for relaxed atomic read/write, something that's needed to formally44 * avoid undefined behavior in cases where we need to read a variable in45 * different threads and we don't particularly care about ordering46 * (e.g. statistic printouts). This is most likely translated into the same47 * assembly instructions as regular read/writes.48 */49 #define atomic_set_unordered(var, val) atomic_store_explicit((var), (val), memory_order_relaxed)50 #define atomic_get_unordered(var) atomic_load_explicit((var), memory_order_relaxed)51 41 52 42 #define atomic_predec(val) \
Note:
See TracChangeset
for help on using the changeset viewer.