|
Dynamic Load Balance 3.6.1+32-59d1
|
#include <stdbool.h>#include <stdint.h>

Go to the source code of this file.
Macros | |
| #define | _Atomic(T) volatile __typeof__(T) |
| #define | atomic_int volatile int |
| #define | atomic_uint volatile unsigned int |
| #define | atomic_int_least64_t volatile int64_t |
| #define | atomic_uint_least64_t volatile uint64_t |
| #define | atomic_bool volatile bool |
| #define | DLB_ATOMIC_ADD(ptr, val) __sync_fetch_and_add(ptr, val) |
| #define | DLB_ATOMIC_ADD_RLX(ptr, val) DLB_ATOMIC_ADD(ptr, val) |
| #define | DLB_ATOMIC_ADD_FETCH(ptr, val) __sync_add_and_fetch(ptr, val) |
| #define | DLB_ATOMIC_ADD_FETCH_RLX(ptr, val) DLB_ATOMIC_ADD_FETCH(ptr, val) |
| #define | DLB_ATOMIC_SUB(ptr, val) __sync_fetch_and_sub(ptr, val) |
| #define | DLB_ATOMIC_SUB_RLX(ptr, val) DLB_ATOMIC_SUB(ptr, val) |
| #define | DLB_ATOMIC_SUB_FETCH(ptr, val) __sync_sub_and_fetch(ptr, val) |
| #define | DLB_ATOMIC_SUB_FETCH_RLX(ptr, val) __sync_sub_and_fetch(ptr, val) |
| #define | DLB_ATOMIC_LD(ptr) ({ typeof (*ptr) value; __sync_synchronize(); value = (*ptr); __sync_synchronize(); value; }) |
| #define | DLB_ATOMIC_LD_RLX(ptr) (*ptr) |
| #define | DLB_ATOMIC_LD_ACQ(ptr) ({ __sync_synchronize(); (*ptr); }) |
| #define | DLB_ATOMIC_ST(ptr, val) __sync_synchronize(); (*ptr) = (val); __sync_synchronize() |
| #define | DLB_ATOMIC_ST_RLX(ptr, val) (*ptr) = (val) |
| #define | DLB_ATOMIC_ST_REL(ptr, val) (*ptr) = (val); __sync_synchronize() |
| #define | DLB_ATOMIC_EXCH(ptr, val) __sync_synchronize(); __sync_lock_test_and_set(ptr, val) |
| #define | DLB_ATOMIC_EXCH_RLX(ptr, val) __sync_lock_test_and_set(ptr, val) |
| #define | DLB_ATOMIC_CMP_EXCH_WEAK(ptr, oldval, newval) __sync_bool_compare_and_swap(ptr, oldval, newval) |
| #define | DLB_CACHE_LINE 64 |
| #define | DLB_ALIGN_CACHE __attribute__((aligned(DLB_CACHE_LINE))) |
| #define _Atomic | ( | T | ) | volatile __typeof__(T) |
| #define atomic_int volatile int |
| #define atomic_uint volatile unsigned int |
| #define atomic_int_least64_t volatile int64_t |
| #define atomic_uint_least64_t volatile uint64_t |
| #define atomic_bool volatile bool |
| #define DLB_ATOMIC_ADD | ( | ptr, | |
| val | |||
| ) | __sync_fetch_and_add(ptr, val) |
| #define DLB_ATOMIC_ADD_RLX | ( | ptr, | |
| val | |||
| ) | DLB_ATOMIC_ADD(ptr, val) |
| #define DLB_ATOMIC_ADD_FETCH | ( | ptr, | |
| val | |||
| ) | __sync_add_and_fetch(ptr, val) |
| #define DLB_ATOMIC_ADD_FETCH_RLX | ( | ptr, | |
| val | |||
| ) | DLB_ATOMIC_ADD_FETCH(ptr, val) |
| #define DLB_ATOMIC_SUB | ( | ptr, | |
| val | |||
| ) | __sync_fetch_and_sub(ptr, val) |
| #define DLB_ATOMIC_SUB_RLX | ( | ptr, | |
| val | |||
| ) | DLB_ATOMIC_SUB(ptr, val) |
| #define DLB_ATOMIC_SUB_FETCH | ( | ptr, | |
| val | |||
| ) | __sync_sub_and_fetch(ptr, val) |
| #define DLB_ATOMIC_SUB_FETCH_RLX | ( | ptr, | |
| val | |||
| ) | __sync_sub_and_fetch(ptr, val) |
| #define DLB_ATOMIC_LD | ( | ptr | ) | ({ typeof (*ptr) value; __sync_synchronize(); value = (*ptr); __sync_synchronize(); value; }) |
| #define DLB_ATOMIC_LD_RLX | ( | ptr | ) | (*ptr) |
| #define DLB_ATOMIC_LD_ACQ | ( | ptr | ) | ({ __sync_synchronize(); (*ptr); }) |
| #define DLB_ATOMIC_ST | ( | ptr, | |
| val | |||
| ) | __sync_synchronize(); (*ptr) = (val); __sync_synchronize() |
| #define DLB_ATOMIC_ST_RLX | ( | ptr, | |
| val | |||
| ) | (*ptr) = (val) |
| #define DLB_ATOMIC_ST_REL | ( | ptr, | |
| val | |||
| ) | (*ptr) = (val); __sync_synchronize() |
| #define DLB_ATOMIC_EXCH | ( | ptr, | |
| val | |||
| ) | __sync_synchronize(); __sync_lock_test_and_set(ptr, val) |
| #define DLB_ATOMIC_EXCH_RLX | ( | ptr, | |
| val | |||
| ) | __sync_lock_test_and_set(ptr, val) |
| #define DLB_ATOMIC_CMP_EXCH_WEAK | ( | ptr, | |
| oldval, | |||
| newval | |||
| ) | __sync_bool_compare_and_swap(ptr, oldval, newval) |
| #define DLB_CACHE_LINE 64 |
| #define DLB_ALIGN_CACHE __attribute__((aligned(DLB_CACHE_LINE))) |