mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
5fa5764f30
This implements a full memory barrier. On ubuntu amd64 with results in an 'mfence' instruction. This is required to syncronization between threads, where there's typically only one write of a memory that should be synced between all threads with the barrier. Much more details can be found here: https://gcc.gnu.org/onlinedocs/gcc-7.3.0/gcc/_005f_005fatomic-Builtins.html#g_t_005f_005fatomic-Builtins https://gcc.gnu.org/onlinedocs/gcc-7.3.0/gcc/_005f_005fsync-Builtins.html#g_t_005f_005fsync-Builtins The main one we use seems to be in C11 via stdatomic.h, the oldest fallback is __sync_synchronize(), which is available since 2005 in gcc. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org> |
||
---|---|---|
.. | ||
aio.h | ||
capability.h | ||
dir.h | ||
filesys.h | ||
glob.h | ||
gssapi.h | ||
iconv.h | ||
kerberos.h | ||
locale.h | ||
network.h | ||
nis.h | ||
passwd.h | ||
readline.h | ||
README | ||
select.h | ||
shmem.h | ||
syslog.h | ||
terminal.h | ||
threads.h | ||
time.h | ||
wait.h | ||
wscript_configure |
This directory contains wrappers around logical groups of system include files. The idea is to avoid #ifdef blocks in the main code, and instead put all the necessary conditional includes in subsystem specific header files in this directory.