From: Joao Abecasis (jpabecasis_at_[hidden])
Date: 2005-09-06 19:26:36
I think the interface of atomic_count should be done in terms of
boost::int32_t instead of long. Currently there are 3 independent
implementations for atomic_count:
* atomic_count_gcc: uses _Atomic_word (32-bit)
* atomic_count_win32: uses BOOST_INTERLOCKED_*, currently defined
for windows platforms, works on 32-bit types.
* atomic_count_pthreads: uses long; however, because it uses a
mutex for synchronization, it could use any type for the counter.
The reason for bringing this up comes from experimenting atomic_count on
a linux x86_64 box with gcc4 (FC4, in case it matters), where long is a
64-bit type, while the counter is 32-bit. I don't know if this also
happens on other 64-bit platforms.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk