Browse Source

MT#55283 add generic atomic_() macros

Change-Id: I56aca3d86663858755b770ede9f3c8e5dcba58f7
pull/1819/head
Richard Fuchs 2 years ago
parent
commit
d76a228096
1 changed files with 3 additions and 0 deletions
  1. +3
    -0
      include/helpers.h

+ 3
- 0
include/helpers.h View File

@ -338,6 +338,9 @@ INLINE double atomic64_div(const atomic64 *n, const atomic64 *d) {
return (double) atomic64_get(n) / (double) dd;
}
#define atomic_get_na(x) __atomic_load_n(x, __ATOMIC_RELAXED)
#define atomic_set_na(x,y) __atomic_store_n(x, y, __ATOMIC_RELAXED)
/*** ATOMIC BITFIELD OPERATIONS ***/


Loading…
Cancel
Save