intrusive MultiLevelHashSet fixes, tests
authorkhizmax <libcds.dev@gmail.com>
Sun, 2 Aug 2015 19:50:42 +0000 (22:50 +0300)
committerkhizmax <libcds.dev@gmail.com>
Sun, 2 Aug 2015 19:50:42 +0000 (22:50 +0300)
Added MS VC++ linker flag

21 files changed:
.gitignore
cds/algo/split_bitstring.h [new file with mode: 0644]
cds/intrusive/details/multilevel_hashset_base.h
cds/intrusive/impl/multilevel_hashset.h
projects/Win/vc12/cds.vcxproj
projects/Win/vc12/cds.vcxproj.filters
projects/Win/vc12/hdr-test-deque.vcxproj
projects/Win/vc12/hdr-test-list.vcxproj
projects/Win/vc12/hdr-test-map.vcxproj
projects/Win/vc12/hdr-test-misc.vcxproj
projects/Win/vc12/hdr-test-priority_queue.vcxproj
projects/Win/vc12/hdr-test-queue.vcxproj
projects/Win/vc12/hdr-test-set.vcxproj
projects/Win/vc12/hdr-test-set.vcxproj.filters
projects/Win/vc12/hdr-test-stack.vcxproj
projects/Win/vc12/hdr-test-striped-set.vcxproj
projects/Win/vc12/hdr-test-tree.vcxproj
projects/source.test-hdr.mk
tests/test-hdr/set/hdr_intrusive_michael_set_hp.cpp
tests/test-hdr/set/hdr_intrusive_multilevel_hashset.h [new file with mode: 0644]
tests/test-hdr/set/hdr_intrusive_multilevel_hashset_hp.cpp [new file with mode: 0644]

index 1b5d9a11c5d001b5296bc293bb30aeb092ca087e..ef8a1bd4625b350327f9269ca541ab53fae9df0b 100644 (file)
@@ -7,7 +7,6 @@
 /tests/cppunit/*.o
 *.o
 *.d
-/todo-2.0.txt
 /tests/data/dictionary.txt
 /bin
 obj
diff --git a/cds/algo/split_bitstring.h b/cds/algo/split_bitstring.h
new file mode 100644 (file)
index 0000000..51590e2
--- /dev/null
@@ -0,0 +1,138 @@
+//$$CDS-header$$
+
+#ifndef CDSLIB_ALGO_SPLIT_BITSTRING_H
+#define CDSLIB_ALGO_SPLIT_BITSTRING_H
+
+#include <cds/algo/base.h>
+
+namespace cds { namespace algo { 
+
+    /// Cuts a bit sequence from fixed-size bit-string
+    /**
+        The splitter an be used as iterator over bit-string.
+        Each call of \p cut() or \p safe_cut() cuts the bit count specified
+        and keeps the position inside bit-string for the next call.
+
+        The splitter stores a const reference to bit-string, not a copy.
+        The maximum count of bits that can be cut for single call is <tt> sizeof(UInt) * 8 </tt>
+    */
+    template <typename BitString, typename UInt = size_t >
+    class split_bitstring
+    {
+    public:
+        typedef BitString bitstring;    ///< Bit-string type
+        typedef UInt      uint_type;    ///< Bit-string portion type
+
+        //@cond
+        static CDS_CONSTEXPR size_t const c_nHashSize   = (sizeof(bitstring) + sizeof(uint_type) - 1) / sizeof(uint_type);
+        static CDS_CONSTEXPR size_t const c_nBitPerByte = 8;
+        static CDS_CONSTEXPR size_t const c_nBitPerHash = sizeof(bitstring) * c_nBitPerByte;
+        static CDS_CONSTEXPR size_t const c_nBitPerInt  = sizeof(uint_type) * c_nBitPerByte;
+        //@endcond
+
+    public:
+        /// Initializises the splitter with reference to \p h
+        explicit split_bitstring( bitstring const& h )
+            : m_ptr(reinterpret_cast<uint_type const*>( &h ))
+            , m_pos(0)
+            , m_first( m_ptr )
+#   ifdef _DEBUG
+            , m_last( m_ptr + c_nHashSize )
+#   endif
+        {}
+
+        /// Returns \p true if end-of-string is not reached yet
+        explicit operator bool() const
+        {
+            return !eos();
+        }
+
+        /// Returns \p true if end-of-stream encountered
+        bool eos() const
+        {
+            return m_pos >= c_nBitPerHash;
+        }
+
+        /// Cuts next \p nBits from bit-string
+        /**
+            Precondition: <tt>nBits <= sizeof(uint_type) * 8</tt>
+
+            This function does not manage out-of-bound condition.
+            To control that use \p safe_cut().
+        */
+        uint_type cut( size_t nBits )
+        {
+            assert( !eos() );
+            assert( nBits <= c_nBitPerInt );
+            assert( m_pos + nBits <= c_nBitPerHash );
+#   ifdef _DEBUG
+            assert( m_ptr < m_last );
+#   endif
+            uint_type result;
+
+            size_t const nRest = c_nBitPerInt - m_pos % c_nBitPerInt;
+            m_pos += nBits;
+            if ( nBits < nRest ) {
+                result = *m_ptr << ( nRest - nBits );
+                result = result >> ( c_nBitPerInt - nBits );
+            }
+            else if ( nBits == nRest ) {
+                result = *m_ptr >> ( c_nBitPerInt - nRest );
+                ++m_ptr;
+            }
+            else {
+                size_t const lsb = *m_ptr >> ( c_nBitPerInt - nRest );
+                nBits -= nRest;
+                ++m_ptr;
+
+                result = *m_ptr << ( c_nBitPerInt - nBits );
+                result = result >> ( c_nBitPerInt - nBits );
+                result = (result << nRest) + lsb;
+            }
+
+            assert( m_pos <= c_nBitPerHash );
+#   ifdef _DEBUG
+            assert( m_ptr <= m_last );
+#   endif
+            return result;
+        }
+
+        /// Cuts up to \p nBits from the bit-string
+        /**
+            Analog of \p cut() but if \p nBits is more than the rest of bit-string,
+            only the rest is returned.
+            If \p eos() is \p true the function returns 0.
+        */
+        uint_type safe_cut( size_t nBits )
+        {
+            if ( eos() )
+                return 0;
+
+            assert( nBits <= sizeof(uint_type) * c_nBitPerByte );
+
+            if ( m_pos + nBits > c_nBitPerHash )
+                nBits = c_nBitPerHash - m_pos;
+            return nBits ? cut( nBits ) : 0;
+        }
+
+        /// Resets the splitter
+        void reset()
+        {
+            m_ptr = m_first;
+            m_pos = 0;
+        }
+
+    private:
+        //@cond
+        uint_type const* m_ptr;  ///< current position in the hash
+        size_t           m_pos;  ///< current position in bits
+        uint_type const* m_first; ///< first position
+#   ifdef _DEBUG
+        uint_type const* m_last;  ///< last position
+#   endif
+        //@endcond
+    };
+
+}} // namespace cds::algo
+
+#endif // #ifndef CDSLIB_ALGO_SPLIT_BITSTRING_H
index 6bb8768869a5720c2f2ce87ea9ca6e0003ee0241..63d57bb4847c31fc8aeedb3f951a912dfcb8c767 100644 (file)
@@ -5,9 +5,11 @@
 
 #include <memory.h> // memcmp, memcpy
 #include <type_traits>
+
 #include <cds/intrusive/details/base.h>
 #include <cds/opt/compare.h>
 #include <cds/algo/atomic.h>
+#include <cds/algo/split_bitstring.h>
 #include <cds/details/marked_ptr.h>
 #include <cds/urcu/options.h>
 
@@ -83,6 +85,7 @@ namespace cds { namespace intrusive {
             event_counter   m_nSlotChanged;     ///< Number of array node slot changing by other thread during an operation
             event_counter   m_nSlotConverting;  ///< Number of events when we encounter a slot while it is converting to array node
 
+            //@cond
             void onInsertSuccess()              { ++m_nInsertSuccess;       }
             void onInserFailed()                { ++m_nInsertFailed;        }
             void onInsertRetry()                { ++m_nInsertRetry;         }
@@ -93,13 +96,14 @@ namespace cds { namespace intrusive {
             void onEraseSuccess()               { ++m_nEraseSuccess;        }
             void onEraseFailed()                { ++m_nEraseFailed;         }
             void onEraseRetry()                 { ++m_nEraseRetry;          }
-            void onFindSuccess()                { ++m_nFinSuccess;          }
+            void onFindSuccess()                { ++m_nFindSuccess;         }
             void onFindFailed()                 { ++m_nFindFailed;          }
 
             void onExpandNodeSuccess()          { ++m_nExpandNodeSuccess;   }
             void onExpandNodeFailed()           { ++m_nExpandNodeFailed;    }
             void onSlotChanged()                { ++m_nSlotChanged;         }
             void onSlotConverting()             { ++m_nSlotConverting;      }
+            //@endcond
         };
 
         /// \p MultiLevelHashSet empty internal statistics
@@ -266,6 +270,13 @@ namespace cds { namespace intrusive {
         template <typename T>
         struct bitwise_compare
         {
+            /// Compares \p lhs and \p rhs
+            /**
+                Returns:
+                - <tt> < 0</tt> if <tt>lhs < rhs</tt>
+                - <tt>0</tt> if <tt>lhs == rhs</tt>
+                - <tt> > 0</tt> if <tt>lhs > rhs</tt>
+            */
             int operator()( T const& lhs, T const& rhs ) const
             {
                 return memcmp( &lhs, &rhs, sizeof(T));
@@ -275,99 +286,7 @@ namespace cds { namespace intrusive {
         //@cond
         namespace details {
             template <typename HashType, typename UInt = size_t >
-            class hash_splitter
-            {
-            public:
-                typedef HashType hash_type;
-                typedef UInt     uint_type;
-
-                static CDS_CONSTEXPR size_t const c_nHashSize   = (sizeof(hash_type) + sizeof(uint_type) - 1) / sizeof(uint_type);
-                static CDS_CONSTEXPR size_t const c_nBitPerByte = 8;
-                static CDS_CONSTEXPR size_t const c_nBitPerHash = sizeof(hash_type) * c_nBitPerByte;
-                static CDS_CONSTEXPR size_t const c_nBitPerInt  = sizeof(uint_type) * c_nBitPerByte;
-
-            public:
-                explicit hash_splitter( hash_type const& h )
-                    : m_ptr(reinterpret_cast<uint_type const*>( &h ))
-                    , m_pos(0)
-                    , m_first( m_ptr )
-#           ifdef _DEBUG
-                    , m_last( m_ptr + c_nHashSize )
-#           endif
-                {}
-
-                explicit operator bool() const
-                {
-                    return !eos();
-                }
-
-                // end-of-bitstring
-                bool eos() const
-                {
-                    return m_pos >= c_nBitPerHash;
-                }
-
-                uint_type cut( size_t nBits )
-                {
-                    assert( !eos() );
-                    assert( nBits <= c_nBitPerInt );
-                    assert( m_pos + nBits <= c_nBitPerHash );
-#           ifdef _DEBUG
-                    assert( m_ptr < m_last );
-#           endif
-                    uint_type result;
-
-                    size_t const nRest = c_nBitPerInt - m_pos % c_nBitPerInt;
-                    m_pos += nBits;
-                    if ( nBits < nRest ) {
-                        result = *m_ptr << ( nRest - nBits );
-                        result = result >> ( c_nBitPerInt - nBits );
-                    }
-                    else if ( nBits == nRest ) {
-                        result = *m_ptr >> ( c_nBitPerInt - nRest );
-                        ++m_ptr;
-                    }
-                    else {
-                        size_t const lsb = *m_ptr >> ( c_nBitPerInt - nRest );
-                        nBits -= nRest;
-                        ++m_ptr;
-
-                        result = *m_ptr << ( c_nBitPerInt - nBits );
-                        result = result >> ( c_nBitPerInt - nBits );
-                        result = (result << nRest) + lsb;
-                    }
-
-                    assert( m_pos <= c_nBitPerHash );
-#           ifdef _DEBUG
-                    assert( m_ptr < m_last );
-#           endif
-                    return result;
-                }
-
-                uint_type safe_cut( size_t nBits )
-                {
-                    assert( !eos() );
-                    assert( nBits <= sizeof(uint_type) * c_nBitPerByte );
-
-                    if ( m_pos + nBits > c_nBitPerHash )
-                        nBits = c_nBitPerHash - m_pos;
-                    return nBits ? cut( nBits ) : 0;
-                }
-
-                void reset()
-                {
-                    m_ptr = m_first;
-                    m_pos = 0;
-                }
-
-            private:
-                uint_type const* m_ptr;  ///< current position in the hash
-                size_t           m_pos;  ///< current position in bits
-                uint_type const* m_first; ///< first position
-#           ifdef _DEBUG
-                uint_type const* m_last;  ///< last position
-#           endif
-            };
+            using hash_splitter = cds::algo::split_bitstring< HashType, UInt >;
         } // namespace details
         //@endcond
 
index f0516ef0c83daef5f0a3bbcc52039d347d866fc5..9f0db90a216ec23697efda925ee28c6106b79cb6 100644 (file)
@@ -65,11 +65,14 @@ namespace cds { namespace intrusive {
           have identical hash then you cannot insert both that keys in the set. \p %MultiLevelHashSet does not maintain the key,\r
           it maintains its fixed-size hash value.\r
 \r
+        Template parameters:\r
+        - \p GC - safe memory reclamation schema. Can be \p gc::HP, \p gc::DHP or one of \ref cds_urcu_type "RCU type"\r
+        - \p T - a value type to be stored in the set\r
+        - \p Traits - type traits, the structure based on \p multilevel_hashset::traits or result of \p multilevel_hashset::make_traits metafunction\r
 \r
         There are several specializations of \p %MultiLevelHashSet for each \p GC. You should include:
         - <tt><cds/intrusive/multilevel_hashset_hp.h></tt> for \p gc::HP garbage collector
         - <tt><cds/intrusive/multilevel_hashset_dhp.h></tt> for \p gc::DHP garbage collector
-        - <tt><cds/intrusive/multilevel_hashset_nogc.h></tt> for \ref cds_intrusive_MultiLevelHashSet_nogc for append-only set
         - <tt><cds/intrusive/multilevel_hashset_rcu.h></tt> for \ref cds_intrusive_MultiLevelHashSet_rcu "RCU type"
     */
     template <
@@ -97,7 +100,7 @@ namespace cds { namespace intrusive {
                 decltype( hash_accessor()( std::declval<T>()) )
             >::type
         >::type hash_type;
-        static_assert( !std::is_pointer<hash_type>, "hash_accessor should return a reference to hash value" );
+        static_assert( !std::is_pointer<hash_type>::value, "hash_accessor should return a reference to hash value" );
 
         typedef typename traits::disposer disposer; ///< data node disposer
 
@@ -218,7 +221,7 @@ namespace cds { namespace intrusive {
             hash_type const& hash = hash_accessor()( val );
             hash_splitter splitter( hash );
             hash_comparator cmp;
-            gc::Guard guard;
+            typename gc::Guard guard;
             back_off bkoff;
 
             atomic_node_ptr * pArr = m_Head;
@@ -267,7 +270,7 @@ namespace cds { namespace intrusive {
                     else {
                         // the slot is empty, try to insert data node
                         node_ptr pNull;
-                        if ( pArr[nSlot].compare_exchange_strong( pNull, node_ptr( &val ), memory_model::memory_order_release, atomics::memory_order_relaxed )
+                        if ( pArr[nSlot].compare_exchange_strong( pNull, node_ptr( &val ), memory_model::memory_order_release, atomics::memory_order_relaxed ))
                         {
                             // the new data node has been inserted
                             f( val );
@@ -305,7 +308,7 @@ namespace cds { namespace intrusive {
             hash_type const& hash = hash_accessor()( val );
             hash_splitter splitter( hash );
             hash_comparator cmp;
-            gc::Guard guard;
+            typename gc::Guard guard;
             back_off bkoff;
 
             atomic_node_ptr * pArr = m_Head;
@@ -363,7 +366,7 @@ namespace cds { namespace intrusive {
                         // the slot is empty, try to insert data node
                         if ( bInsert ) {
                             node_ptr pNull;
-                            if ( pArr[nSlot].compare_exchange_strong( pNull, node_ptr( &val ), memory_model::memory_order_release, atomics::memory_order_relaxed )
+                            if ( pArr[nSlot].compare_exchange_strong( pNull, node_ptr( &val ), memory_model::memory_order_release, atomics::memory_order_relaxed ))
                             {
                                 // the new data node has been inserted
                                 f( val );
@@ -374,7 +377,7 @@ namespace cds { namespace intrusive {
                         }
                         else {
                             m_Stat.onUpdateFailed();
-                            return std:make_pair( false, false );
+                            return std::make_pair( false, false );
                         }
 
                         // insert failed - slot has been changed by another thread
@@ -396,7 +399,7 @@ namespace cds { namespace intrusive {
         {
             typename gc::Guard guard;
             auto pred = [&val](value_type const& item) -> bool { return &item == &val; };
-            value_type * p = do_erase( hash, guard, std::ref( pred ));
+            value_type * p = do_erase( hash_accessor()( val ), guard, std::ref( pred ));
 
             // p is guarded by HP
             if ( p ) {
@@ -637,21 +640,21 @@ namespace cds { namespace intrusive {
 
             metrics m;
             m.head_node_size_log = head_bits;
-            m.head_node_size = 1 << head_bits;
+            m.head_node_size = size_t(1) << head_bits;
             m.array_node_size_log = array_bits;
-            m.array_node_size = 1 << array_bits;
+            m.array_node_size = size_t(1) << array_bits;
             return m;
         }
 
-        template <typename T>
-        static bool check_node_alignment( * p )
+        template <typename Q>
+        static bool check_node_alignment( Q const* p )
         {
             return (reinterpret_cast<uintptr_t>(p) & node_ptr::bitmask) == 0;
         }
 
         atomic_node_ptr * alloc_array_node() const
         {
-            return cxx_array_node_allocator().NewArray( array_node_size(), nullptr )
+            return cxx_array_node_allocator().NewArray( array_node_size(), nullptr );
         }
 
         void free_array_node( atomic_node_ptr * parr ) const
@@ -709,8 +712,8 @@ namespace cds { namespace intrusive {
                     }
                     else {
                         // data node
-                        if ( pArr->compare_exchange_strong( slot, node_ptr(), memory_model::memory_order_acquire, atomics::memory_order_relaxed ) ) {
-                            gc::template retire<disposer>( p );
+                        if ( pArr->compare_exchange_strong( slot, node_ptr(), memory_model::memory_order_acquire, atomics::memory_order_relaxed )) {
+                            gc::template retire<disposer>( slot.ptr() );
                             --m_ItemCounter;
                             m_Stat.onEraseSuccess();
                             break;
@@ -755,7 +758,9 @@ namespace cds { namespace intrusive {
             pArr[idx].store( current, memory_model::memory_order_release );
 
             cur = cur | array_converting;
-            CDS_VERIFY( slot.compare_exchange_strong( cur, node_ptr( to_node( pArr ), array_node ), memory_model::memory_order_release, atomics::memory_order_relaxed )));
+            CDS_VERIFY( 
+                slot.compare_exchange_strong( cur, node_ptr( to_node( pArr ), array_node ), memory_model::memory_order_release, atomics::memory_order_relaxed )
+            );
 
             return std::make_pair( pArr, idx );
         }
@@ -863,4 +868,3 @@ namespace cds { namespace intrusive {
 }} // namespace cds::intrusive
 
 #endif // #ifndef CDSLIB_INTRUSIVE_IMPL_MULTILEVEL_HASHSET_H
-1
\ No newline at end of file
index bb711f02a94ae7bc7187a0598054877775ed8414..1a24a6b60ab1cb6a35eb8b4378cc99eec0356025 100644 (file)
     <ClInclude Include="..\..\..\cds\algo\backoff_strategy.h" />\r
     <ClInclude Include="..\..\..\cds\algo\base.h" />\r
     <ClInclude Include="..\..\..\cds\algo\bitop.h" />\r
+    <ClInclude Include="..\..\..\cds\algo\split_bitstring.h" />\r
     <ClInclude Include="..\..\..\cds\algo\elimination.h" />\r
     <ClInclude Include="..\..\..\cds\algo\elimination_opt.h" />\r
     <ClInclude Include="..\..\..\cds\algo\elimination_tls.h" />\r
index 2548ad5489d64d1161d391b20ab29b6b5efa93b1..1e2b3db79bd214eb3d424e2b55c9e1fabd161df4 100644 (file)
     <ClInclude Include="..\..\..\cds\intrusive\multilevel_hashset_dhp.h">\r
       <Filter>Header Files\cds\intrusive</Filter>\r
     </ClInclude>\r
+    <ClInclude Include="..\..\..\cds\algo\split_bitstring.h">\r
+      <Filter>Header Files\cds\algo</Filter>\r
+    </ClInclude>\r
   </ItemGroup>\r
 </Project>
\ No newline at end of file
index 1193a1eb17bdafc63eb1af86ddfee7e6d95b28fb..0a00c9c46125d502ef4baeb418d337d5ff032789 100644 (file)
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|Win32'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|x64'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|Win32'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugVLD|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemGroup>\r
index 20990826ef8125e08a5aa5fb8661f749f47d80a9..59ea903f7e5667c67ae1684d3392bc1b5d063506 100644 (file)
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|Win32'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|x64'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|Win32'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugVLD|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />\r
index 1956ce57f14ad7d94de529a6e4b583fd107b6d4d..9b26328d68497ae0bbb2d0a8b3f38fcd3b9a4a46 100644 (file)
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|Win32'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|x64'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|Win32'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugVLD|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemGroup>\r
index bb5e61425181260539102195627bd2690ceff77c..0abdd391646002752ba470d00ef3b4644968fbbd 100644 (file)
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|Win32'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|x64'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|Win32'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugVLD|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemGroup>\r
     <ClCompile Include="..\..\..\tests\test-hdr\misc\find_option.cpp" />\r
     <ClCompile Include="..\..\..\tests\test-hdr\misc\hash_tuple.cpp" />\r
     <ClCompile Include="..\..\..\tests\test-hdr\misc\michael_allocator.cpp" />\r
+    <ClCompile Include="..\..\..\tests\test-hdr\misc\split_bitstring.cpp" />\r
     <ClCompile Include="..\..\..\tests\test-hdr\misc\thread_init_fini.cpp" />\r
     <ClCompile Include="..\..\..\tests\test-hdr\misc\permutation_generator.cpp" />\r
   </ItemGroup>\r
index 325b0cfefe6e8c234986cb8a9843e25de513a7c4..4ab19ad16127a28189caa199b4be8336ccab4e5f 100644 (file)
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|Win32'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|x64'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|Win32'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugVLD|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />\r
index 5a7920e3720185a25dda119123c7338ef96bacba..c72ace29b89e5a05b111bb542fc5efb5e19c85a0 100644 (file)
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|Win32'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|x64'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|Win32'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugVLD|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemGroup>\r
index 3eab4e972d6d8e954d9e71bfc7d569466f25d97d..afbd90e8504e7f7bee129d93e39e9d0b6b7fdd26 100644 (file)
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|Win32'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|x64'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|Win32'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugVLD|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemGroup>\r
+    <ClInclude Include="..\..\..\tests\test-hdr\set\hdr_intrusive_multilevel_hashset.h" />\r
     <ClInclude Include="..\..\..\tests\test-hdr\set\hdr_intrusive_set.h" />\r
     <ClInclude Include="..\..\..\tests\test-hdr\set\hdr_intrusive_skiplist_set.h" />\r
     <ClInclude Include="..\..\..\tests\test-hdr\set\hdr_intrusive_skiplist_set_rcu.h" />\r
     <ClCompile Include="..\..\..\tests\test-hdr\set\hdr_intrusive_michael_set_rcu_shb_lazy.cpp" />\r
     <ClCompile Include="..\..\..\tests\test-hdr\set\hdr_intrusive_michael_set_rcu_sht.cpp" />\r
     <ClCompile Include="..\..\..\tests\test-hdr\set\hdr_intrusive_michael_set_rcu_sht_lazy.cpp" />\r
+    <ClCompile Include="..\..\..\tests\test-hdr\set\hdr_intrusive_multilevel_hashset_hp.cpp" />\r
     <ClCompile Include="..\..\..\tests\test-hdr\set\hdr_intrusive_skiplist_dhp.cpp" />\r
     <ClCompile Include="..\..\..\tests\test-hdr\set\hdr_intrusive_skiplist_dhp_member.cpp" />\r
     <ClCompile Include="..\..\..\tests\test-hdr\set\hdr_intrusive_skiplist_hp.cpp" />\r
index e579d1acf3d4e3d4f153e8991ed8835184a1e2d9..24772ff98114ced0cc85ddad765486d541144be2 100644 (file)
@@ -19,6 +19,9 @@
     <ClInclude Include="..\..\..\tests\test-hdr\set\hdr_skiplist_set_rcu.h">\r
       <Filter>container\skip_list</Filter>\r
     </ClInclude>\r
+    <ClInclude Include="..\..\..\tests\test-hdr\set\hdr_intrusive_multilevel_hashset.h">\r
+      <Filter>intrusive\multilevel_hashset</Filter>\r
+    </ClInclude>\r
   </ItemGroup>\r
   <ItemGroup>\r
     <Filter Include="intrusive">\r
@@ -45,6 +48,9 @@
     <Filter Include="container\split_list">\r
       <UniqueIdentifier>{61f94a40-c964-4233-af67-66a1be1e0aab}</UniqueIdentifier>\r
     </Filter>\r
+    <Filter Include="intrusive\multilevel_hashset">\r
+      <UniqueIdentifier>{a878aed0-83c9-4ca7-95bb-74f10aad8bde}</UniqueIdentifier>\r
+    </Filter>\r
   </ItemGroup>\r
   <ItemGroup>\r
     <ClCompile Include="..\..\..\tests\test-hdr\set\hdr_intrusive_michael_set_hp.cpp">\r
     <ClCompile Include="..\..\..\tests\test-hdr\set\hdr_skiplist_set_dhp.cpp">\r
       <Filter>container\skip_list</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="..\..\..\tests\test-hdr\set\hdr_intrusive_multilevel_hashset_hp.cpp">\r
+      <Filter>intrusive\multilevel_hashset</Filter>\r
+    </ClCompile>\r
   </ItemGroup>\r
 </Project>
\ No newline at end of file
index 28f258c1e812509e40c6fe78d59d39690e0e5027..77ca8cb557c4fd5f6d0dd4d632e6a439f7c329fa 100644 (file)
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|Win32'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|x64'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|Win32'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugVLD|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemGroup>\r
index d62e3008f44bcee64a6d99875809909351daff9e..b7ee1625d6a6a3e0ea835f41390ec5a19a0d49cf 100644 (file)
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|Win32'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|x64'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|Win32'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugVLD|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />\r
index a6d325d3f4dd523256710ced698c2158927f59f6..be40b2c73208decb068a5ba157ce8da8ed601dec 100644 (file)
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|Win32'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Debug|x64'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|Win32'">\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
       <Profile>true</Profile>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ICL-Release|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX86</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugVLD|x64'">\r
       <DataExecutionPrevention>\r
       </DataExecutionPrevention>\r
       <TargetMachine>MachineX64</TargetMachine>\r
+      <ForceFileOutput>MultiplyDefinedSymbolOnly</ForceFileOutput>\r
     </Link>\r
   </ItemDefinitionGroup>\r
   <ItemGroup>\r
index 0f27e11f97ff14f4b22bf1f2afa754f6800b5d8b..f352589bdff3707a25444078f1f3f8586644aa7e 100644 (file)
@@ -129,6 +129,7 @@ CDS_TESTHDR_QUEUE := \
     tests/test-hdr/queue/hdr_vyukov_mpmc_cyclic.cpp
 
 CDS_TESTHDR_SET := \
+    tests/test-hdr/set/hdr_intrusive_multilevel_hashset_hp.cpp \
     tests/test-hdr/set/hdr_intrusive_refinable_hashset_avlset.cpp \
     tests/test-hdr/set/hdr_intrusive_refinable_hashset_list.cpp \
     tests/test-hdr/set/hdr_intrusive_refinable_hashset_set.cpp \
index 2753b2de8f651e8aa7237eda2b6791d519aa074b..1500a030abff07235481d2988910eacb5b547170 100644 (file)
@@ -144,7 +144,6 @@ namespace set {
 
         test_int<set>();
     }
-
-
 } // namespace set
+
 CPPUNIT_TEST_SUITE_REGISTRATION(set::IntrusiveHashSetHdrTest);
diff --git a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset.h b/tests/test-hdr/set/hdr_intrusive_multilevel_hashset.h
new file mode 100644 (file)
index 0000000..8eb17e3
--- /dev/null
@@ -0,0 +1,50 @@
+//$$CDS-header$$
+
+#ifndef CDSTEST_HDR_INTRUSIVE_MULTILEVEL_HASHSET_H
+#define CDSTEST_HDR_INTRUSIVE_MULTILEVEL_HASHSET_H
+
+#include "cppunit/cppunit_proxy.h"
+
+// forward declaration
+namespace cds { 
+    namespace intrusive {}
+    namespace opt {}
+}
+
+namespace set {
+    namespace ci = cds::intrusive;
+    namespace co = cds::opt;
+
+    class IntrusiveMultiLevelHashSetHdrTest: public CppUnitMini::TestCase
+    {
+        template <typename Hash>
+        struct Item 
+        {
+            unsigned int nDisposeCount  ;   // count of disposer calling
+            Hash hash;
+        };
+
+        template <typename Hash>
+        struct get_hash
+        {
+            Hash const& operator()( Item<Hash> const& i ) const
+            {
+                return i.hash;
+            }
+        };
+
+        template <typename Set>
+        void test_hp()
+        {
+            Set s;
+        }
+
+        void hp_stdhash();
+
+        CPPUNIT_TEST_SUITE(IntrusiveMultiLevelHashSetHdrTest)
+            CPPUNIT_TEST(hp_stdhash)
+        CPPUNIT_TEST_SUITE_END()
+    };
+} // namespace set
+
+#endif // #ifndef CDSTEST_HDR_INTRUSIVE_MULTILEVEL_HASHSET_H
diff --git a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_hp.cpp b/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_hp.cpp
new file mode 100644 (file)
index 0000000..fb80ee1
--- /dev/null
@@ -0,0 +1,33 @@
+//$$CDS-header$$
+
+#include "set/hdr_intrusive_multilevel_hashset.h"
+#include <cds/intrusive/multilevel_hashset_hp.h>
+
+namespace set {
+    namespace {
+        typedef cds::gc::HP gc_type;
+    } // namespace
+
+    void IntrusiveMultiLevelHashSetHdrTest::hp_stdhash()
+    {
+        typedef size_t hash_type;
+
+        struct traits: public ci::multilevel_hashset::traits
+        {
+            typedef get_hash<hash_type> hash_accessor;
+        };
+        typedef ci::MultiLevelHashSet< gc_type, Item<hash_type>, traits > set_type;
+        test_hp<set_type>();
+
+        typedef ci::MultiLevelHashSet< 
+            gc_type, 
+            Item<hash_type>, 
+            typename ci::multilevel_hashset::make_traits<
+                ci::multilevel_hashset::hash_accessor< get_hash<hash_type>>
+            >::type
+        > set_type2;
+        test_hp<set_type2>();
+    }
+} // namespace set
+
+CPPUNIT_TEST_SUITE_REGISTRATION(set::IntrusiveMultiLevelHashSetHdrTest);