aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Kosnik <bkoz@redhat.com>2006-08-30 09:39:45 +0000
committerBenjamin Kosnik <bkoz@gcc.gnu.org>2006-08-30 09:39:45 +0000
commitb93d5ca9df26104f89b75ff120a3dd2b1bcbae58 (patch)
tree9f268cdade8b1cb7937aab5b2355a992a2856854
parentc87555d6a6b510f5d64a7dace02461c0021b08b8 (diff)
downloadgcc-b93d5ca9df26104f89b75ff120a3dd2b1bcbae58.zip
gcc-b93d5ca9df26104f89b75ff120a3dd2b1bcbae58.tar.gz
gcc-b93d5ca9df26104f89b75ff120a3dd2b1bcbae58.tar.bz2
gnu.ver: Spell out exact signatures for atomic access functions.
2006-08-30 Benjamin Kosnik <bkoz@redhat.com> Richard Guenther <rguenther@suse.de> * config/abi/pre/gnu.ver: Spell out exact signatures for atomic access functions. * include/bits/atomicity.h (__atomic_add_dispatch): Remove volatile qualification for _Atomic_word argument. (__atomic_add_single): Same. (__exchange_and_add_dispatch): Same. (__exchange_and_add_single): Same. Co-Authored-By: Richard Guenther <rguenther@suse.de> From-SVN: r116584
-rw-r--r--libstdc++-v3/ChangeLog12
-rw-r--r--libstdc++-v3/config/abi/pre/gnu.ver4
-rw-r--r--libstdc++-v3/include/bits/atomicity.h13
3 files changed, 21 insertions, 8 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index cf8546c..caa1fcf 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,3 +1,15 @@
+2006-08-30 Benjamin Kosnik <bkoz@redhat.com>
+ Richard Guenther <rguenther@suse.de>
+
+ * config/abi/pre/gnu.ver: Spell out exact signatures for atomic
+ access functions.
+
+ * include/bits/atomicity.h (__atomic_add_dispatch): Remove
+ volatile qualification for _Atomic_word argument.
+ (__atomic_add_single): Same.
+ (__exchange_and_add_dispatch): Same.
+ (__exchange_and_add_single): Same.
+
2006-08-29 Paolo Carlini <pcarlini@suse.de>
* include/tr1/random (subtract_with_carry_01<>::_M_initialize_npows):
diff --git a/libstdc++-v3/config/abi/pre/gnu.ver b/libstdc++-v3/config/abi/pre/gnu.ver
index ee869a2..1a1cfce 100644
--- a/libstdc++-v3/config/abi/pre/gnu.ver
+++ b/libstdc++-v3/config/abi/pre/gnu.ver
@@ -378,8 +378,8 @@ GLIBCXX_3.4 {
# __gnu_cxx::__atomic_add
# __gnu_cxx::__exchange_and_add
- _ZN9__gnu_cxx12__atomic_add*;
- _ZN9__gnu_cxx18__exchange_and_add*;
+ _ZN9__gnu_cxx12__atomic_addEPVii;
+ _ZN9__gnu_cxx18__exchange_and_addEPVii;
# debug mode
_ZN10__gnu_norm15_List_node_base4hook*;
diff --git a/libstdc++-v3/include/bits/atomicity.h b/libstdc++-v3/include/bits/atomicity.h
index 18832fe..79af99e 100644
--- a/libstdc++-v3/include/bits/atomicity.h
+++ b/libstdc++-v3/include/bits/atomicity.h
@@ -60,7 +60,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
#endif
static inline _Atomic_word
- __exchange_and_add_single(volatile _Atomic_word* __mem, int __val)
+ __exchange_and_add_single(_Atomic_word* __mem, int __val)
{
_Atomic_word __result = *__mem;
*__mem += __val;
@@ -68,12 +68,12 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
}
static inline void
- __atomic_add_single(volatile _Atomic_word* __mem, int __val)
+ __atomic_add_single(_Atomic_word* __mem, int __val)
{ *__mem += __val; }
static inline _Atomic_word
__attribute__ ((__unused__))
- __exchange_and_add_dispatch(volatile _Atomic_word* __mem, int __val)
+ __exchange_and_add_dispatch(_Atomic_word* __mem, int __val)
{
#ifdef __GTHREADS
if (__gthread_active_p())
@@ -87,7 +87,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
static inline void
__attribute__ ((__unused__))
- __atomic_add_dispatch(volatile _Atomic_word* __mem, int __val)
+ __atomic_add_dispatch(_Atomic_word* __mem, int __val)
{
#ifdef __GTHREADS
if (__gthread_active_p())
@@ -101,8 +101,9 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
_GLIBCXX_END_NAMESPACE
-// Even if the CPU doesn't need a memory barrier, we need to ensure that
-// the compiler doesn't reorder memory accesses across the barriers.
+// Even if the CPU doesn't need a memory barrier, we need to ensure
+// that the compiler doesn't reorder memory accesses across the
+// barriers.
#ifndef _GLIBCXX_READ_MEM_BARRIER
#define _GLIBCXX_READ_MEM_BARRIER __asm __volatile ("":::"memory")
#endif