summaryrefslogtreecommitdiff
path: root/ACE/ace/Atomic_Op_GCC_T.inl
diff options
context:
space:
mode:
Diffstat (limited to 'ACE/ace/Atomic_Op_GCC_T.inl')
-rw-r--r--ACE/ace/Atomic_Op_GCC_T.inl7
1 files changed, 7 insertions, 0 deletions
diff --git a/ACE/ace/Atomic_Op_GCC_T.inl b/ACE/ace/Atomic_Op_GCC_T.inl
index de3bf1a1438..8a914c65c1a 100644
--- a/ACE/ace/Atomic_Op_GCC_T.inl
+++ b/ACE/ace/Atomic_Op_GCC_T.inl
@@ -130,6 +130,13 @@ ACE_Atomic_Op_GCC<T>::operator= (
template <typename T>
ACE_INLINE T
+ACE_Atomic_Op_GCC<T>::exchange (T newval)
+{
+ return __sync_val_compare_and_swap (&this->value_, this->value_, newval);
+}
+
+template <typename T>
+ACE_INLINE T
ACE_Atomic_Op_GCC<T>::value (void) const
{
return this->value_;