Ticket 49305 - Improve atomic behaviours in 389-ds
Bug Description: Previously our usage of atomics has ranged from
"okay" with PR_Atomic, to dangerous with atomic's only being
partially used. Notablp, PR_Atomic is much slower than gcc's
__atomic_* operations, especially given the barrier options
avaliable in gcc for thread sync.
Fix Description: This replaces most calles to PR_Atomic
with the correct __atomic types. Importantly, this also
changes the slapi_counter types to __ATOMIC_RELAXED, which
removes thread ordering constraints, and allows just "atomics"
to function.
https://pagure.io/389-ds-base/issue/49305
Author: wibrown
Review by: mreynolds (Thanks!)