12 #ifndef ROOT_TAtomicCountGcc 13 #define ROOT_TAtomicCountGcc 31 #if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 2) || \ 32 (defined(__APPLE_CC__) && __APPLE_CC__ > 5000 && !defined(MAC_OS_X_VERSION_10_6)) 33 #include <bits/atomicity.h> 35 #include <ext/atomicity.h> 40 #if defined(__GLIBCXX__) // g++ 3.4+ 42 using __gnu_cxx::__atomic_add;
43 using __gnu_cxx::__exchange_and_add;
59 operator long()
const {
return __exchange_and_add(&fCnt, 0); }
62 #ifdef _GLIBCXX_WRITE_MEM_BARRIER 63 #if !(defined(__INTEL_COMPILER) && defined(__ia64__)) //ICC doesn't support inline asm on IA-64 64 _GLIBCXX_WRITE_MEM_BARRIER;
68 Long_t Get()
const {
return __exchange_and_add(&fCnt, 0); }
TAtomicCount & operator=(const TAtomicCount &)
TAtomicCount(const TAtomicCount &)