From: khizmax Date: Thu, 23 Oct 2014 14:25:41 +0000 (+0400) Subject: Remove SkipList specializations X-Git-Tag: v2.0.0~184 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=a6b4573d46fc1acdd6fa87b928abdf904ce4e66b;p=libcds.git Remove SkipList specializations --- diff --git a/cds/container/impl/skip_list_map.h b/cds/container/impl/skip_list_map.h index 841d6d79..dac53ed5 100644 --- a/cds/container/impl/skip_list_map.h +++ b/cds/container/impl/skip_list_map.h @@ -57,7 +57,7 @@ namespace cds { namespace container { Like STL map class, %SkipListMap stores its key-value pair as std:pair< K const, T>. \warning The skip-list requires up to 67 hazard pointers that may be critical for some GCs for which - the guard count is limited (like as gc::HP, gc::HRC). Those GCs should be explicitly initialized with + the guard count is limited (like \p gc::HP). Those GCs should be explicitly initialized with hazard pointer enough: \code cds::gc::HP myhp( 67 ) \endcode. Otherwise an run-time exception may be raised when you try to create skip-list object. @@ -81,7 +81,7 @@ namespace cds { namespace container { before end of the map. Therefore, such iteration is more suitable for debugging purpose only Remember, each iterator object requires 2 additional hazard pointers, that may be - a limited resource for \p GC like as gc::HP and gc::HRC (however, for gc::PTB the count of + a limited resource for \p GC like \p gc::HP (for gc::PTB the count of guards is unlimited). The iterator class supports the following minimalistic interface: diff --git a/cds/container/impl/skip_list_set.h b/cds/container/impl/skip_list_set.h index 783bc862..33612c6a 100644 --- a/cds/container/impl/skip_list_set.h +++ b/cds/container/impl/skip_list_set.h @@ -55,7 +55,7 @@ namespace cds { namespace container { - opt::stat - internal statistics. Available types: skip_list::stat, skip_list::empty_stat (the default) \warning The skip-list requires up to 67 hazard pointers that may be critical for some GCs for which - the guard count is limited (like as gc::HP, gc::HRC). Those GCs should be explicitly initialized with + the guard count is limited (like as \p gc::HP). Those GCs should be explicitly initialized with hazard pointer enough: \code cds::gc::HP myhp( 67 ) \endcode. Otherwise an run-time exception may be raised when you try to create skip-list object. @@ -79,7 +79,7 @@ namespace cds { namespace container { before end of the set. Therefore, such iteration is more suitable for debugging purpose only Remember, each iterator object requires 2 additional hazard pointers, that may be - a limited resource for \p GC like as gc::HP and gc::HRC (for gc::PTB the count of + a limited resource for \p GC like \p gc::HP (for \p gc::PTB the count of guards is unlimited). The iterator class supports the following minimalistic interface: diff --git a/cds/container/skip_list_map_hrc.h b/cds/container/skip_list_map_hrc.h deleted file mode 100644 index 84d8d1af..00000000 --- a/cds/container/skip_list_map_hrc.h +++ /dev/null @@ -1,11 +0,0 @@ -//$$CDS-header$$ - -#ifndef __CDS_CONTAINER_SKIP_LIST_MAP_HRC_H -#define __CDS_CONTAINER_SKIP_LIST_MAP_HRC_H - -#include -#include -#include -#include - -#endif // #ifndef __CDS_CONTAINER_SKIP_LIST_MAP_HRC_H diff --git a/cds/container/skip_list_set_hrc.h b/cds/container/skip_list_set_hrc.h deleted file mode 100644 index df254dbc..00000000 --- a/cds/container/skip_list_set_hrc.h +++ /dev/null @@ -1,11 +0,0 @@ -//$$CDS-header$$ - -#ifndef __CDS_CONTAINER_SKIP_LIST_SET_HRC_H -#define __CDS_CONTAINER_SKIP_LIST_SET_HRC_H - -#include -#include -#include -#include - -#endif // #ifndef __CDS_CONTAINER_SKIP_LIST_SET_HRC_H diff --git a/cds/intrusive/impl/skip_list.h b/cds/intrusive/impl/skip_list.h index c9f25594..ddce8e53 100644 --- a/cds/intrusive/impl/skip_list.h +++ b/cds/intrusive/impl/skip_list.h @@ -210,13 +210,12 @@ namespace cds { namespace intrusive { - opt::stat - internal statistics. Available types: skip_list::stat, skip_list::empty_stat (the default) \warning The skip-list requires up to 67 hazard pointers that may be critical for some GCs for which - the guard count is limited (like as gc::HP, gc::HRC). Those GCs should be explicitly initialized with + the guard count is limited (like as \p gc::HP). Those GCs should be explicitly initialized with hazard pointer enough: \code cds::gc::HP myhp( 67 ) \endcode. Otherwise an run-time exception may be raised when you try to create skip-list object. \note There are several specializations of \p %SkipListSet for each \p GC. You should include: - for gc::HP garbage collector - - for gc::HRC garbage collector - for gc::PTB garbage collector - for \ref cds_intrusive_SkipListSet_nogc for persistent set - for \ref cds_intrusive_SkipListSet_rcu "RCU type" @@ -235,7 +234,7 @@ namespace cds { namespace intrusive { before end of the set. Therefore, such iteration is more suitable for debugging purpose only Remember, each iterator object requires 2 additional hazard pointers, that may be - a limited resource for \p GC like as gc::HP and gc::HRC (for gc::PTB the count of + a limited resource for \p GC like as \p gc::HP (for \p gc::PTB the count of guards is unlimited). The iterator class supports the following minimalistic interface: diff --git a/cds/intrusive/skip_list_hrc.h b/cds/intrusive/skip_list_hrc.h deleted file mode 100644 index dddfbca6..00000000 --- a/cds/intrusive/skip_list_hrc.h +++ /dev/null @@ -1,201 +0,0 @@ -//$$CDS-header$$ - -#ifndef __CDS_INTRUSIVE_SKIP_LIST_HRC_H -#define __CDS_INTRUSIVE_SKIP_LIST_HRC_H - -#include -#include - -//@cond -namespace cds { namespace intrusive { namespace skip_list { - // Specialization for HRC GC - template - class node< cds::gc::HRC, Tag>: public cds::gc::HRC::container_node - { - public: - typedef gc::HRC gc ; ///< Garbage collector - typedef Tag tag ; ///< tag - - typedef cds::details::marked_ptr marked_ptr ; ///< marked pointer - typedef typename gc::template atomic_marked_ptr< marked_ptr> atomic_marked_ptr ; ///< atomic marked pointer specific for GC - typedef atomic_marked_ptr tower_item_type; - - protected: - atomic_marked_ptr m_pNext ; ///< Next item in bottom-list (list at level 0) - unsigned int m_nHeight ; ///< Node height (size of m_arrNext array). For node at level 0 the height is 1. - atomic_marked_ptr * m_arrNext ; ///< Array of next items for levels 1 .. m_nHeight - 1. For node at level 0 \p m_arrNext is \p nullptr - - public: - bool m_bDel; - - public: - /// Constructs a node of height 1 (a bottom-list node) - node() - : m_pNext( nullptr ) - , m_nHeight(1) - , m_arrNext( nullptr ) - , m_bDel( false ) - {} - - ~node() - { - release_tower(); - m_pNext.store( marked_ptr(), atomics::memory_order_relaxed ); - } - - /// Constructs a node of height \p nHeight - void make_tower( unsigned int nHeight, atomic_marked_ptr * nextTower ) - { - assert( nHeight > 0 ); - assert( (nHeight == 1 && nextTower == nullptr) // bottom-list node - || (nHeight > 1 && nextTower != nullptr) // node at level of more than 0 - ); - - m_arrNext = nextTower; - m_nHeight = nHeight; - } - - atomic_marked_ptr * release_tower() - { - unsigned int nHeight = m_nHeight - 1; - atomic_marked_ptr * pTower = m_arrNext; - if ( pTower ) { - m_arrNext = nullptr; - m_nHeight = 1; - for ( unsigned int i = 0; i < nHeight; ++i ) - pTower[i].store( marked_ptr(), atomics::memory_order_release ); - } - return pTower; - } - - atomic_marked_ptr * get_tower() const - { - return m_arrNext; - } - - /// Access to element of next pointer array - atomic_marked_ptr& next( unsigned int nLevel ) - { - assert( nLevel < height() ); - assert( nLevel == 0 || (nLevel > 0 && m_arrNext != nullptr) ); - - return nLevel ? m_arrNext[ nLevel - 1] : m_pNext; - } - - /// Access to element of next pointer array (const version) - atomic_marked_ptr const& next( unsigned int nLevel ) const - { - assert( nLevel < height() ); - assert( nLevel == 0 || (nLevel > 0 && m_arrNext != nullptr) ); - - return nLevel ? m_arrNext[ nLevel - 1] : m_pNext; - } - - /// Access to element of next pointer array (same as \ref next function) - atomic_marked_ptr& operator[]( unsigned int nLevel ) - { - return next( nLevel ); - } - - /// Access to element of next pointer array (same as \ref next function) - atomic_marked_ptr const& operator[]( unsigned int nLevel ) const - { - return next( nLevel ); - } - - /// Height of the node - unsigned int height() const - { - return m_nHeight; - } - - protected: - virtual void cleanUp( cds::gc::hrc::ThreadGC * pGC ) - { - assert( pGC ); - typename gc::GuardArray<2> aGuards( *pGC ); - - unsigned int const nHeight = height(); - for (unsigned int i = 0; i < nHeight; ++i ) { - while ( true ) { - marked_ptr pNextMarked( aGuards.protect( 0, next(i) )); - node * pNext = pNextMarked.ptr(); - if ( pNext && pNext->m_bDeleted.load(atomics::memory_order_acquire) ) { - marked_ptr p = aGuards.protect( 1, pNext->next(i) ); - next(i).compare_exchange_strong( pNextMarked, p, atomics::memory_order_acquire, atomics::memory_order_relaxed ); - continue; - } - else { - break; - } - } - } - } - - virtual void terminate( cds::gc::hrc::ThreadGC * pGC, bool bConcurrent ) - { - unsigned int const nHeight = height(); - if ( bConcurrent ) { - for (unsigned int i = 0; i < nHeight; ++i ) { - marked_ptr pNext = next(i).load(atomics::memory_order_relaxed); - while ( !next(i).compare_exchange_weak( pNext, marked_ptr(), atomics::memory_order_release, atomics::memory_order_relaxed ) ); - } - } - else { - for (unsigned int i = 0; i < nHeight; ++i ) - next(i).store( marked_ptr(), atomics::memory_order_relaxed ); - } - } - }; - - namespace details { - - template - class head_node< node< cds::gc::HRC, Tag > > - { - typedef node< cds::gc::HRC, Tag > node_type; - - struct head_tower: public node_type - { - typename node_type::atomic_marked_ptr m_Tower[skip_list::c_nHeightLimit]; - }; - - head_tower * m_pHead; - - struct head_disposer { - void operator()( head_tower * p ) - { - delete p; - } - }; - public: - head_node( unsigned int nHeight ) - : m_pHead( new head_tower() ) - { - for ( size_t i = 0; i < sizeof(m_pHead->m_Tower) / sizeof(m_pHead->m_Tower[0]); ++i ) - m_pHead->m_Tower[i].store( typename node_type::marked_ptr(), atomics::memory_order_relaxed ); - - m_pHead->make_tower( nHeight, m_pHead->m_Tower ); - } - - ~head_node() - { - cds::gc::HRC::template retire( m_pHead ); - } - - node_type * head() - { - return static_cast( m_pHead ); - } - node_type const * head() const - { - return static_cast( m_pHead ); - } - - }; - } // namespace details - -}}} // namespace cds::intrusive::skip_list -//@endcond - -#endif diff --git a/projects/Win/vc12/cds.vcxproj b/projects/Win/vc12/cds.vcxproj index 6fd1a808..48b3c62a 100644 --- a/projects/Win/vc12/cds.vcxproj +++ b/projects/Win/vc12/cds.vcxproj @@ -692,12 +692,10 @@ - - @@ -771,7 +769,6 @@ - diff --git a/projects/Win/vc12/cds.vcxproj.filters b/projects/Win/vc12/cds.vcxproj.filters index 04886c30..bef684be 100644 --- a/projects/Win/vc12/cds.vcxproj.filters +++ b/projects/Win/vc12/cds.vcxproj.filters @@ -881,18 +881,12 @@ Header Files\cds\intrusive - - Header Files\cds\intrusive - Header Files\cds\intrusive Header Files\cds\container - - Header Files\cds\container - Header Files\cds\container @@ -902,9 +896,6 @@ Header Files\cds\container - - Header Files\cds\container - Header Files\cds\container diff --git a/projects/Win/vc12/hdr-test-set.vcxproj b/projects/Win/vc12/hdr-test-set.vcxproj index bfc14b82..104fb2a4 100644 --- a/projects/Win/vc12/hdr-test-set.vcxproj +++ b/projects/Win/vc12/hdr-test-set.vcxproj @@ -562,7 +562,6 @@ - @@ -612,7 +611,6 @@ - diff --git a/projects/Win/vc12/hdr-test-set.vcxproj.filters b/projects/Win/vc12/hdr-test-set.vcxproj.filters index aa330c2f..47d8e4af 100644 --- a/projects/Win/vc12/hdr-test-set.vcxproj.filters +++ b/projects/Win/vc12/hdr-test-set.vcxproj.filters @@ -92,9 +92,6 @@ intrusive\skip_list - - intrusive\skip_list - intrusive\skip_list @@ -182,9 +179,6 @@ container\skip_list - - container\skip_list - container\skip_list diff --git a/tests/test-hdr/set/hdr_intrusive_skiplist_hrc.cpp b/tests/test-hdr/set/hdr_intrusive_skiplist_hrc.cpp deleted file mode 100644 index 85baebe9..00000000 --- a/tests/test-hdr/set/hdr_intrusive_skiplist_hrc.cpp +++ /dev/null @@ -1,327 +0,0 @@ -//$$CDS-header$$ - -#include "set/hdr_intrusive_skiplist_set.h" - -#include -#include "map/print_skiplist_stat.h" - -namespace set { - - void IntrusiveSkipListSet::skiplist_hrc_base_cmp() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::compare< cmp > - ,ci::opt::disposer< faked_disposer > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_less() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_cmpmix() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,co::compare< cmp > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_cmp_stat() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::compare< cmp > - ,ci::opt::disposer< faked_disposer > - ,co::stat< ci::skip_list::stat<> > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_less_stat() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,co::stat< ci::skip_list::stat<> > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_cmpmix_stat() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,co::compare< cmp > - ,co::stat< ci::skip_list::stat<> > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_cmp_xorshift() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::compare< cmp > - ,ci::opt::disposer< faked_disposer > - ,ci::skip_list::random_level_generator< ci::skip_list::xorshift > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_less_xorshift() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,ci::skip_list::random_level_generator< ci::skip_list::xorshift > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_cmpmix_xorshift() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,co::compare< cmp > - ,ci::skip_list::random_level_generator< ci::skip_list::xorshift > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_cmp_xorshift_stat() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::compare< cmp > - ,ci::opt::disposer< faked_disposer > - ,ci::skip_list::random_level_generator< ci::skip_list::xorshift > - ,co::stat< ci::skip_list::stat<> > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_less_xorshift_stat() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,ci::skip_list::random_level_generator< ci::skip_list::xorshift > - ,co::stat< ci::skip_list::stat<> > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_cmpmix_xorshift_stat() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,co::compare< cmp > - ,ci::skip_list::random_level_generator< ci::skip_list::xorshift > - ,co::stat< ci::skip_list::stat<> > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - - //********* - void IntrusiveSkipListSet::skiplist_hrc_base_cmp_pascal() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::compare< cmp > - ,ci::opt::disposer< faked_disposer > - ,ci::skip_list::random_level_generator< ci::skip_list::turbo_pascal > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_less_pascal() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,ci::skip_list::random_level_generator< ci::skip_list::turbo_pascal > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_cmpmix_pascal() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,co::compare< cmp > - ,ci::skip_list::random_level_generator< ci::skip_list::turbo_pascal > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_cmp_pascal_stat() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::compare< cmp > - ,ci::opt::disposer< faked_disposer > - ,ci::skip_list::random_level_generator< ci::skip_list::turbo_pascal > - ,co::stat< ci::skip_list::stat<> > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_less_pascal_stat() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,ci::skip_list::random_level_generator< ci::skip_list::turbo_pascal > - ,co::stat< ci::skip_list::stat<> > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - - void IntrusiveSkipListSet::skiplist_hrc_base_cmpmix_pascal_stat() - { - typedef base_int_item< ci::skip_list::node< cds::gc::HRC> > item; - - typedef ci::SkipListSet< cds::gc::HRC, item, - ci::skip_list::make_traits< - ci::opt::hook< ci::skip_list::base_hook< co::gc > > - ,co::less< less > - ,ci::opt::disposer< faked_disposer > - ,co::compare< cmp > - ,ci::skip_list::random_level_generator< ci::skip_list::turbo_pascal > - ,co::stat< ci::skip_list::stat<> > - ,co::item_counter< cds::atomicity::item_counter > - >::type - > set_type; - - test_skiplist >(); - } - -} // namespace set diff --git a/tests/test-hdr/set/hdr_intrusive_skiplist_set.h b/tests/test-hdr/set/hdr_intrusive_skiplist_set.h index f07be30d..9490b82b 100644 --- a/tests/test-hdr/set/hdr_intrusive_skiplist_set.h +++ b/tests/test-hdr/set/hdr_intrusive_skiplist_set.h @@ -550,26 +550,6 @@ namespace set { void skiplist_hp_member_less_pascal_stat(); void skiplist_hp_member_cmpmix_pascal_stat(); - // Skip-list - gc::HRC - void skiplist_hrc_base_cmp(); - void skiplist_hrc_base_less(); - void skiplist_hrc_base_cmpmix(); - void skiplist_hrc_base_cmp_stat(); - void skiplist_hrc_base_less_stat(); - void skiplist_hrc_base_cmpmix_stat(); - void skiplist_hrc_base_cmp_xorshift(); - void skiplist_hrc_base_less_xorshift(); - void skiplist_hrc_base_cmpmix_xorshift(); - void skiplist_hrc_base_cmp_xorshift_stat(); - void skiplist_hrc_base_less_xorshift_stat(); - void skiplist_hrc_base_cmpmix_xorshift_stat(); - void skiplist_hrc_base_cmp_pascal(); - void skiplist_hrc_base_less_pascal(); - void skiplist_hrc_base_cmpmix_pascal(); - void skiplist_hrc_base_cmp_pascal_stat(); - void skiplist_hrc_base_less_pascal_stat(); - void skiplist_hrc_base_cmpmix_pascal_stat(); - // Skip-list - gc::PTB void skiplist_ptb_base_cmp(); void skiplist_ptb_base_less(); @@ -687,25 +667,6 @@ namespace set { CPPUNIT_TEST(skiplist_hp_member_less_pascal_stat) CPPUNIT_TEST(skiplist_hp_member_cmpmix_pascal_stat) - CPPUNIT_TEST(skiplist_hrc_base_cmp) - CPPUNIT_TEST(skiplist_hrc_base_less) - CPPUNIT_TEST(skiplist_hrc_base_cmpmix) - CPPUNIT_TEST(skiplist_hrc_base_cmp_stat) - CPPUNIT_TEST(skiplist_hrc_base_less_stat) - CPPUNIT_TEST(skiplist_hrc_base_cmpmix_stat) - CPPUNIT_TEST(skiplist_hrc_base_cmp_xorshift) - CPPUNIT_TEST(skiplist_hrc_base_less_xorshift) - CPPUNIT_TEST(skiplist_hrc_base_cmpmix_xorshift) - CPPUNIT_TEST(skiplist_hrc_base_cmp_xorshift_stat) - CPPUNIT_TEST(skiplist_hrc_base_less_xorshift_stat) - CPPUNIT_TEST(skiplist_hrc_base_cmpmix_xorshift_stat) - CPPUNIT_TEST(skiplist_hrc_base_cmp_pascal) - CPPUNIT_TEST(skiplist_hrc_base_less_pascal) - CPPUNIT_TEST(skiplist_hrc_base_cmpmix_pascal) - CPPUNIT_TEST(skiplist_hrc_base_cmp_pascal_stat) - CPPUNIT_TEST(skiplist_hrc_base_less_pascal_stat) - CPPUNIT_TEST(skiplist_hrc_base_cmpmix_pascal_stat) - CPPUNIT_TEST(skiplist_ptb_base_cmp) CPPUNIT_TEST(skiplist_ptb_base_less) CPPUNIT_TEST(skiplist_ptb_base_cmpmix) diff --git a/tests/test-hdr/set/hdr_skiplist_set.h b/tests/test-hdr/set/hdr_skiplist_set.h index c593a0cf..7a2d4be4 100644 --- a/tests/test-hdr/set/hdr_skiplist_set.h +++ b/tests/test-hdr/set/hdr_skiplist_set.h @@ -431,31 +431,6 @@ namespace set { void SkipList_HP_michaelalloc_cmp_stat(); void SkipList_HP_michaelalloc_cmpless_stat(); - void SkipList_HRC_less(); - void SkipList_HRC_cmp(); - void SkipList_HRC_cmpless(); - void SkipList_HRC_less_stat(); - void SkipList_HRC_cmp_stat(); - void SkipList_HRC_cmpless_stat(); - void SkipList_HRC_xorshift_less(); - void SkipList_HRC_xorshift_cmp(); - void SkipList_HRC_xorshift_cmpless(); - void SkipList_HRC_xorshift_less_stat(); - void SkipList_HRC_xorshift_cmp_stat(); - void SkipList_HRC_xorshift_cmpless_stat(); - void SkipList_HRC_turbopas_less(); - void SkipList_HRC_turbopas_cmp(); - void SkipList_HRC_turbopas_cmpless(); - void SkipList_HRC_turbopas_less_stat(); - void SkipList_HRC_turbopas_cmp_stat(); - void SkipList_HRC_turbopas_cmpless_stat(); - void SkipList_HRC_michaelalloc_less(); - void SkipList_HRC_michaelalloc_cmp(); - void SkipList_HRC_michaelalloc_cmpless(); - void SkipList_HRC_michaelalloc_less_stat(); - void SkipList_HRC_michaelalloc_cmp_stat(); - void SkipList_HRC_michaelalloc_cmpless_stat(); - void SkipList_PTB_less(); void SkipList_PTB_cmp(); void SkipList_PTB_cmpless(); @@ -532,31 +507,6 @@ namespace set { CPPUNIT_TEST(SkipList_HP_michaelalloc_cmp_stat) CPPUNIT_TEST(SkipList_HP_michaelalloc_cmpless_stat) - CPPUNIT_TEST(SkipList_HRC_less) - CPPUNIT_TEST(SkipList_HRC_cmp) - CPPUNIT_TEST(SkipList_HRC_cmpless) - CPPUNIT_TEST(SkipList_HRC_less_stat) - CPPUNIT_TEST(SkipList_HRC_cmp_stat) - CPPUNIT_TEST(SkipList_HRC_cmpless_stat) - CPPUNIT_TEST(SkipList_HRC_xorshift_less) - CPPUNIT_TEST(SkipList_HRC_xorshift_cmp) - CPPUNIT_TEST(SkipList_HRC_xorshift_cmpless) - CPPUNIT_TEST(SkipList_HRC_xorshift_less_stat) - CPPUNIT_TEST(SkipList_HRC_xorshift_cmp_stat) - CPPUNIT_TEST(SkipList_HRC_xorshift_cmpless_stat) - CPPUNIT_TEST(SkipList_HRC_turbopas_less) - CPPUNIT_TEST(SkipList_HRC_turbopas_cmp) - CPPUNIT_TEST(SkipList_HRC_turbopas_cmpless) - CPPUNIT_TEST(SkipList_HRC_turbopas_less_stat) - CPPUNIT_TEST(SkipList_HRC_turbopas_cmp_stat) - CPPUNIT_TEST(SkipList_HRC_turbopas_cmpless_stat) - CPPUNIT_TEST(SkipList_HRC_michaelalloc_less) - CPPUNIT_TEST(SkipList_HRC_michaelalloc_cmp) - CPPUNIT_TEST(SkipList_HRC_michaelalloc_cmpless) - CPPUNIT_TEST(SkipList_HRC_michaelalloc_less_stat) - CPPUNIT_TEST(SkipList_HRC_michaelalloc_cmp_stat) - CPPUNIT_TEST(SkipList_HRC_michaelalloc_cmpless_stat) - CPPUNIT_TEST(SkipList_PTB_less) CPPUNIT_TEST(SkipList_PTB_cmp) CPPUNIT_TEST(SkipList_PTB_cmpless) diff --git a/tests/test-hdr/set/hdr_skiplist_set_hrc.cpp b/tests/test-hdr/set/hdr_skiplist_set_hrc.cpp deleted file mode 100644 index ef142854..00000000 --- a/tests/test-hdr/set/hdr_skiplist_set_hrc.cpp +++ /dev/null @@ -1,311 +0,0 @@ -//$$CDS-header$$ - -#include "set/hdr_skiplist_set.h" -#include -#include "unit/michael_alloc.h" -#include "map/print_skiplist_stat.h" - -namespace set { - - void SkipListSetHdrTest::SkipList_HRC_less() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::item_counter< simple_item_counter > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_cmp() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::compare< cmp > - ,co::item_counter< simple_item_counter > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_cmpless() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::compare< cmp > - ,co::item_counter< simple_item_counter > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_less_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_cmp_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_cmpless_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_xorshift_less() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::item_counter< simple_item_counter > - ,cc::skip_list::random_level_generator< cc::skip_list::xorshift > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_xorshift_cmp() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,cc::skip_list::random_level_generator< cc::skip_list::xorshift > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_xorshift_cmpless() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,cc::skip_list::random_level_generator< cc::skip_list::xorshift > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_xorshift_less_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - ,cc::skip_list::random_level_generator< cc::skip_list::xorshift > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_xorshift_cmp_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - ,cc::skip_list::random_level_generator< cc::skip_list::xorshift > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_xorshift_cmpless_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - ,cc::skip_list::random_level_generator< cc::skip_list::xorshift > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_turbopas_less() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::item_counter< simple_item_counter > - ,cc::skip_list::random_level_generator< cc::skip_list::turbo_pascal > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_turbopas_cmp() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,cc::skip_list::random_level_generator< cc::skip_list::turbo_pascal > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_turbopas_cmpless() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,cc::skip_list::random_level_generator< cc::skip_list::turbo_pascal > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_turbopas_less_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - ,cc::skip_list::random_level_generator< cc::skip_list::turbo_pascal > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_turbopas_cmp_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - ,cc::skip_list::random_level_generator< cc::skip_list::turbo_pascal > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_turbopas_cmpless_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - ,cc::skip_list::random_level_generator< cc::skip_list::turbo_pascal > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_michaelalloc_less() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::item_counter< simple_item_counter > - ,co::allocator< memory::MichaelAllocator > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_michaelalloc_cmp() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,co::allocator< memory::MichaelAllocator > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_michaelalloc_cmpless() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,co::allocator< memory::MichaelAllocator > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_michaelalloc_less_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - ,co::allocator< memory::MichaelAllocator > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_michaelalloc_cmp_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - ,co::allocator< memory::MichaelAllocator > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } - - void SkipListSetHdrTest::SkipList_HRC_michaelalloc_cmpless_stat() - { - typedef cc::SkipListSet< cds::gc::HRC, item, - cc::skip_list::make_traits< - co::less< less > - ,co::compare< cmp > - ,co::item_counter< simple_item_counter > - ,co::stat< cc::skip_list::stat<> > - ,co::allocator< memory::MichaelAllocator > - >::type - > set; - test< set, misc::print_skiplist_stat >(); - } -} // namespace set