|
Boost-Commit : |
From: matt_calabrese_at_[hidden]
Date: 2007-06-22 13:28:24
Author: matt_calabrese
Date: 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
New Revision: 7128
URL: http://svn.boost.org/trac/boost/changeset/7128
Log:
Started laying down the framework for dispatching implementations of fences and compiler-only fences.
Added:
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/implementation_info/
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/implementation_info/compiler_fence_support.hpp
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/implementation_info/fence_support.hpp
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/implementation_info/operation_support.hpp
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify.hpp
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify.hpp
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_acquire.hpp
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_acquire_fwd.hpp
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_fwd.hpp
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_release.hpp
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_release_fwd.hpp
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify_fwd.hpp
Text files modified:
sandbox/SOC/2006/concurrency/trunk/boost/act/config/interlocked/has_interlocked_operations.hpp | 4 ++--
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/add_assign.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/add_assign_fwd.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/detail/add_assign_default | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/assign/assign.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/assign_if_was/assign_if_was.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/bitand_assign.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/bitand_assign_fwd.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/detail/bitand_assign_default.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/bitor_assign.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/bitor_assign_fwd.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/detail/bitor_assign_default.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/decrement/decrement.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/decrement/decrement_fwd.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/binary_default.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/binary_result_dont_include.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/cas_support.hpp | 22 +++++++++++-----------
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/cas_support_data.hpp | 14 +++++++-------
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/default_unary_impl.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/full_name.hpp | 9 +++++----
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/unary_result_impl.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/increment/increment.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/increment/increment_fwd.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/detail/lshift_assign_default.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/lshift_assign.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/lshift_assign_fwd.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/retrieve/detail/retrieve_default.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/detail/rshift_assign_default.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/rshift_assign.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/rshift_assign_fwd.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/detail/subtract_assign_default | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/subtract_assign.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/subtract_assign_fwd.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/detail/xor_assign_default.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/xor_assign.hpp | 2 +-
sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/xor_assign_fwd.hpp | 2 +-
36 files changed, 57 insertions(+), 56 deletions(-)
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/config/interlocked/has_interlocked_operations.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/config/interlocked/has_interlocked_operations.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/config/interlocked/has_interlocked_operations.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -9,9 +9,9 @@
#ifndef BOOST_ACT_CONFIG_INTERLOCKED_HAS_INTERLOCKED_HPP
#define BOOST_ACT_CONFIG_INTERLOCKED_HAS_INTERLOCKED_HPP
-#include <boost/act/interlocked/detail/cas_support_data.hpp>
+#include <boost/act/interlocked/detail/implementation_info/operation_support.hpp>
-#ifdef BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA
+#ifdef BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT
#define BOOST_ACT_HAS_INTERLOCKED_OPERATIONS
#endif
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/add_assign.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/add_assign.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/add_assign.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_INFO \
-( add_assign, full_barrier, additive )
+( add_assign, full_fence, additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/add_assign_fwd.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/add_assign_fwd.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/add_assign_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder_fwd.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD_INFO \
-( add_assign, full_barrier, additive )
+( add_assign, full_fence, additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/detail/add_assign_default
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/detail/add_assign_default (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/add_assign/detail/add_assign_default 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_default.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_INFO \
-( add_assign, full_barrier, + )
+( add_assign, full_fence, + )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/assign/assign.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/assign/assign.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/assign/assign.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -24,7 +24,7 @@
#include <boost/act/interlocked/detail/impl.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_IMPL_INFO \
-( assign, full_barrier )
+( assign, full_fence )
#include BOOST_ACT_INTERLOCKED_DETAIL_IMPL_BEGIN()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/assign_if_was/assign_if_was.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/assign_if_was/assign_if_was.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/assign_if_was/assign_if_was.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -24,7 +24,7 @@
#include <boost/act/interlocked/detail/impl.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_IMPL_INFO \
-( assign_if_was, full_barrier )
+( assign_if_was, full_fence )
#include BOOST_ACT_INTERLOCKED_DETAIL_IMPL_BEGIN()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/bitand_assign.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/bitand_assign.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/bitand_assign.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_INFO \
-( bitand_assign, full_barrier, not_additive )
+( bitand_assign, full_fence, not_additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/bitand_assign_fwd.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/bitand_assign_fwd.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/bitand_assign_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder_fwd.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD_INFO \
-( bitand_assign, full_barrier, not_additive )
+( bitand_assign, full_fence, not_additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/detail/bitand_assign_default.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/detail/bitand_assign_default.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitand_assign/detail/bitand_assign_default.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_default.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_INFO \
-( bitand_assign, full_barrier, & )
+( bitand_assign, full_fence, & )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/bitor_assign.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/bitor_assign.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/bitor_assign.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_INFO \
-( bitor_assign, full_barrier, not_additive )
+( bitor_assign, full_fence, not_additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/bitor_assign_fwd.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/bitor_assign_fwd.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/bitor_assign_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder_fwd.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD_INFO \
-( bitor_assign, full_barrier, not_additive )
+( bitor_assign, full_fence, not_additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/detail/bitor_assign_default.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/detail/bitor_assign_default.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/bitor_assign/detail/bitor_assign_default.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_default.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_INFO \
-( bitor_assign, full_barrier, | )
+( bitor_assign, full_fence, | )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/decrement/decrement.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/decrement/decrement.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/decrement/decrement.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -11,7 +11,7 @@
#include <boost/act/interlocked/detail/unary_forwarder.hpp>
-#define BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER_INFO ( decrement, full_barrier )
+#define BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER_INFO ( decrement, full_fence )
#include BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/decrement/decrement_fwd.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/decrement/decrement_fwd.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/decrement/decrement_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -11,7 +11,7 @@
#include <boost/act/interlocked/detail/unary_forwarder.hpp>
-#define BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER_FWD_INFO ( decrement, full_barrier )
+#define BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER_FWD_INFO ( decrement, full_fence )
#include BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER_FWD()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/binary_default.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/binary_default.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/binary_default.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -10,7 +10,7 @@
#ifndef BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_IS_READY_FOR_CLEANUP
//#error Improper incusion of interlocked implementation header. Contact Boost.
#else
-#undef BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_IS_FULL_BARRIER
+#undef BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_IS_FULL_FENCE
#undef BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_OP
#undef BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_FULL_NAME
#undef BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_SEMANTICS
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/binary_result_dont_include.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/binary_result_dont_include.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/binary_result_dont_include.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -18,7 +18,7 @@
#include <boost/act/interlocked/detail/cas_support.hpp>
-#ifdef BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA
+#ifdef BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT
#include <boost/preprocessor/cat.hpp>
#include <boost/preprocessor/stringize.hpp>
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/cas_support.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/cas_support.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/cas_support.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -9,9 +9,9 @@
#ifndef BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_HPP
#define BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_HPP
-#include <boost/act/interlocked/detail/cas_support_data.hpp>
+#include <boost/act/interlocked/detail/implementation_info/operation_support.hpp>
-#ifdef BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA
+#ifdef BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT
#include <climits>
#include <boost/act/interlocked/detail/interlocked_operand_validators.hpp>
@@ -36,18 +36,18 @@
#define BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_NAME \
BOOST_PP_TUPLE_ELEM( BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_NUM_PARAMS \
- , 0, BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA \
+ , 0, BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT \
)
#define BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_SEQ \
BOOST_PP_TUPLE_ELEM( BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_NUM_PARAMS \
- , 1, BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA \
+ , 1, BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT \
)
#define BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_CAS_RETURN \
BOOST_PP_TUPLE_ELEM( BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_NUM_PARAMS \
- , 2, BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA \
+ , 2, BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT \
)
// ToDo: Remove this eventually
@@ -56,21 +56,21 @@
#define BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_RETRIEVE_INFO \
BOOST_PP_TUPLE_ELEM( BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_NUM_PARAMS \
- , 3, BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA \
+ , 3, BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT \
)
#ifndef BOOST_ACT_INTERLOCKED_FORCE_DEFAULTS
#define BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_IMPL_INFO \
BOOST_PP_TUPLE_ELEM( BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_NUM_PARAMS \
- , 4, BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA \
+ , 4, BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT \
)
#else
#define BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_IMPL_INFO \
-( ( assign, ( full_barrier ) ) ) \
-( ( assign_if_was, ( full_barrier ) ) )
+( ( assign, ( full_fence ) ) ) \
+( ( assign_if_was, ( full_fence ) ) )
#endif
@@ -95,7 +95,7 @@
#define BOOST_ACT_INTERLOCKED_DETAIL_SEMANTIC_ID_0 0
#define BOOST_ACT_INTERLOCKED_DETAIL_SEMANTIC_ID_acquire 1
#define BOOST_ACT_INTERLOCKED_DETAIL_SEMANTIC_ID_release 2
-#define BOOST_ACT_INTERLOCKED_DETAIL_SEMANTIC_ID_full_barrier 3
+#define BOOST_ACT_INTERLOCKED_DETAIL_SEMANTIC_ID_full_fence 3
#define BOOST_ACT_INTERLOCKED_DETAIL_COMPARE( data, elem ) \
BOOST_PP_EQUAL \
@@ -162,7 +162,7 @@
, BOOST_PP_CAT( BOOST_ACT_INTERLOCKED_DETAIL_SEMANTIC_ID_, semantics ) \
) \
, BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_IMPL_INFO \
- ((0,(acquire)(release)(full_barrier))) \
+ ((0,(acquire)(release)(full_fence))) \
) \
) \
, 2 \
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/cas_support_data.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/cas_support_data.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/cas_support_data.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -39,7 +39,7 @@
// -or-
// release, meanining there is an one for release semantics
// -or-
-// full_barrier, meanining there is one for full barrier semantics
+// full_fence, meanining there is one for full barrier semantics
//
#include <boost/config.hpp>
@@ -55,8 +55,8 @@
// Note: Same name as vista windows on purpose
#define BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA \
( windows,(32),old_value,volatile_retrieve \
- , ( ( assign, ( full_barrier ) ) ) \
- ( ( assign_if_was, ( full_barrier ) ) ) \
+ , ( ( assign, ( full_fence ) ) ) \
+ ( ( assign_if_was, ( full_fence ) ) ) \
)
#else // Windows Vista and higher
@@ -64,8 +64,8 @@
// Note: Same name as pre-vista windows on purpose
#define BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA \
( windows,(32)(64),old_value,volatile_retrieve \
- , ( ( assign, ( full_barrier )( acquire ) ) ) \
- ( ( assign_if_was, ( full_barrier )( acquire )( release ) ) ) \
+ , ( ( assign, ( full_fence )( acquire ) ) ) \
+ ( ( assign_if_was, ( full_fence )( acquire )( release ) ) ) \
)
#endif // End WINVER checks
@@ -77,8 +77,8 @@
// Note: Same name as x64 on purpose
#define BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA \
( gcc_x86,(32),old_value,volatile_retrieve \
- , ( ( assign, ( full_barrier ) ) ) \
- ( ( assign_if_was, ( full_barrier ) ) ) \
+ , ( ( assign, ( full_fence ) ) ) \
+ ( ( assign_if_was, ( full_fence ) ) ) \
)
#elif defined( __x86_64__ )
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/default_unary_impl.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/default_unary_impl.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/default_unary_impl.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -16,7 +16,7 @@
#define BOOST_ACT_INTERLOCKED_DETAIL_RESULT_SEMANTICS \
BOOST_PP_TUPLE_ELEM( 3, 1, BOOST_ACT_INTERLOCKED_DETAIL_RESULT_INFO )
-#define BOOST_ACT_INTERLOCKED_DETAIL_RESULT_AFFIX_full_barrier() 0
+#define BOOST_ACT_INTERLOCKED_DETAIL_RESULT_AFFIX_full_fence() 0
#define BOOST_ACT_INTERLOCKED_DETAIL_RESULT_AFFIX_acquire() 1
#define BOOST_ACT_INTERLOCKED_DETAIL_RESULT_AFFIX_release() 2
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/full_name.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/full_name.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/full_name.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,10 +12,11 @@
#include <boost/preprocessor/cat.hpp>
#include <boost/preprocessor/control/if.hpp>
-#define BOOST_ACT_INTERLOCKED_DETAIL_AFFIX_full_barrier 0
-#define BOOST_ACT_INTERLOCKED_DETAIL_AFFIX_acquire 1
-#define BOOST_ACT_INTERLOCKED_DETAIL_AFFIX_release 2
-#define BOOST_ACT_INTERLOCKED_DETAIL_AFFIX_dummy 0
+#define BOOST_ACT_INTERLOCKED_DETAIL_AFFIX_full_fence 0
+#define BOOST_ACT_INTERLOCKED_DETAIL_AFFIX_acquire 1
+#define BOOST_ACT_INTERLOCKED_DETAIL_AFFIX_release 2
+#define BOOST_ACT_INTERLOCKED_DETAIL_AFFIX_raw 3
+#define BOOST_ACT_INTERLOCKED_DETAIL_AFFIX_dummy 0
#define BOOST_ACT_INTERLOCKED_DETAIL_FULL_NAME( name, semantics ) \
BOOST_PP_IF( BOOST_PP_CAT( BOOST_ACT_INTERLOCKED_DETAIL_AFFIX_ \
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/implementation_info/compiler_fence_support.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/implementation_info/compiler_fence_support.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,33 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_DETAIL_IMPLEMENTATION_INFO_COMPILER_FENCE_SUPP_HPP
+#define BOOST_ACT_INTERLOCKED_DETAIL_IMPLEMENTATION_INFO_COMPILER_FENCE_SUPP_HPP
+
+#include <boost/config.hpp>
+
+#ifdef BOOST_WINDOWS
+
+ #if WINVER >= 0x0600 // Windows Vista
+
+ // Note: Same name as vista windows on purpose
+ #define BOOST_ACT_INTERLOCKED_DETAIL_COMPILER_FENCE_SUPPORT \
+ ( vista, ( full_fence )( load_fence )( store_fence ) )
+
+ #endif // End WINVER checks
+
+#elif defined( __GNUC__ ) // if gcc
+
+ #define BOOST_ACT_INTERLOCKED_DETAIL_COMPILER_FENCE_SUPPORT \
+ ( gcc, ( full_fence ) )
+
+#endif
+
+// Note: If no support is detected, the implementation automatically uses fences
+
+#endif
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/implementation_info/fence_support.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/implementation_info/fence_support.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,39 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_DETAIL_IMPLEMENTATION_INFO_FENCE_SUPPORT_HPP
+#define BOOST_ACT_INTERLOCKED_DETAIL_IMPLEMENTATION_INFO_FENCE_SUPPORT_HPP
+
+#include <boost/config.hpp>
+
+#ifdef BOOST_WINDOWS
+
+ #if WINVER >= 0x0600 // Windows Vista
+
+ // Note: Same name as vista windows on purpose
+ #define BOOST_ACT_INTERLOCKED_DETAIL_FENCE_SUPPORT \
+ ( vista, ( full_fence )( load_fence )( store_fence ) )
+
+ #else
+
+ // ToDo: Add support (SSE sfence, SSE2 lfence, mfence)
+
+ #endif // End WINVER checks
+
+#elif defined( __GNUC__ ) // if gcc
+
+ // ToDo: Add support (SSE sfence, SSE2 lfence, mfence)
+
+#elif defined( _OPENMP ) // Else, resort to OpenMP (full fence only, via flush)
+
+ #define BOOST_ACT_INTERLOCKED_DETAIL_FENCE_SUPPORT \
+ ( openmp, ( full_fence ) )
+
+#endif
+
+#endif
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/implementation_info/operation_support.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/implementation_info/operation_support.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,90 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_DETAIL_IMPLEMENTATION_INFO_OPERATION_SUPPORT_HPP
+#define BOOST_ACT_INTERLOCKED_DETAIL_IMPLEMENTATION_INFO_OPERATION_SUPPORT_HPP
+
+// Note: BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT has the form
+//
+// ( name, valid_bit_count_for_cas, cas_return, retrieve_info
+// , custom_implementations
+// )
+//
+// Where valid_bit_count_for_cas is a Boost.Preprocessor sequence of object
+// sizes in bits which may be used with the underlying cas operation
+//
+// Where cas_return is either:
+// old_value, meaning the old value is returned from assign_if_was_impl
+// -or-
+// success_value, meaning it returns true if the operation was successful
+//
+// Where retrieve_info is either:
+// volatile_retrieve, meaning interlocked::retrieve is automatically
+// implemented to access the passed object with added volatile qualification
+// -or-
+// custom_retrieve, meaning interlocked::retrieve does not have a default
+// implementation and must be provided by the implementor
+//
+// Where custom_implementations is a preprocessor sequence of tuples of the form
+// ( function_name, semantice_sequence )
+// Where function_name is the name of a function with a custom implmentation
+//
+// Where semantic_sequence is a sequence whose elements are each one of:
+// acquire, meanining there is an implementation for acquire semantics
+// -or-
+// release, meanining there is an one for release semantics
+// -or-
+// full_fence, meanining there is one for full barrier semantics
+//
+
+#include <boost/config.hpp>
+
+#ifdef BOOST_WINDOWS
+
+ // ToDo: Only use volatile_retrieve if VC 8.0 or higher
+
+ #if WINVER < 0x0600 // Windows prior to vista
+
+ // Note: Same name as vista windows on purpose
+ #define BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT \
+ ( windows,(32),old_value,volatile_retrieve \
+ , ( ( assign, ( full_fence ) ) ) \
+ ( ( assign_if_was, ( full_fence ) ) ) \
+ )
+
+ #else // Windows Vista and higher
+
+ // Note: Same name as pre-vista windows on purpose
+ #define BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT \
+ ( windows,(32)(64),old_value,volatile_retrieve \
+ , ( ( assign, ( full_fence )( acquire ) ) ) \
+ ( ( assign_if_was, ( full_fence )( acquire )( release ) ) ) \
+ )
+
+ #endif // End WINVER checks
+
+#elif defined( __GNUC__ )
+
+ #if defined( __i386__ )
+
+ // Note: Same name as x64 on purpose
+ #define BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT \
+ ( gcc_x86,(32),old_value,volatile_retrieve \
+ , ( ( assign, ( full_fence ) ) ) \
+ ( ( assign_if_was, ( full_fence ) ) ) \
+ )
+
+ #elif defined( __x86_64__ )
+
+ #error GCC not supported for 64-bit.
+
+ #endif
+
+#endif // End OS checks
+
+#endif
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/unary_result_impl.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/unary_result_impl.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/detail/unary_result_impl.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/cas_support.hpp>
-#ifdef BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA
+#ifdef BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT
#include <boost/type_traits/remove_volatile.hpp>
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/increment/increment.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/increment/increment.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/increment/increment.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -11,7 +11,7 @@
#include <boost/act/interlocked/detail/unary_forwarder.hpp>
-#define BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER_INFO ( increment, full_barrier )
+#define BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER_INFO ( increment, full_fence )
#include BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/increment/increment_fwd.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/increment/increment_fwd.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/increment/increment_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -11,7 +11,7 @@
#include <boost/act/interlocked/detail/unary_forwarder.hpp>
-#define BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER_FWD_INFO ( increment, full_barrier )
+#define BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER_FWD_INFO ( increment, full_fence )
#include BOOST_ACT_INTERLOCKED_DETAIL_UNARY_FORWARDER_FWD()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/detail/lshift_assign_default.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/detail/lshift_assign_default.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/detail/lshift_assign_default.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_default.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_INFO \
-( lshift_assign, full_barrier, << )
+( lshift_assign, full_fence, << )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/lshift_assign.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/lshift_assign.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/lshift_assign.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_INFO \
-( lshift_assign, full_barrier, not_additive )
+( lshift_assign, full_fence, not_additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/lshift_assign_fwd.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/lshift_assign_fwd.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/lshift_assign/lshift_assign_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder_fwd.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD_INFO \
-( lshift_assign, full_barrier, not_additive )
+( lshift_assign, full_fence, not_additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD()
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,16 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_MODIFY_HPP
+#define BOOST_ACT_INTERLOCKED_MODIFY_HPP
+
+#include <boost/act/interlocked/modify/modify.hpp>
+#include <boost/act/interlocked/modify/modify_acquire.hpp>
+#include <boost/act/interlocked/modify/modify_release.hpp>
+
+#endif
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,48 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_HPP
+#define BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_HPP
+
+#include <boost/act/interlocked/assign_if_was/assign_if_was.hpp>
+#include <boost/act/interlocked/detail/cas_support.hpp>
+#include <boost/type_traits/remove_cv.hpp>
+#include <boost/utility/enable_if.hpp>
+
+namespace boost { namespace act { namespace interlocked {
+
+template< typename TargetType, typename OperationType >
+typename lazy_enable_if
+<
+ detail::are_valid_assign_style_params< TargetType >
+, remove_cv< TargetType >
+>
+::type
+modify( TargetType& destination, OperationType operation )
+{
+ typedef typename remove_cv< TargetType >::type unqualified_type;
+ unqualified_type new_value;
+
+ for( unqualified_type curr_value = interlocked::retrieve( target )
+ ; ( new_value = interlocked::assign_if_was
+ ( target
+ , operation( curr_value )
+ , curr_value
+ )
+ )
+ != curr_value
+ ; curr_value = new_value
+ );
+
+ // Note: new_value is the old value here
+ return new_value;
+}
+
+} } }
+
+#endif
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_acquire.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_acquire.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,48 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_ACQUIRE_HPP
+#define BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_ACQUIRE_HPP
+
+#include <boost/act/interlocked/assign_if_was/assign_if_was_acquire.hpp>
+#include <boost/act/interlocked/detail/cas_support.hpp>
+#include <boost/type_traits/remove_cv.hpp>
+#include <boost/utility/enable_if.hpp>
+
+namespace boost { namespace act { namespace interlocked {
+
+template< typename TargetType, typename OperationType >
+typename lazy_enable_if
+<
+ detail::are_valid_assign_style_params< TargetType >
+, remove_cv< TargetType >
+>
+::type
+modify_acquire( TargetType& destination, OperationType operation )
+{
+ typedef typename remove_cv< TargetType >::type unqualified_type;
+ unqualified_type new_value;
+
+ for( unqualified_type curr_value = interlocked::retrieve( target )
+ ; ( new_value = interlocked::assign_if_was_acquire
+ ( target
+ , operation( curr_value )
+ , curr_value
+ )
+ )
+ != curr_value
+ ; curr_value = new_value
+ );
+
+ // Note: new_value is the old value here
+ return new_value;
+}
+
+} } }
+
+#endif
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_acquire_fwd.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_acquire_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,29 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_ACQUIRE_FWD_HPP
+#define BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_ACQUIRE_FWD_HPP
+
+#include <boost/act/interlocked/detail/cas_support.hpp>
+#include <boost/type_traits/remove_cv.hpp>
+#include <boost/utility/enable_if.hpp>
+
+namespace boost { namespace act { namespace interlocked {
+
+template< typename TargetType, typename OperationType >
+typename lazy_enable_if
+<
+ detail::are_valid_assign_style_params< TargetType >
+, remove_cv< TargetType >
+>
+::type
+modify_acquire( TargetType& destination, OperationType operation );
+
+} } }
+
+#endif
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_fwd.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,29 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_FWD_HPP
+#define BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_FWD_HPP
+
+#include <boost/act/interlocked/detail/cas_support.hpp>
+#include <boost/type_traits/remove_cv.hpp>
+#include <boost/utility/enable_if.hpp>
+
+namespace boost { namespace act { namespace interlocked {
+
+template< typename TargetType, typename OperationType >
+typename lazy_enable_if
+<
+ detail::are_valid_assign_style_params< TargetType >
+, remove_cv< TargetType >
+>
+::type
+modify( TargetType& destination, OperationType operation );
+
+} } }
+
+#endif
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_release.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_release.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,48 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_RELEASE_HPP
+#define BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_RELEASE_HPP
+
+#include <boost/act/interlocked/assign_if_was/assign_if_was_release.hpp>
+#include <boost/act/interlocked/detail/cas_support.hpp>
+#include <boost/type_traits/remove_cv.hpp>
+#include <boost/utility/enable_if.hpp>
+
+namespace boost { namespace act { namespace interlocked {
+
+template< typename TargetType, typename OperationType >
+typename lazy_enable_if
+<
+ detail::are_valid_assign_style_params< TargetType >
+, remove_cv< TargetType >
+>
+::type
+modify_release( TargetType& destination, OperationType operation )
+{
+ typedef typename remove_cv< TargetType >::type unqualified_type;
+ unqualified_type new_value;
+
+ for( unqualified_type curr_value = interlocked::retrieve( target )
+ ; ( new_value = interlocked::assign_if_was_release
+ ( target
+ , operation( curr_value )
+ , curr_value
+ )
+ )
+ != curr_value
+ ; curr_value = new_value
+ );
+
+ // Note: new_value is the old value here
+ return new_value;
+}
+
+} } }
+
+#endif
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_release_fwd.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify/modify_release_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,29 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_RELEASE_FWD_HPP
+#define BOOST_ACT_INTERLOCKED_MODIFY_MODIFY_RELEASE_FWD_HPP
+
+#include <boost/act/interlocked/detail/cas_support.hpp>
+#include <boost/type_traits/remove_cv.hpp>
+#include <boost/utility/enable_if.hpp>
+
+namespace boost { namespace act { namespace interlocked {
+
+template< typename TargetType, typename OperationType >
+typename lazy_enable_if
+<
+ detail::are_valid_assign_style_params< TargetType >
+, remove_cv< TargetType >
+>
+::type
+modify_release( TargetType& destination, OperationType operation );
+
+} } }
+
+#endif
Added: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify_fwd.hpp
==============================================================================
--- (empty file)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/modify_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -0,0 +1,16 @@
+/*=============================================================================
+ Copyright (c) 2006, 2007 Matthew Calabrese
+
+ Use, modification and distribution is subject to the Boost Software
+ License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+ http://www.boost.org/LICENSE_1_0.txt)
+==============================================================================*/
+
+#ifndef BOOST_ACT_INTERLOCKED_MODIFY_FWD_HPP
+#define BOOST_ACT_INTERLOCKED_MODIFY_FWD_HPP
+
+#include <boost/act/interlocked/modify/modify_fwd.hpp>
+#include <boost/act/interlocked/modify/modify_acquire_fwd.hpp>
+#include <boost/act/interlocked/modify/modify_release_fwd.hpp>
+
+#endif
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/retrieve/detail/retrieve_default.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/retrieve/detail/retrieve_default.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/retrieve/detail/retrieve_default.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -11,7 +11,7 @@
#include <boost/act/interlocked/detail/cas_support.hpp>
-#ifdef BOOST_ACT_INTERLOCKED_DETAIL_CAS_SUPPORT_DATA
+#ifdef BOOST_ACT_INTERLOCKED_DETAIL_OPERATION_SUPPORT
#if BOOST_ACT_INTERLOCKED_DETAIL_HAS_VOLATILE_RETRIEVE // If: volatile impl
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/detail/rshift_assign_default.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/detail/rshift_assign_default.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/detail/rshift_assign_default.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_default.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_INFO \
-( rshift_assign, full_barrier, >> )
+( rshift_assign, full_fence, >> )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/rshift_assign.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/rshift_assign.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/rshift_assign.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_INFO \
-( rshift_assign, full_barrier, not_additive )
+( rshift_assign, full_fence, not_additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/rshift_assign_fwd.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/rshift_assign_fwd.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/rshift_assign/rshift_assign_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder_fwd.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD_INFO \
-( rshift_assign, full_barrier, not_additive )
+( rshift_assign, full_fence, not_additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/detail/subtract_assign_default
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/detail/subtract_assign_default (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/detail/subtract_assign_default 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_default.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_INFO \
-( subtract_assign, full_barrier, - )
+( subtract_assign, full_fence, - )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/subtract_assign.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/subtract_assign.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/subtract_assign.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_INFO \
-( subtract_assign, full_barrier, additive )
+( subtract_assign, full_fence, additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/subtract_assign_fwd.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/subtract_assign_fwd.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/subtract_assign/subtract_assign_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder_fwd.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD_INFO \
-( subtract_assign, full_barrier, additive )
+( subtract_assign, full_fence, additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/detail/xor_assign_default.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/detail/xor_assign_default.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/detail/xor_assign_default.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_default.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT_INFO \
-( xor_assign, full_barrier, ^ )
+( xor_assign, full_fence, ^ )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_DEFAULT()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/xor_assign.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/xor_assign.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/xor_assign.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_INFO \
-( xor_assign, full_barrier, not_additive )
+( xor_assign, full_fence, not_additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER()
Modified: sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/xor_assign_fwd.hpp
==============================================================================
--- sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/xor_assign_fwd.hpp (original)
+++ sandbox/SOC/2006/concurrency/trunk/boost/act/interlocked/xor_assign/xor_assign_fwd.hpp 2007-06-22 13:28:20 EDT (Fri, 22 Jun 2007)
@@ -12,7 +12,7 @@
#include <boost/act/interlocked/detail/binary_forwarder_fwd.hpp>
#define BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD_INFO \
-( xor_assign, full_barrier, not_additive )
+( xor_assign, full_fence, not_additive )
#include BOOST_ACT_INTERLOCKED_DETAIL_BINARY_FORWARDER_FWD()
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk