From 87974cb23acebee8e4f679d922e264cc08a9a4eb Mon Sep 17 00:00:00 2001 From: khizmax Date: Tue, 20 Oct 2015 06:57:57 +0300 Subject: [PATCH] Renamed MultiLevelHashSet/Map to FeldmanHashSet/Map --- ..._hashmap_base.h => feldman_hashmap_base.h} | 68 +-- ..._hashset_base.h => feldman_hashset_base.h} | 70 +-- cds/container/feldman_hashmap_dhp.h | 9 + cds/container/feldman_hashmap_hp.h | 9 + ...el_hashmap_rcu.h => feldman_hashmap_rcu.h} | 68 +-- cds/container/feldman_hashset_dhp.h | 9 + cds/container/feldman_hashset_hp.h | 9 + ...el_hashset_rcu.h => feldman_hashset_rcu.h} | 68 +-- ...multilevel_hashmap.h => feldman_hashmap.h} | 78 +-- ...multilevel_hashset.h => feldman_hashset.h} | 74 +-- cds/container/multilevel_hashmap_dhp.h | 9 - cds/container/multilevel_hashmap_hp.h | 9 - cds/container/multilevel_hashset_dhp.h | 9 - cds/container/multilevel_hashset_hp.h | 9 - ..._hashset_base.h => feldman_hashset_base.h} | 44 +- cds/intrusive/feldman_hashset_dhp.h | 9 + cds/intrusive/feldman_hashset_hp.h | 9 + ...el_hashset_rcu.h => feldman_hashset_rcu.h} | 84 +-- ...multilevel_hashset.h => feldman_hashset.h} | 102 ++-- cds/intrusive/multilevel_hashset_dhp.h | 9 - cds/intrusive/multilevel_hashset_hp.h | 9 - projects/Win/vc12/cds.sln | 6 +- projects/Win/vc12/cds.vcxproj | 30 +- projects/Win/vc12/cds.vcxproj.filters | 30 +- projects/Win/vc12/hdr-test-map.vcxproj | 16 +- .../Win/vc12/hdr-test-map.vcxproj.filters | 16 +- projects/Win/vc12/hdr-test-set.vcxproj | 32 +- .../Win/vc12/hdr-test-set.vcxproj.filters | 68 +-- projects/Win/vc12/unit-map-delodd.vcxproj | 2 +- projects/Win/vc12/unit-map-find.vcxproj | 6 +- .../Win/vc12/unit-map-find.vcxproj.filters | 6 +- .../Win/vc12/unit-map-insdel-item.vcxproj | 4 +- .../vc12/unit-map-insdel-item.vcxproj.filters | 4 +- projects/Win/vc12/unit-map-insdel.vcxproj | 6 +- .../Win/vc12/unit-map-insdel.vcxproj.filters | 6 +- projects/Win/vc12/unit-map-insdelfind.vcxproj | 2 +- projects/Win/vc12/unit-set-delodd.vcxproj | 2 +- projects/Win/vc12/unit-set-insdel.vcxproj | 4 +- .../Win/vc12/unit-set-insdel.vcxproj.filters | 4 +- projects/Win/vc12/unit-set-insdelfind.vcxproj | 2 +- projects/Win/vc14/cds.sln | 6 +- projects/Win/vc14/cds.vcxproj | 30 +- projects/Win/vc14/cds.vcxproj.filters | 30 +- projects/Win/vc14/hdr-test-map.vcxproj | 16 +- .../Win/vc14/hdr-test-map.vcxproj.filters | 16 +- projects/Win/vc14/hdr-test-set.vcxproj | 32 +- .../Win/vc14/hdr-test-set.vcxproj.filters | 68 +-- projects/Win/vc14/unit-map-delodd.vcxproj | 2 +- projects/Win/vc14/unit-map-find.vcxproj | 6 +- .../Win/vc14/unit-map-find.vcxproj.filters | 6 +- .../Win/vc14/unit-map-insdel-item.vcxproj | 4 +- .../vc14/unit-map-insdel-item.vcxproj.filters | 4 +- projects/Win/vc14/unit-map-insdel.vcxproj | 6 +- .../Win/vc14/unit-map-insdel.vcxproj.filters | 6 +- projects/Win/vc14/unit-map-insdelfind.vcxproj | 2 +- projects/Win/vc14/unit-set-delodd.vcxproj | 2 +- projects/Win/vc14/unit-set-insdel.vcxproj | 4 +- .../Win/vc14/unit-set-insdel.vcxproj.filters | 4 +- projects/Win/vc14/unit-set-insdelfind.vcxproj | 2 +- projects/source.test-hdr.mk | 42 +- projects/source.unit.map.mk | 20 +- projects/source.unit.set.mk | 8 +- tests/data/test-debug.conf | 60 +- tests/data/test-express.conf | 60 +- tests/data/test.conf | 60 +- tests/test-hdr/CMakeLists.txt | 42 +- ...ilevel_hashmap.h => hdr_feldman_hashmap.h} | 10 +- .../test-hdr/map/hdr_feldman_hashmap_dhp.cpp | 198 ++++++ tests/test-hdr/map/hdr_feldman_hashmap_hp.cpp | 198 ++++++ .../map/hdr_feldman_hashmap_rcu_gpb.cpp | 197 ++++++ .../map/hdr_feldman_hashmap_rcu_gpi.cpp | 197 ++++++ .../map/hdr_feldman_hashmap_rcu_gpt.cpp | 197 ++++++ .../map/hdr_feldman_hashmap_rcu_shb.cpp | 223 +++++++ .../map/hdr_feldman_hashmap_rcu_sht.cpp | 223 +++++++ .../map/hdr_multilevel_hashmap_dhp.cpp | 198 ------ .../map/hdr_multilevel_hashmap_hp.cpp | 198 ------ .../map/hdr_multilevel_hashmap_rcu_gpb.cpp | 197 ------ .../map/hdr_multilevel_hashmap_rcu_gpi.cpp | 197 ------ .../map/hdr_multilevel_hashmap_rcu_gpt.cpp | 197 ------ .../map/hdr_multilevel_hashmap_rcu_shb.cpp | 223 ------- .../map/hdr_multilevel_hashmap_rcu_sht.cpp | 223 ------- ...ilevel_hashset.h => hdr_feldman_hashset.h} | 10 +- ...et_dhp.cpp => hdr_feldman_hashset_dhp.cpp} | 174 +++--- ...hset_hp.cpp => hdr_feldman_hashset_hp.cpp} | 176 +++--- ...pb.cpp => hdr_feldman_hashset_rcu_gpb.cpp} | 174 +++--- ...pi.cpp => hdr_feldman_hashset_rcu_gpi.cpp} | 174 +++--- ...pt.cpp => hdr_feldman_hashset_rcu_gpt.cpp} | 174 +++--- ...hb.cpp => hdr_feldman_hashset_rcu_shb.cpp} | 174 +++--- ...ht.cpp => hdr_feldman_hashset_rcu_sht.cpp} | 174 +++--- ...hset.h => hdr_intrusive_feldman_hashset.h} | 10 +- ... => hdr_intrusive_feldman_hashset_dhp.cpp} | 174 +++--- ...p => hdr_intrusive_feldman_hashset_hp.cpp} | 176 +++--- ...hdr_intrusive_feldman_hashset_rcu_gpb.cpp} | 174 +++--- ...hdr_intrusive_feldman_hashset_rcu_gpi.cpp} | 174 +++--- ...hdr_intrusive_feldman_hashset_rcu_gpt.cpp} | 174 +++--- ...hdr_intrusive_feldman_hashset_rcu_shb.cpp} | 174 +++--- ...hdr_intrusive_feldman_hashset_rcu_sht.cpp} | 174 +++--- tests/unit/map2/CMakeLists.txt | 18 +- tests/unit/map2/map_defs.h | 564 +++++++++--------- tests/unit/map2/map_delodd.cpp | 4 +- tests/unit/map2/map_delodd.h | 14 +- ...hmap.cpp => map_delodd_feldmanhashmap.cpp} | 6 +- tests/unit/map2/map_find_int.cpp | 4 +- tests/unit/map2/map_find_int.h | 8 +- ...ap.cpp => map_find_int_feldmanhashmap.cpp} | 4 +- tests/unit/map2/map_find_string.cpp | 4 +- tests/unit/map2/map_find_string.h | 16 +- ...cpp => map_find_string_feldmanhashmap.cpp} | 8 +- tests/unit/map2/map_insdel_func.cpp | 4 +- tests/unit/map2/map_insdel_func.h | 14 +- ...cpp => map_insdel_func_feldmanhashmap.cpp} | 6 +- tests/unit/map2/map_insdel_int.cpp | 4 +- tests/unit/map2/map_insdel_int.h | 12 +- ....cpp => map_insdel_int_feldmanhashmap.cpp} | 6 +- tests/unit/map2/map_insdel_item_int.cpp | 4 +- tests/unit/map2/map_insdel_item_int.h | 14 +- ...=> map_insdel_item_int_feldmanhashmap.cpp} | 6 +- tests/unit/map2/map_insdel_item_string.cpp | 4 +- tests/unit/map2/map_insdel_item_string.h | 16 +- ...map_insdel_item_string_feldmanhashmap.cpp} | 8 +- tests/unit/map2/map_insdel_string.cpp | 4 +- tests/unit/map2/map_insdel_string.h | 12 +- ...p => map_insdel_string_feldmanhashmap.cpp} | 6 +- tests/unit/map2/map_insdelfind.cpp | 4 +- tests/unit/map2/map_insdelfind.h | 14 +- ....cpp => map_insdelfind_feldmanhashmap.cpp} | 6 +- tests/unit/map2/map_insfind_int.cpp | 4 +- tests/unit/map2/map_insfind_int.h | 12 +- ...cpp => map_insfind_int_feldmanhashmap.cpp} | 6 +- tests/unit/map2/map_type_feldman_hashmap.h | 227 +++++++ tests/unit/map2/map_type_multilevel_hashmap.h | 227 ------- ...et_stat.h => print_feldman_hashset_stat.h} | 14 +- tests/unit/set2/CMakeLists.txt | 8 +- tests/unit/set2/set_defs.h | 512 ++++++++-------- tests/unit/set2/set_delodd.cpp | 4 +- tests/unit/set2/set_delodd.h | 12 +- ...hset.cpp => set_delodd_feldmanhashset.cpp} | 6 +- tests/unit/set2/set_insdel_func.cpp | 4 +- tests/unit/set2/set_insdel_func.h | 12 +- ...cpp => set_insdel_func_feldmanhashset.cpp} | 6 +- tests/unit/set2/set_insdel_string.cpp | 4 +- tests/unit/set2/set_insdel_string.h | 20 +- ...p => set_insdel_string_feldmanhashset.cpp} | 10 +- tests/unit/set2/set_insdelfind.cpp | 4 +- tests/unit/set2/set_insdelfind.h | 8 +- ....cpp => set_insdelfind_feldmanhashset.cpp} | 4 +- tests/unit/set2/set_type_feldman_hashset.h | 341 +++++++++++ tests/unit/set2/set_type_multilevel_hashset.h | 341 ----------- 148 files changed, 4732 insertions(+), 4732 deletions(-) rename cds/container/details/{multilevel_hashmap_base.h => feldman_hashmap_base.h} (81%) rename cds/container/details/{multilevel_hashset_base.h => feldman_hashset_base.h} (63%) create mode 100644 cds/container/feldman_hashmap_dhp.h create mode 100644 cds/container/feldman_hashmap_hp.h rename cds/container/{multilevel_hashmap_rcu.h => feldman_hashmap_rcu.h} (91%) create mode 100644 cds/container/feldman_hashset_dhp.h create mode 100644 cds/container/feldman_hashset_hp.h rename cds/container/{multilevel_hashset_rcu.h => feldman_hashset_rcu.h} (87%) rename cds/container/impl/{multilevel_hashmap.h => feldman_hashmap.h} (91%) rename cds/container/impl/{multilevel_hashset.h => feldman_hashset.h} (88%) delete mode 100644 cds/container/multilevel_hashmap_dhp.h delete mode 100644 cds/container/multilevel_hashmap_hp.h delete mode 100644 cds/container/multilevel_hashset_dhp.h delete mode 100644 cds/container/multilevel_hashset_hp.h rename cds/intrusive/details/{multilevel_hashset_base.h => feldman_hashset_base.h} (90%) create mode 100644 cds/intrusive/feldman_hashset_dhp.h create mode 100644 cds/intrusive/feldman_hashset_hp.h rename cds/intrusive/{multilevel_hashset_rcu.h => feldman_hashset_rcu.h} (94%) rename cds/intrusive/impl/{multilevel_hashset.h => feldman_hashset.h} (93%) delete mode 100644 cds/intrusive/multilevel_hashset_dhp.h delete mode 100644 cds/intrusive/multilevel_hashset_hp.h rename tests/test-hdr/map/{hdr_multilevel_hashmap.h => hdr_feldman_hashmap.h} (99%) create mode 100644 tests/test-hdr/map/hdr_feldman_hashmap_dhp.cpp create mode 100644 tests/test-hdr/map/hdr_feldman_hashmap_hp.cpp create mode 100644 tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpb.cpp create mode 100644 tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpi.cpp create mode 100644 tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpt.cpp create mode 100644 tests/test-hdr/map/hdr_feldman_hashmap_rcu_shb.cpp create mode 100644 tests/test-hdr/map/hdr_feldman_hashmap_rcu_sht.cpp delete mode 100644 tests/test-hdr/map/hdr_multilevel_hashmap_dhp.cpp delete mode 100644 tests/test-hdr/map/hdr_multilevel_hashmap_hp.cpp delete mode 100644 tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpb.cpp delete mode 100644 tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpi.cpp delete mode 100644 tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpt.cpp delete mode 100644 tests/test-hdr/map/hdr_multilevel_hashmap_rcu_shb.cpp delete mode 100644 tests/test-hdr/map/hdr_multilevel_hashmap_rcu_sht.cpp rename tests/test-hdr/set/{hdr_multilevel_hashset.h => hdr_feldman_hashset.h} (99%) rename tests/test-hdr/set/{hdr_multilevel_hashset_dhp.cpp => hdr_feldman_hashset_dhp.cpp} (52%) rename tests/test-hdr/set/{hdr_multilevel_hashset_hp.cpp => hdr_feldman_hashset_hp.cpp} (52%) rename tests/test-hdr/set/{hdr_multilevel_hashset_rcu_gpb.cpp => hdr_feldman_hashset_rcu_gpb.cpp} (52%) rename tests/test-hdr/set/{hdr_multilevel_hashset_rcu_gpi.cpp => hdr_feldman_hashset_rcu_gpi.cpp} (52%) rename tests/test-hdr/set/{hdr_multilevel_hashset_rcu_gpt.cpp => hdr_feldman_hashset_rcu_gpt.cpp} (52%) rename tests/test-hdr/set/{hdr_multilevel_hashset_rcu_shb.cpp => hdr_feldman_hashset_rcu_shb.cpp} (55%) rename tests/test-hdr/set/{hdr_multilevel_hashset_rcu_sht.cpp => hdr_feldman_hashset_rcu_sht.cpp} (55%) rename tests/test-hdr/set/{hdr_intrusive_multilevel_hashset.h => hdr_intrusive_feldman_hashset.h} (98%) rename tests/test-hdr/set/{hdr_intrusive_multilevel_hashset_dhp.cpp => hdr_intrusive_feldman_hashset_dhp.cpp} (56%) rename tests/test-hdr/set/{hdr_intrusive_multilevel_hashset_hp.cpp => hdr_intrusive_feldman_hashset_hp.cpp} (56%) rename tests/test-hdr/set/{hdr_intrusive_multilevel_hashset_rcu_gpb.cpp => hdr_intrusive_feldman_hashset_rcu_gpb.cpp} (56%) rename tests/test-hdr/set/{hdr_intrusive_multilevel_hashset_rcu_gpi.cpp => hdr_intrusive_feldman_hashset_rcu_gpi.cpp} (56%) rename tests/test-hdr/set/{hdr_intrusive_multilevel_hashset_rcu_gpt.cpp => hdr_intrusive_feldman_hashset_rcu_gpt.cpp} (56%) rename tests/test-hdr/set/{hdr_intrusive_multilevel_hashset_rcu_shb.cpp => hdr_intrusive_feldman_hashset_rcu_shb.cpp} (58%) rename tests/test-hdr/set/{hdr_intrusive_multilevel_hashset_rcu_sht.cpp => hdr_intrusive_feldman_hashset_rcu_sht.cpp} (58%) rename tests/unit/map2/{map_delodd_multilevelhashmap.cpp => map_delodd_feldmanhashmap.cpp} (64%) rename tests/unit/map2/{map_find_int_multilevelhashmap.cpp => map_find_int_feldmanhashmap.cpp} (74%) rename tests/unit/map2/{map_find_string_multilevelhashmap.cpp => map_find_string_feldmanhashmap.cpp} (59%) rename tests/unit/map2/{map_insdel_func_multilevelhashmap.cpp => map_insdel_func_feldmanhashmap.cpp} (65%) rename tests/unit/map2/{map_insdel_int_multilevelhashmap.cpp => map_insdel_int_feldmanhashmap.cpp} (65%) rename tests/unit/map2/{map_insdel_item_int_multilevelhashmap.cpp => map_insdel_item_int_feldmanhashmap.cpp} (66%) rename tests/unit/map2/{map_insdel_item_string_multilevelhashmap.cpp => map_insdel_item_string_feldmanhashmap.cpp} (60%) rename tests/unit/map2/{map_insdel_string_multilevelhashmap.cpp => map_insdel_string_feldmanhashmap.cpp} (65%) rename tests/unit/map2/{map_insdelfind_multilevelhashmap.cpp => map_insdelfind_feldmanhashmap.cpp} (65%) rename tests/unit/map2/{map_insfind_int_multilevelhashmap.cpp => map_insfind_int_feldmanhashmap.cpp} (65%) create mode 100644 tests/unit/map2/map_type_feldman_hashmap.h delete mode 100644 tests/unit/map2/map_type_multilevel_hashmap.h rename tests/unit/{print_multilevel_hashset_stat.h => print_feldman_hashset_stat.h} (84%) rename tests/unit/set2/{set_delodd_multilevelhashset.cpp => set_delodd_feldmanhashset.cpp} (65%) rename tests/unit/set2/{set_insdel_func_multilevelhashset.cpp => set_insdel_func_feldmanhashset.cpp} (65%) rename tests/unit/set2/{set_insdel_string_multilevelhashset.cpp => set_insdel_string_feldmanhashset.cpp} (54%) rename tests/unit/set2/{set_insdelfind_multilevelhashset.cpp => set_insdelfind_feldmanhashset.cpp} (75%) create mode 100644 tests/unit/set2/set_type_feldman_hashset.h delete mode 100644 tests/unit/set2/set_type_multilevel_hashset.h diff --git a/cds/container/details/multilevel_hashmap_base.h b/cds/container/details/feldman_hashmap_base.h similarity index 81% rename from cds/container/details/multilevel_hashmap_base.h rename to cds/container/details/feldman_hashmap_base.h index b06b5cb7..20eab6b3 100644 --- a/cds/container/details/multilevel_hashmap_base.h +++ b/cds/container/details/feldman_hashmap_base.h @@ -1,34 +1,34 @@ //$$CDS-header$$ -#ifndef CDSLIB_CONTAINER_DETAILS_MULTILEVEL_HASHMAP_BASE_H -#define CDSLIB_CONTAINER_DETAILS_MULTILEVEL_HASHMAP_BASE_H +#ifndef CDSLIB_CONTAINER_DETAILS_FELDMAN_HASHMAP_BASE_H +#define CDSLIB_CONTAINER_DETAILS_FELDMAN_HASHMAP_BASE_H -#include +#include #include #include namespace cds { namespace container { - /// \p MultiLevelHashMap related definitions + /// \p FeldmanHashMap related definitions /** @ingroup cds_nonintrusive_helper */ - namespace multilevel_hashmap { - /// \p MultiLevelHashMap internal statistics, see cds::intrusive::multilevel_hashset::stat + namespace feldman_hashmap { + /// \p FeldmanHashMap internal statistics, see cds::intrusive::feldman_hashset::stat template - using stat = cds::intrusive::multilevel_hashset::stat< EventCounter >; + using stat = cds::intrusive::feldman_hashset::stat< EventCounter >; - /// \p MultiLevelHashMap empty internal statistics - typedef cds::intrusive::multilevel_hashset::empty_stat empty_stat; + /// \p FeldmanHashMap empty internal statistics + typedef cds::intrusive::feldman_hashset::empty_stat empty_stat; /// Bit-wise memcmp-based comparator for hash value \p T template - using bitwise_compare = cds::intrusive::multilevel_hashset::bitwise_compare< T >; + using bitwise_compare = cds::intrusive::feldman_hashset::bitwise_compare< T >; - /// \p MultiLevelHashMap traits + /// \p FeldmanHashMap traits struct traits { /// Hash functor, default is \p opt::none /** - \p MultiLevelHashMap may use any hash functor converting a key to + \p FeldmanHashMap may use any hash functor converting a key to fixed-sized bit-string, for example, SHA1, SHA2, MurmurHash, CityHash @@ -67,7 +67,7 @@ namespace cds { namespace container { }; // IP4 address - statistics map - typedef cds::container::MultiLevelHashMap< cds::gc::HP, ip4_address, statistics, ip4_map_traits > ip4_map; + typedef cds::container::FeldmanHashMap< cds::gc::HP, ip4_address, statistics, ip4_map_traits > ip4_map; @endcode variable-size key requires a hash functor: URL map @@ -86,26 +86,26 @@ namespace cds { namespace container { }; // URL statistics map - typedef cds::container::MultiLevelHashMap< cds::gc::HP, std::string, statistics, url_map_traits > url_map; + typedef cds::container::FeldmanHashMap< cds::gc::HP, std::string, statistics, url_map_traits > url_map; @endcode */ typedef opt::none hash; /// Hash comparing functor /** - @copydetails cds::intrusive::multilevel_hashset::traits::compare + @copydetails cds::intrusive::feldman_hashset::traits::compare */ typedef cds::opt::none compare; /// Specifies binary predicate used for hash compare. /** - @copydetails cds::intrusive::multilevel_hashset::traits::less + @copydetails cds::intrusive::feldman_hashset::traits::less */ typedef cds::opt::none less; /// Item counter /** - @copydetails cds::intrusive::multilevel_hashset::traits::item_counter + @copydetails cds::intrusive::feldman_hashset::traits::item_counter */ typedef cds::atomicity::item_counter item_counter; @@ -117,13 +117,13 @@ namespace cds { namespace container { /// Array node allocator /** - @copydetails cds::intrusive::multilevel_hashset::traits::node_allocator + @copydetails cds::intrusive::feldman_hashset::traits::node_allocator */ typedef CDS_DEFAULT_ALLOCATOR node_allocator; /// C++ memory ordering model /** - @copydetails cds::intrusive::multilevel_hashset::traits::memory_model + @copydetails cds::intrusive::feldman_hashset::traits::memory_model */ typedef cds::opt::v::relaxed_ordering memory_model; @@ -132,18 +132,18 @@ namespace cds { namespace container { /// Internal statistics /** - @copydetails cds::intrusive::multilevel_hashset::traits::stat + @copydetails cds::intrusive::feldman_hashset::traits::stat */ typedef empty_stat stat; - /// RCU deadlock checking policy (only for \ref cds_container_MultilevelHashMap_rcu "RCU-based MultilevelHashMap") + /// RCU deadlock checking policy (only for \ref cds_container_FeldmanHashMap_rcu "RCU-based FeldmanHashMap") /** - @copydetails cds::intrusive::multilevel_hashset::traits::rcu_check_deadlock + @copydetails cds::intrusive::feldman_hashset::traits::rcu_check_deadlock */ typedef cds::opt::v::rcu_throw_deadlock rcu_check_deadlock; }; - /// Metafunction converting option list to \p multilevel_hashmap::traits + /// Metafunction converting option list to \p feldman_hashmap::traits /** Supported \p Options are: - \p opt::hash - a hash functor, default is \p std::hash @@ -155,15 +155,15 @@ namespace cds { namespace container { - \p opt::compare - hash comparison functor. No default functor is provided. If the option is not specified, the \p opt::less is used. - \p opt::less - specifies binary predicate used for hash comparison. - @copydetails cds::container::multilevel_hashmap::traits::less + @copydetails cds::container::feldman_hashmap::traits::less - \p opt::back_off - back-off strategy used. If the option is not specified, the \p cds::backoff::Default is used. - \p opt::item_counter - the type of item counting feature. - @copydetails cds::container::multilevel_hashmap::traits::item_counter + @copydetails cds::container::feldman_hashmap::traits::item_counter - \p opt::memory_model - C++ memory ordering model. Can be \p opt::v::relaxed_ordering (relaxed memory model, the default) or \p opt::v::sequential_consistent (sequentially consisnent memory model). - - \p opt::stat - internal statistics. By default, it is disabled (\p multilevel_hashmap::empty_stat). - To enable it use \p multilevel_hashmap::stat - - \p opt::rcu_check_deadlock - a deadlock checking policy for \ref cds_intrusive_MultilevelHashSet_rcu "RCU-based MultilevelHashSet" + - \p opt::stat - internal statistics. By default, it is disabled (\p feldman_hashmap::empty_stat). + To enable it use \p feldman_hashmap::stat + - \p opt::rcu_check_deadlock - a deadlock checking policy for \ref cds_intrusive_FeldmanHashSet_rcu "RCU-based FeldmanHashSet" Default is \p opt::v::rcu_throw_deadlock */ template @@ -178,12 +178,12 @@ namespace cds { namespace container { >::type type; # endif }; - } // namespace multilevel_hashmap + } // namespace feldman_hashmap //@cond // Forward declaration - template < class GC, typename Key, typename T, class Traits = multilevel_hashmap::traits > - class MultiLevelHashMap; + template < class GC, typename Key, typename T, class Traits = feldman_hashmap::traits > + class FeldmanHashMap; //@endcond //@cond @@ -285,7 +285,7 @@ namespace cds { namespace container { }; template - struct make_multilevel_hashmap + struct make_feldman_hashmap { typedef GC gc; typedef Key key_type; @@ -315,11 +315,11 @@ namespace cds { namespace container { }; // Metafunction result - typedef cds::intrusive::MultiLevelHashSet< GC, node_type, intrusive_traits > type; + typedef cds::intrusive::FeldmanHashSet< GC, node_type, intrusive_traits > type; }; } // namespace details //@endcond }} // namespace cds::container -#endif // #ifndef CDSLIB_CONTAINER_DETAILS_MULTILEVEL_HASHMAP_BASE_H +#endif // #ifndef CDSLIB_CONTAINER_DETAILS_FELDMAN_HASHMAP_BASE_H diff --git a/cds/container/details/multilevel_hashset_base.h b/cds/container/details/feldman_hashset_base.h similarity index 63% rename from cds/container/details/multilevel_hashset_base.h rename to cds/container/details/feldman_hashset_base.h index f0c7fca0..2f319627 100644 --- a/cds/container/details/multilevel_hashset_base.h +++ b/cds/container/details/feldman_hashset_base.h @@ -1,58 +1,58 @@ //$$CDS-header$$ -#ifndef CDSLIB_CONTAINER_DETAILS_MULTILEVEL_HASHSET_BASE_H -#define CDSLIB_CONTAINER_DETAILS_MULTILEVEL_HASHSET_BASE_H +#ifndef CDSLIB_CONTAINER_DETAILS_FELDMAN_HASHSET_BASE_H +#define CDSLIB_CONTAINER_DETAILS_FELDMAN_HASHSET_BASE_H -#include +#include #include namespace cds { namespace container { - /// \p MultiLevelHashSet related definitions + /// \p FeldmanHashSet related definitions /** @ingroup cds_nonintrusive_helper */ - namespace multilevel_hashset { + namespace feldman_hashset { /// Hash accessor option /** - @copydetails cds::intrusive::multilevel_hashset::traits::hash_accessor + @copydetails cds::intrusive::feldman_hashset::traits::hash_accessor */ template - using hash_accessor = cds::intrusive::multilevel_hashset::hash_accessor< Accessor >; + using hash_accessor = cds::intrusive::feldman_hashset::hash_accessor< Accessor >; - /// \p MultiLevelHashSet internal statistics, see cds::intrusive::multilevel_hashset::stat + /// \p FeldmanHashSet internal statistics, see cds::intrusive::feldman_hashset::stat template - using stat = cds::intrusive::multilevel_hashset::stat< EventCounter >; + using stat = cds::intrusive::feldman_hashset::stat< EventCounter >; - /// \p MultiLevelHashSet empty internal statistics - typedef cds::intrusive::multilevel_hashset::empty_stat empty_stat; + /// \p FeldmanHashSet empty internal statistics + typedef cds::intrusive::feldman_hashset::empty_stat empty_stat; /// Bit-wise memcmp-based comparator for hash value \p T template - using bitwise_compare = cds::intrusive::multilevel_hashset::bitwise_compare< T >; + using bitwise_compare = cds::intrusive::feldman_hashset::bitwise_compare< T >; - /// \p MultiLevelHashSet traits + /// \p FeldmanHashSet traits struct traits { /// Mandatory functor to get hash value from data node /** - @copydetails cds::intrusive::multilevel_hashset::traits::hash_accessor + @copydetails cds::intrusive::feldman_hashset::traits::hash_accessor */ typedef cds::opt::none hash_accessor; /// Hash comparing functor /** - @copydetails cds::intrusive::multilevel_hashset::traits::compare + @copydetails cds::intrusive::feldman_hashset::traits::compare */ typedef cds::opt::none compare; /// Specifies binary predicate used for hash compare. /** - @copydetails cds::intrusive::multilevel_hashset::traits::less + @copydetails cds::intrusive::feldman_hashset::traits::less */ typedef cds::opt::none less; /// Item counter /** - @copydetails cds::intrusive::multilevel_hashset::traits::item_counter + @copydetails cds::intrusive::feldman_hashset::traits::item_counter */ typedef cds::atomicity::item_counter item_counter; @@ -64,13 +64,13 @@ namespace cds { namespace container { /// Array node allocator /** - @copydetails cds::intrusive::multilevel_hashset::traits::node_allocator + @copydetails cds::intrusive::feldman_hashset::traits::node_allocator */ typedef CDS_DEFAULT_ALLOCATOR node_allocator; /// C++ memory ordering model /** - @copydetails cds::intrusive::multilevel_hashset::traits::memory_model + @copydetails cds::intrusive::feldman_hashset::traits::memory_model */ typedef cds::opt::v::relaxed_ordering memory_model; @@ -79,21 +79,21 @@ namespace cds { namespace container { /// Internal statistics /** - @copydetails cds::intrusive::multilevel_hashset::traits::stat + @copydetails cds::intrusive::feldman_hashset::traits::stat */ typedef empty_stat stat; - /// RCU deadlock checking policy (only for \ref cds_container_MultilevelHashSet_rcu "RCU-based MultilevelHashSet") + /// RCU deadlock checking policy (only for \ref cds_container_FeldmanHashSet_rcu "RCU-based FeldmanHashSet") /** - @copydetails cds::intrusive::multilevel_hashset::traits::rcu_check_deadlock + @copydetails cds::intrusive::feldman_hashset::traits::rcu_check_deadlock */ typedef cds::opt::v::rcu_throw_deadlock rcu_check_deadlock; }; - /// Metafunction converting option list to \p multilevel_hashset::traits + /// Metafunction converting option list to \p feldman_hashset::traits /** Supported \p Options are: - - \p multilevel_hashset::hash_accessor - mandatory option, hash accessor functor. + - \p feldman_hashset::hash_accessor - mandatory option, hash accessor functor. @copydetails traits::hash_accessor - \p opt::allocator - item allocator @copydetails traits::allocator @@ -102,15 +102,15 @@ namespace cds { namespace container { - \p opt::compare - hash comparison functor. No default functor is provided. If the option is not specified, the \p opt::less is used. - \p opt::less - specifies binary predicate used for hash comparison. - @copydetails cds::container::multilevel_hashset::traits::less + @copydetails cds::container::feldman_hashset::traits::less - \p opt::back_off - back-off strategy used. If the option is not specified, the \p cds::backoff::Default is used. - \p opt::item_counter - the type of item counting feature. - @copydetails cds::intrusive::multilevel_hashset::traits::item_counter + @copydetails cds::intrusive::feldman_hashset::traits::item_counter - \p opt::memory_model - C++ memory ordering model. Can be \p opt::v::relaxed_ordering (relaxed memory model, the default) or \p opt::v::sequential_consistent (sequentially consisnent memory model). - - \p opt::stat - internal statistics. By default, it is disabled (\p multilevel_hashset::empty_stat). - To enable it use \p multilevel_hashset::stat - - \p opt::rcu_check_deadlock - a deadlock checking policy for \ref cds_intrusive_MultilevelHashSet_rcu "RCU-based MultilevelHashSet" + - \p opt::stat - internal statistics. By default, it is disabled (\p feldman_hashset::empty_stat). + To enable it use \p feldman_hashset::stat + - \p opt::rcu_check_deadlock - a deadlock checking policy for \ref cds_intrusive_FeldmanHashSet_rcu "RCU-based FeldmanHashSet" Default is \p opt::v::rcu_throw_deadlock */ template @@ -125,19 +125,19 @@ namespace cds { namespace container { >::type type; # endif }; - } // namespace multilevel_hashset + } // namespace feldman_hashset //@cond // Forward declaration - template < class GC, typename T, class Traits = cds::container::multilevel_hashset::traits > - class MultiLevelHashSet; + template < class GC, typename T, class Traits = cds::container::feldman_hashset::traits > + class FeldmanHashSet; //@endcond //@cond namespace details { template - struct make_multilevel_hashset + struct make_feldman_hashset { typedef GC gc; typedef T value_type; @@ -159,11 +159,11 @@ namespace cds { namespace container { }; // Metafunction result - typedef cds::intrusive::MultiLevelHashSet< GC, T, intrusive_traits > type; + typedef cds::intrusive::FeldmanHashSet< GC, T, intrusive_traits > type; }; } // namespace details //@endcond }} // namespace cds::container -#endif // #ifndef CDSLIB_CONTAINER_DETAILS_MULTILEVEL_HASHSET_BASE_H +#endif // #ifndef CDSLIB_CONTAINER_DETAILS_FELDMAN_HASHSET_BASE_H diff --git a/cds/container/feldman_hashmap_dhp.h b/cds/container/feldman_hashmap_dhp.h new file mode 100644 index 00000000..85ea7af2 --- /dev/null +++ b/cds/container/feldman_hashmap_dhp.h @@ -0,0 +1,9 @@ +//$$CDS-header$$ + +#ifndef CDSLIB_CONTAINER_FELDMAN_HASHMAP_DHP_H +#define CDSLIB_CONTAINER_FELDMAN_HASHMAP_DHP_H + +#include +#include + +#endif // #ifndef CDSLIB_CONTAINER_FELDMAN_HASHMAP_DHP_H diff --git a/cds/container/feldman_hashmap_hp.h b/cds/container/feldman_hashmap_hp.h new file mode 100644 index 00000000..50c66a87 --- /dev/null +++ b/cds/container/feldman_hashmap_hp.h @@ -0,0 +1,9 @@ +//$$CDS-header$$ + +#ifndef CDSLIB_CONTAINER_FELDMAN_HASHMAP_HP_H +#define CDSLIB_CONTAINER_FELDMAN_HASHMAP_HP_H + +#include +#include + +#endif // #ifndef CDSLIB_CONTAINER_FELDMAN_HASHMAP_HP_H diff --git a/cds/container/multilevel_hashmap_rcu.h b/cds/container/feldman_hashmap_rcu.h similarity index 91% rename from cds/container/multilevel_hashmap_rcu.h rename to cds/container/feldman_hashmap_rcu.h index c049b436..501766a3 100644 --- a/cds/container/multilevel_hashmap_rcu.h +++ b/cds/container/feldman_hashmap_rcu.h @@ -1,45 +1,45 @@ //$$CDS-header$$ -#ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHMAP_RCU_H -#define CDSLIB_CONTAINER_MULTILEVEL_HASHMAP_RCU_H +#ifndef CDSLIB_CONTAINER_FELDMAN_HASHMAP_RCU_H +#define CDSLIB_CONTAINER_FELDMAN_HASHMAP_RCU_H -#include -#include +#include +#include namespace cds { namespace container { /// Hash map based on multi-level array /** @ingroup cds_nonintrusive_map - @anchor cds_container_MultilevelHashMap_rcu + @anchor cds_container_FeldmanHashMap_rcu Source: - [2013] Steven Feldman, Pierre LaBorde, Damian Dechev "Concurrent Multi-level Arrays: Wait-free Extensible Hash Maps" - See algorithm short description @ref cds_container_MultilevelHashMap_hp "here" + See algorithm short description @ref cds_container_FeldmanHashMap_hp "here" - @note Two important things you should keep in mind when you're using \p %MultiLevelHashMap: + @note Two important things you should keep in mind when you're using \p %FeldmanHashMap: - all keys is converted to fixed-size bit-string by hash functor provided. - You can use variable-length keys, for example, \p std::string as a key for \p %MultiLevelHashMap, + You can use variable-length keys, for example, \p std::string as a key for \p %FeldmanHashMap, but real key in the map will be fixed-size hash values of your keys. For the strings you may use well-known hashing algorithms like SHA1, SHA2, MurmurHash, CityHash or its successor FarmHash and so on, which - converts variable-length strings to fixed-length bit-strings, and such hash values will be the keys in \p %MultiLevelHashMap. - If your key is fixed-sized the hash functor is optional, see \p multilevel_hashmap::traits::hash for explanation and examples. - - \p %MultiLevelHashMap uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, - have identical hash then you cannot insert both that keys in the map. \p %MultiLevelHashMap does not maintain the key, + converts variable-length strings to fixed-length bit-strings, and such hash values will be the keys in \p %FeldmanHashMap. + If your key is fixed-sized the hash functor is optional, see \p feldman_hashmap::traits::hash for explanation and examples. + - \p %FeldmanHashMap uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, + have identical hash then you cannot insert both that keys in the map. \p %FeldmanHashMap does not maintain the key, it maintains its fixed-size hash value. - The map supports @ref cds_container_MultilevelHashMap_rcu_iterators "bidirectional thread-safe iterators". + The map supports @ref cds_container_FeldmanHashMap_rcu_iterators "bidirectional thread-safe iterators". Template parameters: - \p RCU - one of \ref cds_urcu_gc "RCU type" - \p Key - a key type to be stored in the map - \p T - a value type to be stored in the map - - \p Traits - type traits, the structure based on \p multilevel_hashmap::traits or result of \p multilevel_hashmap::make_traits metafunction. + - \p Traits - type traits, the structure based on \p feldman_hashmap::traits or result of \p feldman_hashmap::make_traits metafunction. - @note Before including you should include appropriate RCU header file, + @note Before including you should include appropriate RCU header file, see \ref cds_urcu_gc "RCU type" for list of existing RCU class and corresponding header files. */ template < @@ -47,20 +47,20 @@ namespace cds { namespace container { ,typename Key ,typename T #ifdef CDS_DOXYGEN_INVOKED - ,class Traits = multilevel_hashmap::traits + ,class Traits = feldman_hashmap::traits #else ,class Traits #endif > - class MultiLevelHashMap< cds::urcu::gc< RCU >, Key, T, Traits > + class FeldmanHashMap< cds::urcu::gc< RCU >, Key, T, Traits > #ifdef CDS_DOXYGEN_INVOKED - : protected cds::intrusive::MultiLevelHashSet< cds::urcu::gc< RCU >, std::pair, Traits > + : protected cds::intrusive::FeldmanHashSet< cds::urcu::gc< RCU >, std::pair, Traits > #else - : protected cds::container::details::make_multilevel_hashmap< cds::urcu::gc< RCU >, Key, T, Traits >::type + : protected cds::container::details::make_feldman_hashmap< cds::urcu::gc< RCU >, Key, T, Traits >::type #endif { //@cond - typedef cds::container::details::make_multilevel_hashmap< cds::urcu::gc< RCU >, Key, T, Traits > maker; + typedef cds::container::details::make_feldman_hashmap< cds::urcu::gc< RCU >, Key, T, Traits > maker; typedef typename maker::type base_class; //@endcond public: @@ -70,7 +70,7 @@ namespace cds { namespace container { typedef std::pair< key_type const, mapped_type> value_type; ///< Key-value pair to be stored in the map typedef Traits traits; ///< Map traits #ifdef CDS_DOXYGEN_INVOKED - typedef typename traits::hash hasher; ///< Hash functor, see \p multilevel_hashmap::traits::hash + typedef typename traits::hash hasher; ///< Hash functor, see \p feldman_hashmap::traits::hash #else typedef typename maker::hasher hasher; #endif @@ -110,7 +110,7 @@ namespace cds { namespace container { template class bidirectional_iterator: public base_class::iterator_base { - friend class MultiLevelHashMap; + friend class FeldmanHashMap; typedef typename base_class::iterator_base iterator_base; protected: @@ -190,7 +190,7 @@ namespace cds { namespace container { template class reverse_bidirectional_iterator : public base_class::iterator_base { - friend class MultiLevelHashMap; + friend class FeldmanHashMap; typedef typename base_class::iterator_base iterator_base; public: @@ -269,10 +269,10 @@ namespace cds { namespace container { public: #ifdef CDS_DOXYGEN_INVOKED - typedef implementation_defined iterator; ///< @ref cds_container_MultilevelHashMap_rcu_iterators "bidirectional iterator" type - typedef implementation_defined const_iterator; ///< @ref cds_container_MultilevelHashMap_rcu_iterators "bidirectional const iterator" type - typedef implementation_defined reverse_iterator; ///< @ref cds_container_MultilevelHashMap_rcu_iterators "bidirectional reverse iterator" type - typedef implementation_defined const_reverse_iterator; ///< @ref cds_container_MultilevelHashMap_rcu_iterators "bidirectional reverse const iterator" type + typedef implementation_defined iterator; ///< @ref cds_container_FeldmanHashMap_rcu_iterators "bidirectional iterator" type + typedef implementation_defined const_iterator; ///< @ref cds_container_FeldmanHashMap_rcu_iterators "bidirectional const iterator" type + typedef implementation_defined reverse_iterator; ///< @ref cds_container_FeldmanHashMap_rcu_iterators "bidirectional reverse iterator" type + typedef implementation_defined const_reverse_iterator; ///< @ref cds_container_FeldmanHashMap_rcu_iterators "bidirectional reverse const iterator" type #else typedef bidirectional_iterator iterator; typedef bidirectional_iterator const_iterator; @@ -297,12 +297,12 @@ namespace cds { namespace container { \endcode where \p N is multi-level array depth. */ - MultiLevelHashMap( size_t head_bits = 8, size_t array_bits = 4 ) + FeldmanHashMap( size_t head_bits = 8, size_t array_bits = 4 ) : base_class( head_bits, array_bits ) {} /// Destructs the map and frees all data - ~MultiLevelHashMap() + ~FeldmanHashMap() {} /// Inserts new element with key and default value @@ -500,7 +500,7 @@ namespace cds { namespace container { its \p release() member function is called. Example: \code - typedef cds::container::MultiLevelHashMap< cds::urcu::gc< cds::urcu::general_buffered<>>, int, foo, my_traits > map_type; + typedef cds::container::FeldmanHashMap< cds::urcu::gc< cds::urcu::general_buffered<>>, int, foo, my_traits > map_type; map_type theMap; // ... @@ -572,7 +572,7 @@ namespace cds { namespace container { Usage: \code - typedef cds::container::MultiLevelHashMap< your_template_params > my_map; + typedef cds::container::FeldmanHashMap< your_template_params > my_map; my_map theMap; // ... { @@ -641,7 +641,7 @@ namespace cds { namespace container { public: ///@name Thread-safe iterators - /** @anchor cds_container_MultilevelHashMap_rcu_iterators + /** @anchor cds_container_FeldmanHashMap_rcu_iterators The map supports thread-safe iterators: you may iterate over the map in multi-threaded environment under explicit RCU lock. RCU lock requirement means that inserting or searching is allowed but you must not erase the items from the map @@ -655,7 +655,7 @@ namespace cds { namespace container { uint32_t payload; // only for example }; typedef cds::urcu::gc< cds::urcu::general_buffered<>> rcu; - typedef cds::container::MultiLevelHashMap< rcu, std::string, foo> map_type; + typedef cds::container::FeldmanHashMap< rcu, std::string, foo> map_type; map_type m; @@ -777,4 +777,4 @@ namespace cds { namespace container { }; }} // namespace cds::container -#endif // #ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHMAP_RCU_H +#endif // #ifndef CDSLIB_CONTAINER_FELDMAN_HASHMAP_RCU_H diff --git a/cds/container/feldman_hashset_dhp.h b/cds/container/feldman_hashset_dhp.h new file mode 100644 index 00000000..ce87b590 --- /dev/null +++ b/cds/container/feldman_hashset_dhp.h @@ -0,0 +1,9 @@ +//$$CDS-header$$ + +#ifndef CDSLIB_CONTAINER_FELDMAN_HASHSET_DHP_H +#define CDSLIB_CONTAINER_FELDMAN_HASHSET_DHP_H + +#include +#include + +#endif // #ifndef CDSLIB_CONTAINER_FELDMAN_HASHSET_DHP_H diff --git a/cds/container/feldman_hashset_hp.h b/cds/container/feldman_hashset_hp.h new file mode 100644 index 00000000..00ac7049 --- /dev/null +++ b/cds/container/feldman_hashset_hp.h @@ -0,0 +1,9 @@ +//$$CDS-header$$ + +#ifndef CDSLIB_CONTAINER_FELDMAN_HASHSET_HP_H +#define CDSLIB_CONTAINER_FELDMAN_HASHSET_HP_H + +#include +#include + +#endif // #ifndef CDSLIB_CONTAINER_FELDMAN_HASHSET_HP_H diff --git a/cds/container/multilevel_hashset_rcu.h b/cds/container/feldman_hashset_rcu.h similarity index 87% rename from cds/container/multilevel_hashset_rcu.h rename to cds/container/feldman_hashset_rcu.h index fdd1f5ed..b8bbccff 100644 --- a/cds/container/multilevel_hashset_rcu.h +++ b/cds/container/feldman_hashset_rcu.h @@ -1,73 +1,73 @@ //$$CDS-header$$ -#ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHSET_RCU_H -#define CDSLIB_CONTAINER_MULTILEVEL_HASHSET_RCU_H +#ifndef CDSLIB_CONTAINER_FELDMAN_HASHSET_RCU_H +#define CDSLIB_CONTAINER_FELDMAN_HASHSET_RCU_H -#include -#include +#include +#include namespace cds { namespace container { /// Hash set based on multi-level array, \ref cds_urcu_desc "RCU" specialization /** @ingroup cds_nonintrusive_set - @anchor cds_container_MultilevelHashSet_rcu + @anchor cds_container_FeldmanHashSet_rcu Source: - [2013] Steven Feldman, Pierre LaBorde, Damian Dechev "Concurrent Multi-level Arrays: Wait-free Extensible Hash Maps" - See algorithm short description @ref cds_intrusive_MultilevelHashSet_hp "here" + See algorithm short description @ref cds_intrusive_FeldmanHashSet_hp "here" - @note Two important things you should keep in mind when you're using \p %MultiLevelHashSet: - - all keys must be fixed-size. It means that you cannot use \p std::string as a key for \p %MultiLevelHashSet. + @note Two important things you should keep in mind when you're using \p %FeldmanHashSet: + - all keys must be fixed-size. It means that you cannot use \p std::string as a key for \p %FeldmanHashSet. Instead, for the strings you should use well-known hashing algorithms like SHA1, SHA2, MurmurHash, CityHash or its successor FarmHash and so on, which - converts variable-length strings to fixed-length bit-strings, and use that hash as a key in \p %MultiLevelHashSet. - - \p %MultiLevelHashSet uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, - have identical hash then you cannot insert both that keys in the set. \p %MultiLevelHashSet does not maintain the key, + converts variable-length strings to fixed-length bit-strings, and use that hash as a key in \p %FeldmanHashSet. + - \p %FeldmanHashSet uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, + have identical hash then you cannot insert both that keys in the set. \p %FeldmanHashSet does not maintain the key, it maintains its fixed-size hash value. - The set supports @ref cds_container_MultilevelHashSet_iterators "bidirectional thread-safe iterators". + The set supports @ref cds_container_FeldmanHashSet_iterators "bidirectional thread-safe iterators". Template parameters: - \p RCU - one of \ref cds_urcu_gc "RCU type" - \p T - a value type to be stored in the set - - \p Traits - type traits, the structure based on \p multilevel_hashset::traits or result of \p multilevel_hashset::make_traits metafunction. - \p Traits is the mandatory argument because it has one mandatory type - an @ref multilevel_hashset::traits::hash_accessor "accessor" + - \p Traits - type traits, the structure based on \p feldman_hashset::traits or result of \p feldman_hashset::make_traits metafunction. + \p Traits is the mandatory argument because it has one mandatory type - an @ref feldman_hashset::traits::hash_accessor "accessor" to hash value of \p T. The set algorithm does not calculate that hash value. - @note Before including you should include appropriate RCU header file, + @note Before including you should include appropriate RCU header file, see \ref cds_urcu_gc "RCU type" for list of existing RCU class and corresponding header files. - The set supports @ref cds_container_MultilevelHashSet_rcu_iterators "bidirectional thread-safe iterators" + The set supports @ref cds_container_FeldmanHashSet_rcu_iterators "bidirectional thread-safe iterators" with some restrictions. */ template < class RCU , typename T #ifdef CDS_DOXYGEN_INVOKED - , class Traits = multilevel_hashset::traits + , class Traits = feldman_hashset::traits #else , class Traits #endif > - class MultiLevelHashSet< cds::urcu::gc< RCU >, T, Traits > + class FeldmanHashSet< cds::urcu::gc< RCU >, T, Traits > #ifdef CDS_DOXYGEN_INVOKED - : protected cds::intrusive::MultiLevelHashSet< cds::urcu::gc< RCU >, T, Traits > + : protected cds::intrusive::FeldmanHashSet< cds::urcu::gc< RCU >, T, Traits > #else - : protected cds::container::details::make_multilevel_hashset< cds::urcu::gc< RCU >, T, Traits >::type + : protected cds::container::details::make_feldman_hashset< cds::urcu::gc< RCU >, T, Traits >::type #endif { //@cond - typedef cds::container::details::make_multilevel_hashset< cds::urcu::gc< RCU >, T, Traits > maker; + typedef cds::container::details::make_feldman_hashset< cds::urcu::gc< RCU >, T, Traits > maker; typedef typename maker::type base_class; //@endcond public: typedef cds::urcu::gc< RCU > gc; ///< RCU garbage collector typedef T value_type; ///< type of value stored in the set - typedef Traits traits; ///< Traits template parameter, see \p multilevel_hashset::traits + typedef Traits traits; ///< Traits template parameter, see \p feldman_hashset::traits typedef typename base_class::hash_accessor hash_accessor; ///< Hash accessor functor typedef typename base_class::hash_type hash_type; ///< Hash type deduced from \p hash_accessor return type @@ -84,10 +84,10 @@ namespace cds { namespace container { static CDS_CONSTEXPR const bool c_bExtractLockExternal = false; ///< Group of \p extract_xxx functions does not require external locking typedef typename base_class::exempt_ptr exempt_ptr; ///< pointer to extracted node - typedef typename base_class::iterator iterator; ///< @ref cds_container_MultilevelHashSet_rcu_iterators "bidirectional iterator" type - typedef typename base_class::const_iterator const_iterator; ///< @ref cds_container_MultilevelHashSet_rcu_iterators "bidirectional const iterator" type - typedef typename base_class::reverse_iterator reverse_iterator; ///< @ref cds_container_MultilevelHashSet_rcu_iterators "bidirectional reverse iterator" type - typedef typename base_class::const_reverse_iterator const_reverse_iterator; ///< @ref cds_container_MultilevelHashSet_rcu_iterators "bidirectional reverse const iterator" type + typedef typename base_class::iterator iterator; ///< @ref cds_container_FeldmanHashSet_rcu_iterators "bidirectional iterator" type + typedef typename base_class::const_iterator const_iterator; ///< @ref cds_container_FeldmanHashSet_rcu_iterators "bidirectional const iterator" type + typedef typename base_class::reverse_iterator reverse_iterator; ///< @ref cds_container_FeldmanHashSet_rcu_iterators "bidirectional reverse iterator" type + typedef typename base_class::const_reverse_iterator const_reverse_iterator; ///< @ref cds_container_FeldmanHashSet_rcu_iterators "bidirectional reverse const iterator" type protected: //@cond @@ -107,12 +107,12 @@ namespace cds { namespace container { \endcode where \p N is multi-level array depth. */ - MultiLevelHashSet( size_t head_bits = 8, size_t array_bits = 4 ) + FeldmanHashSet( size_t head_bits = 8, size_t array_bits = 4 ) : base_class( head_bits, array_bits ) {} /// Destructs the set and frees all data - ~MultiLevelHashSet() + ~FeldmanHashSet() {} /// Inserts new element @@ -267,7 +267,7 @@ namespace cds { namespace container { its \p release() member function is called. Example: \code - typedef cds::container::MultiLevelHashSet< cds::urcu::gc< cds::urcu::general_buffered<> >, foo, my_traits > set_type; + typedef cds::container::FeldmanHashSet< cds::urcu::gc< cds::urcu::general_buffered<> >, foo, my_traits > set_type; set_type theSet; // ... @@ -331,7 +331,7 @@ namespace cds { namespace container { Usage: \code - typedef cds::container::MultiLevelHashSet< your_template_params > my_set; + typedef cds::container::FeldmanHashSet< your_template_params > my_set; my_set theSet; // ... { @@ -398,7 +398,7 @@ namespace cds { namespace container { public: ///@name Thread-safe iterators - /** @anchor cds_container_MultilevelHashSet_rcu_iterators + /** @anchor cds_container_FeldmanHashSet_rcu_iterators The set supports thread-safe iterators: you may iterate over the set in multi-threaded environment under explicit RCU lock. RCU lock requirement means that inserting or searching is allowed but you must not erase the items from the set @@ -412,7 +412,7 @@ namespace cds { namespace container { // ... other fields uint32_t payload; // only for example }; - struct set_traits: cds::container::multilevel_hashset::traits + struct set_traits: cds::container::feldman_hashset::traits { struct hash_accessor { uint32_t operator()( foo const& src ) const @@ -423,7 +423,7 @@ namespace cds { namespace container { }; typedef cds::urcu::gc< cds::urcu::general_buffered<>> rcu; - typedef cds::container::MultiLevelHashSet< rcu, foo, set_traits > set_type; + typedef cds::container::FeldmanHashSet< rcu, foo, set_traits > set_type; set_type s; @@ -547,4 +547,4 @@ namespace cds { namespace container { }} // namespace cds::container -#endif // #ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHSET_RCU_H +#endif // #ifndef CDSLIB_CONTAINER_FELDMAN_HASHSET_RCU_H diff --git a/cds/container/impl/multilevel_hashmap.h b/cds/container/impl/feldman_hashmap.h similarity index 91% rename from cds/container/impl/multilevel_hashmap.h rename to cds/container/impl/feldman_hashmap.h index 50a9d66f..7fd1c141 100644 --- a/cds/container/impl/multilevel_hashmap.h +++ b/cds/container/impl/feldman_hashmap.h @@ -1,17 +1,17 @@ //$$CDS-header$$ -#ifndef CDSLIB_CONTAINER_IMPL_MULTILEVEL_HASHMAP_H -#define CDSLIB_CONTAINER_IMPL_MULTILEVEL_HASHMAP_H +#ifndef CDSLIB_CONTAINER_IMPL_FELDMAN_HASHMAP_H +#define CDSLIB_CONTAINER_IMPL_FELDMAN_HASHMAP_H -#include -#include +#include +#include #include namespace cds { namespace container { /// Hash map based on multi-level array /** @ingroup cds_nonintrusive_map - @anchor cds_container_MultilevelHashMap_hp + @anchor cds_container_FeldmanHashMap_hp Source: - [2013] Steven Feldman, Pierre LaBorde, Damian Dechev "Concurrent Multi-level Arrays: @@ -21,7 +21,7 @@ namespace cds { namespace container { a global resize, the process of redistributing the elements in a hash map that occurs when adding new buckets. The negative impact of blocking synchronization is multiplied during a global resize, because all threads will be forced to wait on the thread that is performing the involved process of resizing the hash map - and redistributing the elements. \p %MultilevelHashSet implementation avoids global resizes through new array + and redistributing the elements. \p %FeldmanHashSet implementation avoids global resizes through new array allocation. By allowing concurrent expansion this structure is free from the overhead of an explicit resize, which facilitates concurrent operations. @@ -33,8 +33,8 @@ namespace cds { namespace container { We know that if we expand the hash map a fixed number of times there can be no collision as duplicate keys are not provided for in the standard semantics of a hash map. - \p %MultiLevelHashMap is a multi-level array which has an internal structure similar to a tree: - @image html multilevel_hashset.png + \p %FeldmanHashMap is a multi-level array which has an internal structure similar to a tree: + @image html feldman_hashset.png The multi-level array differs from a tree in that each position on the tree could hold an array of nodes or a single node. A position that holds a single node is a \p dataNode which holds the hash value of a key and the value that is associated with that key; it is a simple struct holding two variables. A \p dataNode in the multi-level array could be marked. @@ -44,7 +44,7 @@ namespace cds { namespace container { an array of nodes. The pointer to an \p arrayNode is differentiated from that of a pointer to a \p dataNode by a bitmark on the second-least significant bit. - \p %MultiLevelHashMap multi-level array is similar to a tree in that we keep a pointer to the root, which is a memory array + \p %FeldmanHashMap multi-level array is similar to a tree in that we keep a pointer to the root, which is a memory array called \p head. The length of the \p head memory array is unique, whereas every other \p arrayNode has a uniform length; a normal \p arrayNode has a fixed power-of-two length equal to the binary logarithm of a variable called \p arrayLength. The maximum depth of the tree, \p maxDepth, is the maximum number of pointers that must be followed to reach any node. @@ -54,31 +54,31 @@ namespace cds { namespace container { That approach to the structure of the hash map uses an extensible hashing scheme; the hash value is treated as a bit string and rehash incrementally. - @note Two important things you should keep in mind when you're using \p %MultiLevelHashMap: + @note Two important things you should keep in mind when you're using \p %FeldmanHashMap: - all keys is converted to fixed-size bit-string by hash functor provided. - You can use variable-length keys, for example, \p std::string as a key for \p %MultiLevelHashMap, + You can use variable-length keys, for example, \p std::string as a key for \p %FeldmanHashMap, but real key in the map will be fixed-size hash values of your keys. For the strings you may use well-known hashing algorithms like SHA1, SHA2, MurmurHash, CityHash or its successor FarmHash and so on, which - converts variable-length strings to fixed-length bit-strings, and such hash values will be the keys in \p %MultiLevelHashMap. - If your key is fixed-sized the hash functor is optional, see \p multilevel_hashmap::traits::hash for explanation and examples. - - \p %MultiLevelHashMap uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, - have identical hash then you cannot insert both that keys in the map. \p %MultiLevelHashMap does not maintain the key, + converts variable-length strings to fixed-length bit-strings, and such hash values will be the keys in \p %FeldmanHashMap. + If your key is fixed-sized the hash functor is optional, see \p feldman_hashmap::traits::hash for explanation and examples. + - \p %FeldmanHashMap uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, + have identical hash then you cannot insert both that keys in the map. \p %FeldmanHashMap does not maintain the key, it maintains its fixed-size hash value. - The map supports @ref cds_container_MultilevelHashMap_iterators "bidirectional thread-safe iterators". + The map supports @ref cds_container_FeldmanHashMap_iterators "bidirectional thread-safe iterators". Template parameters: - \p GC - safe memory reclamation schema. Can be \p gc::HP, \p gc::DHP or one of \ref cds_urcu_type "RCU type" - \p Key - a key type to be stored in the map - \p T - a value type to be stored in the map - - \p Traits - type traits, the structure based on \p multilevel_hashmap::traits or result of \p multilevel_hashmap::make_traits metafunction. + - \p Traits - type traits, the structure based on \p feldman_hashmap::traits or result of \p feldman_hashmap::make_traits metafunction. - There are several specializations of \p %MultiLevelHashMap for each \p GC. You should include: - - for \p gc::HP garbage collector - - for \p gc::DHP garbage collector - - for \ref cds_intrusive_MultiLevelHashMap_rcu "RCU type". RCU specialization + There are several specializations of \p %FeldmanHashMap for each \p GC. You should include: + - for \p gc::HP garbage collector + - for \p gc::DHP garbage collector + - for \ref cds_intrusive_FeldmanHashMap_rcu "RCU type". RCU specialization has a slightly different interface. */ template < @@ -86,20 +86,20 @@ namespace cds { namespace container { ,typename Key ,typename T #ifdef CDS_DOXYGEN_INVOKED - ,class Traits = multilevel_hashmap::traits + ,class Traits = feldman_hashmap::traits #else ,class Traits #endif > - class MultiLevelHashMap + class FeldmanHashMap #ifdef CDS_DOXYGEN_INVOKED - : protected cds::intrusive::MultiLevelHashSet< GC, std::pair, Traits > + : protected cds::intrusive::FeldmanHashSet< GC, std::pair, Traits > #else - : protected cds::container::details::make_multilevel_hashmap< GC, Key, T, Traits >::type + : protected cds::container::details::make_feldman_hashmap< GC, Key, T, Traits >::type #endif { //@cond - typedef cds::container::details::make_multilevel_hashmap< GC, Key, T, Traits > maker; + typedef cds::container::details::make_feldman_hashmap< GC, Key, T, Traits > maker; typedef typename maker::type base_class; //@endcond public: @@ -109,7 +109,7 @@ namespace cds { namespace container { typedef std::pair< key_type const, mapped_type> value_type; ///< Key-value pair to be stored in the map typedef Traits traits; ///< Map traits #ifdef CDS_DOXYGEN_INVOKED - typedef typename traits::hash hasher; ///< Hash functor, see \p multilevel_hashmap::traits::hash + typedef typename traits::hash hasher; ///< Hash functor, see \p feldman_hashmap::traits::hash #else typedef typename maker::hasher hasher; #endif @@ -136,7 +136,7 @@ namespace cds { namespace container { template class bidirectional_iterator: public base_class::iterator_base { - friend class MultiLevelHashMap; + friend class FeldmanHashMap; typedef typename base_class::iterator_base iterator_base; protected: @@ -216,7 +216,7 @@ namespace cds { namespace container { template class reverse_bidirectional_iterator : public base_class::iterator_base { - friend class MultiLevelHashMap; + friend class FeldmanHashMap; typedef typename base_class::iterator_base iterator_base; public: @@ -303,10 +303,10 @@ namespace cds { namespace container { #endif #ifdef CDS_DOXYGEN_INVOKED - typedef implementation_defined iterator; ///< @ref cds_container_MultilevelHashMap_iterators "bidirectional iterator" type - typedef implementation_defined const_iterator; ///< @ref cds_container_MultilevelHashMap_iterators "bidirectional const iterator" type - typedef implementation_defined reverse_iterator; ///< @ref cds_container_MultilevelHashMap_iterators "bidirectional reverse iterator" type - typedef implementation_defined const_reverse_iterator; ///< @ref cds_container_MultilevelHashMap_iterators "bidirectional reverse const iterator" type + typedef implementation_defined iterator; ///< @ref cds_container_FeldmanHashMap_iterators "bidirectional iterator" type + typedef implementation_defined const_iterator; ///< @ref cds_container_FeldmanHashMap_iterators "bidirectional const iterator" type + typedef implementation_defined reverse_iterator; ///< @ref cds_container_FeldmanHashMap_iterators "bidirectional reverse iterator" type + typedef implementation_defined const_reverse_iterator; ///< @ref cds_container_FeldmanHashMap_iterators "bidirectional reverse const iterator" type #else typedef bidirectional_iterator iterator; typedef bidirectional_iterator const_iterator; @@ -331,12 +331,12 @@ namespace cds { namespace container { \endcode where \p N is multi-level array depth. */ - MultiLevelHashMap( size_t head_bits = 8, size_t array_bits = 4 ) + FeldmanHashMap( size_t head_bits = 8, size_t array_bits = 4 ) : base_class( head_bits, array_bits ) {} /// Destructs the map and frees all data - ~MultiLevelHashMap() + ~FeldmanHashMap() {} /// Inserts new element with key and default value @@ -537,7 +537,7 @@ namespace cds { namespace container { Usage: \code - typedef cds::container::MultiLevelHashMap< cds::gc::HP, int, foo, my_traits > map_type; + typedef cds::container::FeldmanHashMap< cds::gc::HP, int, foo, my_traits > map_type; map_type theMap; // ... { @@ -610,7 +610,7 @@ namespace cds { namespace container { Usage: \code - typedef cds::container::MultiLevelHashMap< cds::gc::HP, int, foo, my_traits > map_type; + typedef cds::container::FeldmanHashMap< cds::gc::HP, int, foo, my_traits > map_type; map_type theMap; // ... { @@ -681,7 +681,7 @@ namespace cds { namespace container { public: ///@name Thread-safe iterators - /** @anchor cds_container_MultilevelHashMap_iterators + /** @anchor cds_container_FeldmanHashMap_iterators The map supports thread-safe iterators: you may iterate over the map in multi-threaded environment. It is guaranteed that the iterators will remain valid even if another thread deletes the node the iterator points to: Hazard Pointer embedded into the iterator object protects the node from physical reclamation. @@ -800,4 +800,4 @@ namespace cds { namespace container { }} // namespace cds::container -#endif // #ifndef CDSLIB_CONTAINER_IMPL_MULTILEVEL_HASHMAP_H +#endif // #ifndef CDSLIB_CONTAINER_IMPL_FELDMAN_HASHMAP_H diff --git a/cds/container/impl/multilevel_hashset.h b/cds/container/impl/feldman_hashset.h similarity index 88% rename from cds/container/impl/multilevel_hashset.h rename to cds/container/impl/feldman_hashset.h index 9d3341ba..4e05f39c 100644 --- a/cds/container/impl/multilevel_hashset.h +++ b/cds/container/impl/feldman_hashset.h @@ -1,16 +1,16 @@ //$$CDS-header$$ -#ifndef CDSLIB_CONTAINER_IMPL_MULTILEVEL_HASHSET_H -#define CDSLIB_CONTAINER_IMPL_MULTILEVEL_HASHSET_H +#ifndef CDSLIB_CONTAINER_IMPL_FELDMAN_HASHSET_H +#define CDSLIB_CONTAINER_IMPL_FELDMAN_HASHSET_H -#include -#include +#include +#include namespace cds { namespace container { /// Hash set based on multi-level array /** @ingroup cds_nonintrusive_set - @anchor cds_container_MultilevelHashSet_hp + @anchor cds_container_FeldmanHashSet_hp Source: - [2013] Steven Feldman, Pierre LaBorde, Damian Dechev "Concurrent Multi-level Arrays: @@ -20,7 +20,7 @@ namespace cds { namespace container { a global resize, the process of redistributing the elements in a hash map that occurs when adding new buckets. The negative impact of blocking synchronization is multiplied during a global resize, because all threads will be forced to wait on the thread that is performing the involved process of resizing the hash map - and redistributing the elements. \p %MultilevelHashSet implementation avoids global resizes through new array + and redistributing the elements. \p %FeldmanHashSet implementation avoids global resizes through new array allocation. By allowing concurrent expansion this structure is free from the overhead of an explicit resize, which facilitates concurrent operations. @@ -32,8 +32,8 @@ namespace cds { namespace container { We know that if we expand the hash map a fixed number of times there can be no collision as duplicate keys are not provided for in the standard semantics of a hash map. - \p %MultiLevelHashSet is a multi-level array which has an internal structure similar to a tree: - @image html multilevel_hashset.png + \p %FeldmanHashSet is a multi-level array which has an internal structure similar to a tree: + @image html feldman_hashset.png The multi-level array differs from a tree in that each position on the tree could hold an array of nodes or a single node. A position that holds a single node is a \p dataNode which holds the hash value of a key and the value that is associated with that key; it is a simple struct holding two variables. A \p dataNode in the multi-level array could be marked. @@ -43,7 +43,7 @@ namespace cds { namespace container { an array of nodes. The pointer to an \p arrayNode is differentiated from that of a pointer to a \p dataNode by a bitmark on the second-least significant bit. - \p %MultiLevelHashSet multi-level array is similar to a tree in that we keep a pointer to the root, which is a memory array + \p %FeldmanHashSet multi-level array is similar to a tree in that we keep a pointer to the root, which is a memory array called \p head. The length of the \p head memory array is unique, whereas every other \p arrayNode has a uniform length; a normal \p arrayNode has a fixed power-of-two length equal to the binary logarithm of a variable called \p arrayLength. The maximum depth of the tree, \p maxDepth, is the maximum number of pointers that must be followed to reach any node. @@ -53,56 +53,56 @@ namespace cds { namespace container { That approach to the structure of the hash set uses an extensible hashing scheme; the hash value is treated as a bit string and rehash incrementally. - @note Two important things you should keep in mind when you're using \p %MultiLevelHashSet: - - all keys must be fixed-size. It means that you cannot use \p std::string as a key for \p %MultiLevelHashSet. + @note Two important things you should keep in mind when you're using \p %FeldmanHashSet: + - all keys must be fixed-size. It means that you cannot use \p std::string as a key for \p %FeldmanHashSet. Instead, for the strings you should use well-known hashing algorithms like SHA1, SHA2, MurmurHash, CityHash or its successor FarmHash and so on, which - converts variable-length strings to fixed-length bit-strings, and use that hash as a key in \p %MultiLevelHashSet. - - \p %MultiLevelHashSet uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, - have identical hash then you cannot insert both that keys in the set. \p %MultiLevelHashSet does not maintain the key, + converts variable-length strings to fixed-length bit-strings, and use that hash as a key in \p %FeldmanHashSet. + - \p %FeldmanHashSet uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, + have identical hash then you cannot insert both that keys in the set. \p %FeldmanHashSet does not maintain the key, it maintains its fixed-size hash value. - The set supports @ref cds_container_MultilevelHashSet_iterators "bidirectional thread-safe iterators". + The set supports @ref cds_container_FeldmanHashSet_iterators "bidirectional thread-safe iterators". Template parameters: - \p GC - safe memory reclamation schema. Can be \p gc::HP, \p gc::DHP or one of \ref cds_urcu_type "RCU type" - \p T - a value type to be stored in the set - - \p Traits - type traits, the structure based on \p multilevel_hashset::traits or result of \p multilevel_hashset::make_traits metafunction. - \p Traits is the mandatory argument because it has one mandatory type - an @ref multilevel_hashset::traits::hash_accessor "accessor" + - \p Traits - type traits, the structure based on \p feldman_hashset::traits or result of \p feldman_hashset::make_traits metafunction. + \p Traits is the mandatory argument because it has one mandatory type - an @ref feldman_hashset::traits::hash_accessor "accessor" to hash value of \p T. The set algorithm does not calculate that hash value. - There are several specializations of \p %MultiLevelHashSet for each \p GC. You should include: - - for \p gc::HP garbage collector - - for \p gc::DHP garbage collector - - for \ref cds_intrusive_MultilevelHashSet_rcu "RCU type". RCU specialization + There are several specializations of \p %FeldmanHashSet for each \p GC. You should include: + - for \p gc::HP garbage collector + - for \p gc::DHP garbage collector + - for \ref cds_intrusive_FeldmanHashSet_rcu "RCU type". RCU specialization has a slightly different interface. */ template < class GC , typename T #ifdef CDS_DOXYGEN_INVOKED - , class Traits = multilevel_hashset::traits + , class Traits = feldman_hashset::traits #else , class Traits #endif > - class MultiLevelHashSet + class FeldmanHashSet #ifdef CDS_DOXYGEN_INVOKED - : protected cds::intrusive::MultiLevelHashSet< GC, T, Traits > + : protected cds::intrusive::FeldmanHashSet< GC, T, Traits > #else - : protected cds::container::details::make_multilevel_hashset< GC, T, Traits >::type + : protected cds::container::details::make_feldman_hashset< GC, T, Traits >::type #endif { //@cond - typedef cds::container::details::make_multilevel_hashset< GC, T, Traits > maker; + typedef cds::container::details::make_feldman_hashset< GC, T, Traits > maker; typedef typename maker::type base_class; //@endcond public: typedef GC gc; ///< Garbage collector typedef T value_type; ///< type of value stored in the set - typedef Traits traits; ///< Traits template parameter, see \p multilevel_hashset::traits + typedef Traits traits; ///< Traits template parameter, see \p feldman_hashset::traits typedef typename base_class::hash_accessor hash_accessor; ///< Hash accessor functor typedef typename base_class::hash_type hash_type; ///< Hash type deduced from \p hash_accessor return type @@ -120,10 +120,10 @@ namespace cds { namespace container { /// Count of hazard pointers required static CDS_CONSTEXPR size_t const c_nHazardPtrCount = base_class::c_nHazardPtrCount; - typedef typename base_class::iterator iterator; ///< @ref cds_container_MultilevelHashSet_iterators "bidirectional iterator" type - typedef typename base_class::const_iterator const_iterator; ///< @ref cds_container_MultilevelHashSet_iterators "bidirectional const iterator" type - typedef typename base_class::reverse_iterator reverse_iterator; ///< @ref cds_container_MultilevelHashSet_iterators "bidirectional reverse iterator" type - typedef typename base_class::const_reverse_iterator const_reverse_iterator; ///< @ref cds_container_MultilevelHashSet_iterators "bidirectional reverse const iterator" type + typedef typename base_class::iterator iterator; ///< @ref cds_container_FeldmanHashSet_iterators "bidirectional iterator" type + typedef typename base_class::const_iterator const_iterator; ///< @ref cds_container_FeldmanHashSet_iterators "bidirectional const iterator" type + typedef typename base_class::reverse_iterator reverse_iterator; ///< @ref cds_container_FeldmanHashSet_iterators "bidirectional reverse iterator" type + typedef typename base_class::const_reverse_iterator const_reverse_iterator; ///< @ref cds_container_FeldmanHashSet_iterators "bidirectional reverse const iterator" type protected: //@cond @@ -143,12 +143,12 @@ namespace cds { namespace container { \endcode where \p N is multi-level array depth. */ - MultiLevelHashSet( size_t head_bits = 8, size_t array_bits = 4 ) + FeldmanHashSet( size_t head_bits = 8, size_t array_bits = 4 ) : base_class( head_bits, array_bits ) {} /// Destructs the set and frees all data - ~MultiLevelHashSet() + ~FeldmanHashSet() {} /// Inserts new element @@ -312,7 +312,7 @@ namespace cds { namespace container { Usage: \code - typedef cds::container::MultiLevelHashSet< your_template_args > my_set; + typedef cds::container::FeldmanHashSet< your_template_args > my_set; my_set theSet; // ... { @@ -374,7 +374,7 @@ namespace cds { namespace container { Usage: \code - typedef cds::container::MultiLevelHashSet< your_template_params > my_set; + typedef cds::container::FeldmanHashSet< your_template_params > my_set; my_set theSet; // ... { @@ -439,7 +439,7 @@ namespace cds { namespace container { public: ///@name Thread-safe iterators - /** @anchor cds_container_MultilevelHashSet_iterators + /** @anchor cds_container_FeldmanHashSet_iterators The set supports thread-safe iterators: you may iterate over the set in multi-threaded environment. It is guaranteed that the iterators will remain valid even if another thread deletes the node the iterator points to: Hazard Pointer embedded into the iterator object protects the node from physical reclamation. @@ -559,4 +559,4 @@ namespace cds { namespace container { }} // namespace cds::container -#endif // #ifndef CDSLIB_CONTAINER_IMPL_MULTILEVEL_HASHSET_H +#endif // #ifndef CDSLIB_CONTAINER_IMPL_FELDMAN_HASHSET_H diff --git a/cds/container/multilevel_hashmap_dhp.h b/cds/container/multilevel_hashmap_dhp.h deleted file mode 100644 index 1f898b59..00000000 --- a/cds/container/multilevel_hashmap_dhp.h +++ /dev/null @@ -1,9 +0,0 @@ -//$$CDS-header$$ - -#ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHMAP_DHP_H -#define CDSLIB_CONTAINER_MULTILEVEL_HASHMAP_DHP_H - -#include -#include - -#endif // #ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHMAP_DHP_H diff --git a/cds/container/multilevel_hashmap_hp.h b/cds/container/multilevel_hashmap_hp.h deleted file mode 100644 index f38c6267..00000000 --- a/cds/container/multilevel_hashmap_hp.h +++ /dev/null @@ -1,9 +0,0 @@ -//$$CDS-header$$ - -#ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHMAP_HP_H -#define CDSLIB_CONTAINER_MULTILEVEL_HASHMAP_HP_H - -#include -#include - -#endif // #ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHMAP_HP_H diff --git a/cds/container/multilevel_hashset_dhp.h b/cds/container/multilevel_hashset_dhp.h deleted file mode 100644 index 66b62b85..00000000 --- a/cds/container/multilevel_hashset_dhp.h +++ /dev/null @@ -1,9 +0,0 @@ -//$$CDS-header$$ - -#ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHSET_DHP_H -#define CDSLIB_CONTAINER_MULTILEVEL_HASHSET_DHP_H - -#include -#include - -#endif // #ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHSET_DHP_H diff --git a/cds/container/multilevel_hashset_hp.h b/cds/container/multilevel_hashset_hp.h deleted file mode 100644 index 34dd032c..00000000 --- a/cds/container/multilevel_hashset_hp.h +++ /dev/null @@ -1,9 +0,0 @@ -//$$CDS-header$$ - -#ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHSET_HP_H -#define CDSLIB_CONTAINER_MULTILEVEL_HASHSET_HP_H - -#include -#include - -#endif // #ifndef CDSLIB_CONTAINER_MULTILEVEL_HASHSET_HP_H diff --git a/cds/intrusive/details/multilevel_hashset_base.h b/cds/intrusive/details/feldman_hashset_base.h similarity index 90% rename from cds/intrusive/details/multilevel_hashset_base.h rename to cds/intrusive/details/feldman_hashset_base.h index 1327a0a2..cb37cc29 100644 --- a/cds/intrusive/details/multilevel_hashset_base.h +++ b/cds/intrusive/details/feldman_hashset_base.h @@ -1,7 +1,7 @@ //$$CDS-header$$ -#ifndef CDSLIB_INTRUSIVE_DETAILS_MULTILEVEL_HASHSET_BASE_H -#define CDSLIB_INTRUSIVE_DETAILS_MULTILEVEL_HASHSET_BASE_H +#ifndef CDSLIB_INTRUSIVE_DETAILS_FELDMAN_HASHSET_BASE_H +#define CDSLIB_INTRUSIVE_DETAILS_FELDMAN_HASHSET_BASE_H #include // memcmp, memcpy #include @@ -15,10 +15,10 @@ namespace cds { namespace intrusive { - /// MultiLevelHashSet related definitions + /// FeldmanHashSet related definitions /** @ingroup cds_intrusive_helper */ - namespace multilevel_hashset { + namespace feldman_hashset { /// Hash accessor option /** @copydetails traits::hash_accessor @@ -33,7 +33,7 @@ namespace cds { namespace intrusive { //@endcond }; - /// \p MultiLevelHashSet internal statistics + /// \p FeldmanHashSet internal statistics template struct stat { typedef EventCounter event_counter ; ///< Event counter type @@ -82,7 +82,7 @@ namespace cds { namespace intrusive { //@endcond }; - /// \p MultiLevelHashSet empty internal statistics + /// \p FeldmanHashSet empty internal statistics struct empty_stat { //@cond void onInsertSuccess() const {} @@ -107,12 +107,12 @@ namespace cds { namespace intrusive { //@endcond }; - /// \p MultiLevelHashSet traits + /// \p FeldmanHashSet traits struct traits { /// Mandatory functor to get hash value from data node /** - It is most-important feature of \p MultiLevelHashSet. + It is most-important feature of \p FeldmanHashSet. That functor must return a reference to fixed-sized hash value of data node. The return value of that functor specifies the type of hash value. @@ -154,7 +154,7 @@ namespace cds { namespace intrusive { /// Item counter /** - The item counting is an important part of \p MultiLevelHashSet algorithm: + The item counting is an important part of \p FeldmanHashSet algorithm: the \p empty() member function depends on correct item counting. Therefore, \p atomicity::empty_item_counter is not allowed as a type of the option. @@ -181,22 +181,22 @@ namespace cds { namespace intrusive { /// Internal statistics /** - By default, internal statistics is disabled (\p multilevel_hashset::empty_stat). - Use \p multilevel_hashset::stat to enable it. + By default, internal statistics is disabled (\p feldman_hashset::empty_stat). + Use \p feldman_hashset::stat to enable it. */ typedef empty_stat stat; - /// RCU deadlock checking policy (only for \ref cds_intrusive_MultilevelHashSet_rcu "RCU-based MultilevelHashSet") + /// RCU deadlock checking policy (only for \ref cds_intrusive_FeldmanHashSet_rcu "RCU-based FeldmanHashSet") /** List of available policy see \p opt::rcu_check_deadlock */ typedef cds::opt::v::rcu_throw_deadlock rcu_check_deadlock; }; - /// Metafunction converting option list to \p multilevel_hashset::traits + /// Metafunction converting option list to \p feldman_hashset::traits /** Supported \p Options are: - - \p multilevel_hashset::hash_accessor - mandatory option, hash accessor functor. + - \p feldman_hashset::hash_accessor - mandatory option, hash accessor functor. @copydetails traits::hash_accessor - \p opt::node_allocator - array node allocator. @copydetails traits::node_allocator @@ -209,15 +209,15 @@ namespace cds { namespace intrusive { - \p opt::disposer - the functor used for disposing removed data node. Default is \p opt::v::empty_disposer. Due the nature of GC schema the disposer may be called asynchronously. - \p opt::item_counter - the type of item counting feature. - The item counting is an important part of \p MultiLevelHashSet algorithm: + The item counting is an important part of \p FeldmanHashSet algorithm: the \p empty() member function depends on correct item counting. Therefore, \p atomicity::empty_item_counter is not allowed as a type of the option. Default is \p atomicity::item_counter. - \p opt::memory_model - C++ memory ordering model. Can be \p opt::v::relaxed_ordering (relaxed memory model, the default) or \p opt::v::sequential_consistent (sequentially consisnent memory model). - - \p opt::stat - internal statistics. By default, it is disabled (\p multilevel_hashset::empty_stat). - To enable it use \p multilevel_hashset::stat - - \p opt::rcu_check_deadlock - a deadlock checking policy for \ref cds_intrusive_MultilevelHashSet_rcu "RCU-based MultilevelHashSet" + - \p opt::stat - internal statistics. By default, it is disabled (\p feldman_hashset::empty_stat). + To enable it use \p feldman_hashset::stat + - \p opt::rcu_check_deadlock - a deadlock checking policy for \ref cds_intrusive_FeldmanHashSet_rcu "RCU-based FeldmanHashSet" Default is \p opt::v::rcu_throw_deadlock */ template @@ -287,14 +287,14 @@ namespace cds { namespace intrusive { } // namespace details //@endcond - } // namespace multilevel_hashset + } // namespace feldman_hashset //@cond // Forward declaration - template < class GC, typename T, class Traits = multilevel_hashset::traits > - class MultiLevelHashSet; + template < class GC, typename T, class Traits = feldman_hashset::traits > + class FeldmanHashSet; //@endcond }} // namespace cds::intrusive -#endif // #ifndef CDSLIB_INTRUSIVE_DETAILS_MULTILEVEL_HASHSET_BASE_H +#endif // #ifndef CDSLIB_INTRUSIVE_DETAILS_FELDMAN_HASHSET_BASE_H diff --git a/cds/intrusive/feldman_hashset_dhp.h b/cds/intrusive/feldman_hashset_dhp.h new file mode 100644 index 00000000..2564eb07 --- /dev/null +++ b/cds/intrusive/feldman_hashset_dhp.h @@ -0,0 +1,9 @@ +//$$CDS-header$$ + +#ifndef CDSLIB_INTRUSIVE_FELDMAN_HASHSET_DHP_H +#define CDSLIB_INTRUSIVE_FELDMAN_HASHSET_DHP_H + +#include +#include + +#endif // #ifndef CDSLIB_INTRUSIVE_FELDMAN_HASHSET_DHP_H diff --git a/cds/intrusive/feldman_hashset_hp.h b/cds/intrusive/feldman_hashset_hp.h new file mode 100644 index 00000000..9ec8c9b1 --- /dev/null +++ b/cds/intrusive/feldman_hashset_hp.h @@ -0,0 +1,9 @@ +//$$CDS-header$$ + +#ifndef CDSLIB_INTRUSIVE_FELDMAN_HASHSET_HP_H +#define CDSLIB_INTRUSIVE_FELDMAN_HASHSET_HP_H + +#include +#include + +#endif // #ifndef CDSLIB_INTRUSIVE_FELDMAN_HASHSET_HP_H diff --git a/cds/intrusive/multilevel_hashset_rcu.h b/cds/intrusive/feldman_hashset_rcu.h similarity index 94% rename from cds/intrusive/multilevel_hashset_rcu.h rename to cds/intrusive/feldman_hashset_rcu.h index accb6aa6..52e79b2d 100644 --- a/cds/intrusive/multilevel_hashset_rcu.h +++ b/cds/intrusive/feldman_hashset_rcu.h @@ -1,12 +1,12 @@ //$$CDS-header$$ -#ifndef CDSLIB_INTRUSIVE_MULTILEVEL_HASHSET_RCU_H -#define CDSLIB_INTRUSIVE_MULTILEVEL_HASHSET_RCU_H +#ifndef CDSLIB_INTRUSIVE_FELDMAN_HASHSET_RCU_H +#define CDSLIB_INTRUSIVE_FELDMAN_HASHSET_RCU_H #include // std::ref #include // std::iterator_traits -#include +#include #include #include #include @@ -16,47 +16,47 @@ namespace cds { namespace intrusive { /// Intrusive hash set based on multi-level array, \ref cds_urcu_desc "RCU" specialization /** @ingroup cds_intrusive_map - @anchor cds_intrusive_MultilevelHashSet_rcu + @anchor cds_intrusive_FeldmanHashSet_rcu Source: - [2013] Steven Feldman, Pierre LaBorde, Damian Dechev "Concurrent Multi-level Arrays: Wait-free Extensible Hash Maps" - See algorithm short description @ref cds_intrusive_MultilevelHashSet_hp "here" + See algorithm short description @ref cds_intrusive_FeldmanHashSet_hp "here" - @note Two important things you should keep in mind when you're using \p %MultiLevelHashSet: - - all keys must be fixed-size. It means that you cannot use \p std::string as a key for \p %MultiLevelHashSet. + @note Two important things you should keep in mind when you're using \p %FeldmanHashSet: + - all keys must be fixed-size. It means that you cannot use \p std::string as a key for \p %FeldmanHashSet. Instead, for the strings you should use well-known hashing algorithms like SHA1, SHA2, MurmurHash, CityHash or its successor FarmHash and so on, which - converts variable-length strings to fixed-length bit-strings, and use that hash as a key in \p %MultiLevelHashSet. - - \p %MultiLevelHashSet uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, - have identical hash then you cannot insert both that keys in the set. \p %MultiLevelHashSet does not maintain the key, + converts variable-length strings to fixed-length bit-strings, and use that hash as a key in \p %FeldmanHashSet. + - \p %FeldmanHashSet uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, + have identical hash then you cannot insert both that keys in the set. \p %FeldmanHashSet does not maintain the key, it maintains its fixed-size hash value. Template parameters: - \p RCU - one of \ref cds_urcu_gc "RCU type" - \p T - a value type to be stored in the set - - \p Traits - type traits, the structure based on \p multilevel_hashset::traits or result of \p multilevel_hashset::make_traits metafunction. - \p Traits is the mandatory argument because it has one mandatory type - an @ref multilevel_hashset::traits::hash_accessor "accessor" + - \p Traits - type traits, the structure based on \p feldman_hashset::traits or result of \p feldman_hashset::make_traits metafunction. + \p Traits is the mandatory argument because it has one mandatory type - an @ref feldman_hashset::traits::hash_accessor "accessor" to hash value of \p T. The set algorithm does not calculate that hash value. - @note Before including you should include appropriate RCU header file, + @note Before including you should include appropriate RCU header file, see \ref cds_urcu_gc "RCU type" for list of existing RCU class and corresponding header files. - The set supports @ref cds_intrusive_MultilevelHashSet_rcu_iterators "bidirectional thread-safe iterators" + The set supports @ref cds_intrusive_FeldmanHashSet_rcu_iterators "bidirectional thread-safe iterators" with some restrictions. */ template < class RCU, class T, #ifdef CDS_DOXYGEN_INVOKED - class Traits = multilevel_hashset::traits + class Traits = feldman_hashset::traits #else class Traits #endif > - class MultiLevelHashSet< cds::urcu::gc< RCU >, T, Traits > + class FeldmanHashSet< cds::urcu::gc< RCU >, T, Traits > { public: typedef cds::urcu::gc< RCU > gc; ///< RCU garbage collector @@ -83,7 +83,7 @@ namespace cds { namespace intrusive { typedef typename cds::opt::details::make_comparator_from< hash_type, traits, - multilevel_hashset::bitwise_compare< hash_type > + feldman_hashset::bitwise_compare< hash_type > >::type hash_comparator; # endif @@ -126,14 +126,14 @@ namespace cds { namespace intrusive { }; typedef cds::details::Allocator< array_node, node_allocator > cxx_array_node_allocator; - typedef multilevel_hashset::details::hash_splitter< hash_type > hash_splitter; + typedef feldman_hashset::details::hash_splitter< hash_type > hash_splitter; typedef cds::urcu::details::check_deadlock_policy< gc, rcu_check_deadlock> check_deadlock_policy; //@endcond private: //@cond - multilevel_hashset::details::metrics const m_Metrics; ///< Metrics + feldman_hashset::details::metrics const m_Metrics; ///< Metrics array_node * m_Head; ///< Head array item_counter m_ItemCounter; ///< Item counter stat m_Stat; ///< Internal statistics @@ -151,13 +151,13 @@ namespace cds { namespace intrusive { \endcode where \p N is multi-level array depth. */ - MultiLevelHashSet(size_t head_bits = 8, size_t array_bits = 4) - : m_Metrics(multilevel_hashset::details::metrics::make(head_bits, array_bits, sizeof(hash_type))) + FeldmanHashSet(size_t head_bits = 8, size_t array_bits = 4) + : m_Metrics(feldman_hashset::details::metrics::make(head_bits, array_bits, sizeof(hash_type))) , m_Head(alloc_head_node()) {} /// Destructs the set and frees all data - ~MultiLevelHashSet() + ~FeldmanHashSet() { destroy_tree(); free_array_node(m_Head); @@ -381,7 +381,7 @@ namespace cds { namespace intrusive { its \p release() member function is called. Example: \code - typedef cds::intrusive::MultiLevelHashSet< cds::urcu::gc< cds::urcu::general_buffered<> >, foo, my_traits > set_type; + typedef cds::intrusive::FeldmanHashSet< cds::urcu::gc< cds::urcu::general_buffered<> >, foo, my_traits > set_type; set_type theSet; // ... @@ -463,7 +463,7 @@ namespace cds { namespace intrusive { Usage: \code - typedef cds::intrusive::MultiLevelHashSet< your_template_params > my_set; + typedef cds::intrusive::FeldmanHashSet< your_template_params > my_set; my_set theSet; // ... { @@ -535,13 +535,13 @@ namespace cds { namespace intrusive { //@cond class iterator_base { - friend class MultiLevelHashSet; + friend class FeldmanHashSet; protected: array_node * m_pNode; ///< current array node size_t m_idx; ///< current position in m_pNode value_type * m_pValue; ///< current value - MultiLevelHashSet const* m_set; ///< Hash set + FeldmanHashSet const* m_set; ///< Hash set public: iterator_base() CDS_NOEXCEPT @@ -590,14 +590,14 @@ namespace cds { namespace intrusive { } protected: - iterator_base(MultiLevelHashSet const& set, array_node * pNode, size_t idx, bool) + iterator_base(FeldmanHashSet const& set, array_node * pNode, size_t idx, bool) : m_pNode(pNode) , m_idx(idx) , m_pValue(nullptr) , m_set(&set) {} - iterator_base(MultiLevelHashSet const& set, array_node * pNode, size_t idx) + iterator_base(FeldmanHashSet const& set, array_node * pNode, size_t idx) : m_pNode(pNode) , m_idx(idx) , m_pValue(nullptr) @@ -757,7 +757,7 @@ namespace cds { namespace intrusive { template class bidirectional_iterator : protected iterator_base { - friend class MultiLevelHashSet; + friend class FeldmanHashSet; protected: static CDS_CONSTEXPR bool const c_bConstantIterator = IsConst; @@ -817,11 +817,11 @@ namespace cds { namespace intrusive { } protected: - bidirectional_iterator(MultiLevelHashSet& set, array_node * pNode, size_t idx, bool) + bidirectional_iterator(FeldmanHashSet& set, array_node * pNode, size_t idx, bool) : iterator_base(set, pNode, idx, false) {} - bidirectional_iterator(MultiLevelHashSet& set, array_node * pNode, size_t idx) + bidirectional_iterator(FeldmanHashSet& set, array_node * pNode, size_t idx) : iterator_base(set, pNode, idx) {} }; @@ -830,7 +830,7 @@ namespace cds { namespace intrusive { template class reverse_bidirectional_iterator : public iterator_base { - friend class MultiLevelHashSet; + friend class FeldmanHashSet; public: typedef typename std::conditional< IsConst, value_type const*, value_type*>::type value_ptr; ///< Value pointer @@ -888,11 +888,11 @@ namespace cds { namespace intrusive { } private: - reverse_bidirectional_iterator(MultiLevelHashSet& set, array_node * pNode, size_t idx, bool) + reverse_bidirectional_iterator(FeldmanHashSet& set, array_node * pNode, size_t idx, bool) : iterator_base(set, pNode, idx, false) {} - reverse_bidirectional_iterator(MultiLevelHashSet& set, array_node * pNode, size_t idx) + reverse_bidirectional_iterator(FeldmanHashSet& set, array_node * pNode, size_t idx) : iterator_base(set, pNode, idx, false) { iterator_base::backward(); @@ -902,10 +902,10 @@ namespace cds { namespace intrusive { public: #ifdef CDS_DOXYGEN_INVOKED - typedef implementation_defined iterator; ///< @ref cds_intrusive_MultilevelHashSet_rcu_iterators "bidirectional iterator" type - typedef implementation_defined const_iterator; ///< @ref cds_intrusive_MultilevelHashSet_rcu_iterators "bidirectional const iterator" type - typedef implementation_defined reverse_iterator; ///< @ref cds_intrusive_MultilevelHashSet_rcu_iterators "bidirectional reverse iterator" type - typedef implementation_defined const_reverse_iterator; ///< @ref cds_intrusive_MultilevelHashSet_rcu_iterators "bidirectional reverse const iterator" type + typedef implementation_defined iterator; ///< @ref cds_intrusive_FeldmanHashSet_rcu_iterators "bidirectional iterator" type + typedef implementation_defined const_iterator; ///< @ref cds_intrusive_FeldmanHashSet_rcu_iterators "bidirectional const iterator" type + typedef implementation_defined reverse_iterator; ///< @ref cds_intrusive_FeldmanHashSet_rcu_iterators "bidirectional reverse iterator" type + typedef implementation_defined const_reverse_iterator; ///< @ref cds_intrusive_FeldmanHashSet_rcu_iterators "bidirectional reverse const iterator" type #else typedef bidirectional_iterator iterator; typedef bidirectional_iterator const_iterator; @@ -914,7 +914,7 @@ namespace cds { namespace intrusive { #endif ///@name Thread-safe iterators - /** @anchor cds_intrusive_MultilevelHashSet_rcu_iterators + /** @anchor cds_intrusive_FeldmanHashSet_rcu_iterators The set supports thread-safe iterators: you may iterate over the set in multi-threaded environment under explicit RCU lock. RCU lock requirement means that inserting or searching is allowed but you must not erase the items from the set @@ -928,7 +928,7 @@ namespace cds { namespace intrusive { // ... other fields uint32_t payload; // only for example }; - struct set_traits: cds::intrusive::multilevel_hashset::traits + struct set_traits: cds::intrusive::feldman_hashset::traits { struct hash_accessor { uint32_t operator()( foo const& src ) const @@ -939,7 +939,7 @@ namespace cds { namespace intrusive { }; typedef cds::urcu::gc< cds::urcu::general_buffered<>> rcu; - typedef cds::intrusive::MultiLevelHashSet< rcu, foo, set_traits > set_type; + typedef cds::intrusive::FeldmanHashSet< rcu, foo, set_traits > set_type; set_type s; @@ -1413,4 +1413,4 @@ namespace cds { namespace intrusive { }} // namespace cds::intrusive -#endif // #ifndef CDSLIB_INTRUSIVE_MULTILEVEL_HASHSET_RCU_H +#endif // #ifndef CDSLIB_INTRUSIVE_FELDMAN_HASHSET_RCU_H diff --git a/cds/intrusive/impl/multilevel_hashset.h b/cds/intrusive/impl/feldman_hashset.h similarity index 93% rename from cds/intrusive/impl/multilevel_hashset.h rename to cds/intrusive/impl/feldman_hashset.h index edb7941f..fb713bbd 100644 --- a/cds/intrusive/impl/multilevel_hashset.h +++ b/cds/intrusive/impl/feldman_hashset.h @@ -1,18 +1,18 @@ //$$CDS-header$$ -#ifndef CDSLIB_INTRUSIVE_IMPL_MULTILEVEL_HASHSET_H -#define CDSLIB_INTRUSIVE_IMPL_MULTILEVEL_HASHSET_H +#ifndef CDSLIB_INTRUSIVE_IMPL_FELDMAN_HASHSET_H +#define CDSLIB_INTRUSIVE_IMPL_FELDMAN_HASHSET_H #include // std::ref #include // std::iterator_traits -#include +#include #include namespace cds { namespace intrusive { /// Intrusive hash set based on multi-level array /** @ingroup cds_intrusive_map - @anchor cds_intrusive_MultilevelHashSet_hp + @anchor cds_intrusive_FeldmanHashSet_hp Source: - [2013] Steven Feldman, Pierre LaBorde, Damian Dechev "Concurrent Multi-level Arrays: @@ -22,7 +22,7 @@ namespace cds { namespace intrusive { a global resize, the process of redistributing the elements in a hash map that occurs when adding new buckets. The negative impact of blocking synchronization is multiplied during a global resize, because all threads will be forced to wait on the thread that is performing the involved process of resizing the hash map - and redistributing the elements. \p %MultilevelHashSet implementation avoids global resizes through new array + and redistributing the elements. \p %FeldmanHashSet implementation avoids global resizes through new array allocation. By allowing concurrent expansion this structure is free from the overhead of an explicit resize, which facilitates concurrent operations. @@ -34,8 +34,8 @@ namespace cds { namespace intrusive { We know that if we expand the hash map a fixed number of times there can be no collision as duplicate keys are not provided for in the standard semantics of a hash map. - \p %MultiLevelHashSet is a multi-level array which has a structure similar to a tree: - @image html multilevel_hashset.png + \p %FeldmanHashSet is a multi-level array which has a structure similar to a tree: + @image html feldman_hashset.png The multi-level array differs from a tree in that each position on the tree could hold an array of nodes or a single node. A position that holds a single node is a \p dataNode which holds the hash value of a key and the value that is associated with that key; it is a simple struct holding two variables. A \p dataNode in the multi-level array could be marked. @@ -45,7 +45,7 @@ namespace cds { namespace intrusive { an array of nodes. The pointer to an \p arrayNode is differentiated from that of a pointer to a \p dataNode by a bitmark on the second-least significant bit. - \p %MultiLevelHashSet multi-level array is similar to a tree in that we keep a pointer to the root, which is a memory array + \p %FeldmanHashSet multi-level array is similar to a tree in that we keep a pointer to the root, which is a memory array called \p head. The length of the \p head memory array is unique, whereas every other \p arrayNode has a uniform length; a normal \p arrayNode has a fixed power-of-two length equal to the binary logarithm of a variable called \p arrayLength. The maximum depth of the tree, \p maxDepth, is the maximum number of pointers that must be followed to reach any node. @@ -55,46 +55,46 @@ namespace cds { namespace intrusive { That approach to the structure of the hash set uses an extensible hashing scheme; the hash value is treated as a bit string and rehash incrementally. - @note Two important things you should keep in mind when you're using \p %MultiLevelHashSet: - - all keys must be fixed-size. It means that you cannot use \p std::string as a key for \p %MultiLevelHashSet. + @note Two important things you should keep in mind when you're using \p %FeldmanHashSet: + - all keys must be fixed-size. It means that you cannot use \p std::string as a key for \p %FeldmanHashSet. Instead, for the strings you should use well-known hashing algorithms like SHA1, SHA2, MurmurHash, CityHash or its successor FarmHash and so on, which - converts variable-length strings to fixed-length bit-strings, and use that hash as a key in \p %MultiLevelHashSet. - - \p %MultiLevelHashSet uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, - have identical hash then you cannot insert both that keys in the set. \p %MultiLevelHashSet does not maintain the key, + converts variable-length strings to fixed-length bit-strings, and use that hash as a key in \p %FeldmanHashSet. + - \p %FeldmanHashSet uses a perfect hashing. It means that if two different keys, for example, of type \p std::string, + have identical hash then you cannot insert both that keys in the set. \p %FeldmanHashSet does not maintain the key, it maintains its fixed-size hash value. - The set supports @ref cds_intrusive_MultilevelHashSet_iterators "bidirectional thread-safe iterators". + The set supports @ref cds_intrusive_FeldmanHashSet_iterators "bidirectional thread-safe iterators". Template parameters: - \p GC - safe memory reclamation schema. Can be \p gc::HP, \p gc::DHP or one of \ref cds_urcu_type "RCU type" - \p T - a value type to be stored in the set - - \p Traits - type traits, the structure based on \p multilevel_hashset::traits or result of \p multilevel_hashset::make_traits metafunction. - \p Traits is the mandatory argument because it has one mandatory type - an @ref multilevel_hashset::traits::hash_accessor "accessor" + - \p Traits - type traits, the structure based on \p feldman_hashset::traits or result of \p feldman_hashset::make_traits metafunction. + \p Traits is the mandatory argument because it has one mandatory type - an @ref feldman_hashset::traits::hash_accessor "accessor" to hash value of \p T. The set algorithm does not calculate that hash value. - There are several specializations of \p %MultiLevelHashSet for each \p GC. You should include: - - for \p gc::HP garbage collector - - for \p gc::DHP garbage collector - - for \ref cds_intrusive_MultilevelHashSet_rcu "RCU type". RCU specialization + There are several specializations of \p %FeldmanHashSet for each \p GC. You should include: + - for \p gc::HP garbage collector + - for \p gc::DHP garbage collector + - for \ref cds_intrusive_FeldmanHashSet_rcu "RCU type". RCU specialization has a slightly different interface. */ template < class GC ,typename T #ifdef CDS_DOXYGEN_INVOKED - ,typename Traits = multilevel_hashset::traits + ,typename Traits = feldman_hashset::traits #else ,typename Traits #endif > - class MultiLevelHashSet + class FeldmanHashSet { public: typedef GC gc; ///< Garbage collector typedef T value_type; ///< type of value stored in the set - typedef Traits traits; ///< Traits template parameter, see \p multilevel_hashset::traits + typedef Traits traits; ///< Traits template parameter, see \p feldman_hashset::traits typedef typename traits::hash_accessor hash_accessor; ///< Hash accessor functor static_assert(!std::is_same< hash_accessor, cds::opt::none >::value, "hash_accessor functor must be specified" ); @@ -116,7 +116,7 @@ namespace cds { namespace intrusive { typedef typename cds::opt::details::make_comparator_from< hash_type, traits, - multilevel_hashset::bitwise_compare< hash_type > + feldman_hashset::bitwise_compare< hash_type > >::type hash_comparator; # endif @@ -160,20 +160,20 @@ namespace cds { namespace intrusive { typedef cds::details::Allocator< array_node, node_allocator > cxx_array_node_allocator; - typedef multilevel_hashset::details::hash_splitter< hash_type > hash_splitter; + typedef feldman_hashset::details::hash_splitter< hash_type > hash_splitter; //@endcond protected: //@cond class iterator_base { - friend class MultiLevelHashSet; + friend class FeldmanHashSet; protected: array_node * m_pNode; ///< current array node size_t m_idx; ///< current position in m_pNode typename gc::Guard m_guard; ///< HP guard - MultiLevelHashSet const* m_set; ///< Hash set + FeldmanHashSet const* m_set; ///< Hash set public: iterator_base() CDS_NOEXCEPT @@ -227,13 +227,13 @@ namespace cds { namespace intrusive { } protected: - iterator_base( MultiLevelHashSet const& set, array_node * pNode, size_t idx, bool ) + iterator_base( FeldmanHashSet const& set, array_node * pNode, size_t idx, bool ) : m_pNode( pNode ) , m_idx( idx ) , m_set( &set ) {} - iterator_base( MultiLevelHashSet const& set, array_node * pNode, size_t idx ) + iterator_base( FeldmanHashSet const& set, array_node * pNode, size_t idx ) : m_pNode( pNode ) , m_idx( idx ) , m_set( &set ) @@ -389,7 +389,7 @@ namespace cds { namespace intrusive { template class bidirectional_iterator: protected iterator_base { - friend class MultiLevelHashSet; + friend class FeldmanHashSet; protected: static CDS_CONSTEXPR bool const c_bConstantIterator = IsConst; @@ -454,11 +454,11 @@ namespace cds { namespace intrusive { } protected: - bidirectional_iterator( MultiLevelHashSet& set, array_node * pNode, size_t idx, bool ) + bidirectional_iterator( FeldmanHashSet& set, array_node * pNode, size_t idx, bool ) : iterator_base( set, pNode, idx, false ) {} - bidirectional_iterator( MultiLevelHashSet& set, array_node * pNode, size_t idx ) + bidirectional_iterator( FeldmanHashSet& set, array_node * pNode, size_t idx ) : iterator_base( set, pNode, idx ) {} }; @@ -467,7 +467,7 @@ namespace cds { namespace intrusive { template class reverse_bidirectional_iterator : public iterator_base { - friend class MultiLevelHashSet; + friend class FeldmanHashSet; public: typedef typename std::conditional< IsConst, value_type const*, value_type*>::type value_ptr; ///< Value pointer @@ -530,11 +530,11 @@ namespace cds { namespace intrusive { } private: - reverse_bidirectional_iterator( MultiLevelHashSet& set, array_node * pNode, size_t idx, bool ) + reverse_bidirectional_iterator( FeldmanHashSet& set, array_node * pNode, size_t idx, bool ) : iterator_base( set, pNode, idx, false ) {} - reverse_bidirectional_iterator( MultiLevelHashSet& set, array_node * pNode, size_t idx ) + reverse_bidirectional_iterator( FeldmanHashSet& set, array_node * pNode, size_t idx ) : iterator_base( set, pNode, idx, false ) { iterator_base::backward(); @@ -544,10 +544,10 @@ namespace cds { namespace intrusive { public: #ifdef CDS_DOXYGEN_INVOKED - typedef implementation_defined iterator; ///< @ref cds_intrusive_MultilevelHashSet_iterators "bidirectional iterator" type - typedef implementation_defined const_iterator; ///< @ref cds_intrusive_MultilevelHashSet_iterators "bidirectional const iterator" type - typedef implementation_defined reverse_iterator; ///< @ref cds_intrusive_MultilevelHashSet_iterators "bidirectional reverse iterator" type - typedef implementation_defined const_reverse_iterator; ///< @ref cds_intrusive_MultilevelHashSet_iterators "bidirectional reverse const iterator" type + typedef implementation_defined iterator; ///< @ref cds_intrusive_FeldmanHashSet_iterators "bidirectional iterator" type + typedef implementation_defined const_iterator; ///< @ref cds_intrusive_FeldmanHashSet_iterators "bidirectional const iterator" type + typedef implementation_defined reverse_iterator; ///< @ref cds_intrusive_FeldmanHashSet_iterators "bidirectional reverse iterator" type + typedef implementation_defined const_reverse_iterator; ///< @ref cds_intrusive_FeldmanHashSet_iterators "bidirectional reverse const iterator" type #else typedef bidirectional_iterator iterator; typedef bidirectional_iterator const_iterator; @@ -557,7 +557,7 @@ namespace cds { namespace intrusive { private: //@cond - multilevel_hashset::details::metrics const m_Metrics; ///< Metrics + feldman_hashset::details::metrics const m_Metrics; ///< Metrics array_node * m_Head; ///< Head array item_counter m_ItemCounter; ///< Item counter stat m_Stat; ///< Internal statistics @@ -575,13 +575,13 @@ namespace cds { namespace intrusive { \endcode where \p N is multi-level array depth. */ - MultiLevelHashSet( size_t head_bits = 8, size_t array_bits = 4 ) - : m_Metrics( multilevel_hashset::details::metrics::make( head_bits, array_bits, sizeof(hash_type))) + FeldmanHashSet( size_t head_bits = 8, size_t array_bits = 4 ) + : m_Metrics( feldman_hashset::details::metrics::make( head_bits, array_bits, sizeof(hash_type))) , m_Head( alloc_head_node()) {} /// Destructs the set and frees all data - ~MultiLevelHashSet() + ~FeldmanHashSet() { destroy_tree(); free_array_node( m_Head ); @@ -796,7 +796,7 @@ namespace cds { namespace intrusive { Usage: \code - typedef cds::intrusive::MultiLevelHashSet< your_template_args > my_set; + typedef cds::intrusive::FeldmanHashSet< your_template_args > my_set; my_set theSet; // ... { @@ -875,7 +875,7 @@ namespace cds { namespace intrusive { Usage: \code - typedef cds::intrusive::MultiLevelHashSet< your_template_params > my_set; + typedef cds::intrusive::FeldmanHashSet< your_template_params > my_set; my_set theSet; // ... { @@ -947,7 +947,7 @@ namespace cds { namespace intrusive { public: ///@name Thread-safe iterators - /** @anchor cds_intrusive_MultilevelHashSet_iterators + /** @anchor cds_intrusive_FeldmanHashSet_iterators The set supports thread-safe iterators: you may iterate over the set in multi-threaded environment. It is guaranteed that the iterators will remain valid even if another thread deletes the node the iterator points to: Hazard Pointer embedded into the iterator object protects the node from physical reclamation. @@ -1436,9 +1436,9 @@ namespace cds { namespace intrusive { namespace std { template - struct iterator_traits< typename cds::intrusive::MultiLevelHashSet< GC, T, Traits >::iterator > + struct iterator_traits< typename cds::intrusive::FeldmanHashSet< GC, T, Traits >::iterator > { - typedef typename cds::intrusive::MultiLevelHashSet< GC, T, Traits >::iterator iterator_class; + typedef typename cds::intrusive::FeldmanHashSet< GC, T, Traits >::iterator iterator_class; // difference_type is not applicable for that iterator // typedef ??? difference_type @@ -1449,9 +1449,9 @@ namespace std { }; template - struct iterator_traits< typename cds::intrusive::MultiLevelHashSet< GC, T, Traits >::const_iterator > + struct iterator_traits< typename cds::intrusive::FeldmanHashSet< GC, T, Traits >::const_iterator > { - typedef typename cds::intrusive::MultiLevelHashSet< GC, T, Traits >::const_iterator iterator_class; + typedef typename cds::intrusive::FeldmanHashSet< GC, T, Traits >::const_iterator iterator_class; // difference_type is not applicable for that iterator // typedef ??? difference_type @@ -1464,4 +1464,4 @@ namespace std { } // namespace std */ -#endif // #ifndef CDSLIB_INTRUSIVE_IMPL_MULTILEVEL_HASHSET_H +#endif // #ifndef CDSLIB_INTRUSIVE_IMPL_FELDMAN_HASHSET_H diff --git a/cds/intrusive/multilevel_hashset_dhp.h b/cds/intrusive/multilevel_hashset_dhp.h deleted file mode 100644 index e0c95112..00000000 --- a/cds/intrusive/multilevel_hashset_dhp.h +++ /dev/null @@ -1,9 +0,0 @@ -//$$CDS-header$$ - -#ifndef CDSLIB_INTRUSIVE_MULTILEVEL_HASHSET_DHP_H -#define CDSLIB_INTRUSIVE_MULTILEVEL_HASHSET_DHP_H - -#include -#include - -#endif // #ifndef CDSLIB_INTRUSIVE_MULTILEVEL_HASHSET_DHP_H diff --git a/cds/intrusive/multilevel_hashset_hp.h b/cds/intrusive/multilevel_hashset_hp.h deleted file mode 100644 index 97dc8a22..00000000 --- a/cds/intrusive/multilevel_hashset_hp.h +++ /dev/null @@ -1,9 +0,0 @@ -//$$CDS-header$$ - -#ifndef CDSLIB_INTRUSIVE_MULTILEVEL_HASHSET_HP_H -#define CDSLIB_INTRUSIVE_MULTILEVEL_HASHSET_HP_H - -#include -#include - -#endif // #ifndef CDSLIB_INTRUSIVE_MULTILEVEL_HASHSET_HP_H diff --git a/projects/Win/vc12/cds.sln b/projects/Win/vc12/cds.sln index 9e737608..ea2f9466 100644 --- a/projects/Win/vc12/cds.sln +++ b/projects/Win/vc12/cds.sln @@ -10,7 +10,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "multi-threaded test", "mult ..\..\..\tests\unit\print_cuckoo_stat.h = ..\..\..\tests\unit\print_cuckoo_stat.h ..\..\..\tests\unit\print_ellenbintree_stat.h = ..\..\..\tests\unit\print_ellenbintree_stat.h ..\..\..\tests\unit\print_mspriorityqueue_stat.h = ..\..\..\tests\unit\print_mspriorityqueue_stat.h - ..\..\..\tests\unit\print_multilevel_hashset_stat.h = ..\..\..\tests\unit\print_multilevel_hashset_stat.h + ..\..\..\tests\unit\print_feldman_hashset_stat.h = ..\..\..\tests\unit\print_feldman_hashset_stat.h ..\..\..\tests\unit\print_segmentedqueue_stat.h = ..\..\..\tests\unit\print_segmentedqueue_stat.h ..\..\..\tests\unit\print_skip_list_stat.h = ..\..\..\tests\unit\print_skip_list_stat.h ..\..\..\tests\unit\print_split_list_stat.h = ..\..\..\tests\unit\print_split_list_stat.h @@ -80,7 +80,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "map", "map", "{6BB7A27F-FC5 ..\..\..\tests\unit\map2\map_type_lazy_list.h = ..\..\..\tests\unit\map2\map_type_lazy_list.h ..\..\..\tests\unit\map2\map_type_michael.h = ..\..\..\tests\unit\map2\map_type_michael.h ..\..\..\tests\unit\map2\map_type_michael_list.h = ..\..\..\tests\unit\map2\map_type_michael_list.h - ..\..\..\tests\unit\map2\map_type_multilevel_hashmap.h = ..\..\..\tests\unit\map2\map_type_multilevel_hashmap.h + ..\..\..\tests\unit\map2\map_type_feldman_hashmap.h = ..\..\..\tests\unit\map2\map_type_feldman_hashmap.h ..\..\..\tests\unit\map2\map_type_skip_list.h = ..\..\..\tests\unit\map2\map_type_skip_list.h ..\..\..\tests\unit\map2\map_type_split_list.h = ..\..\..\tests\unit\map2\map_type_split_list.h ..\..\..\tests\unit\map2\map_type_std.h = ..\..\..\tests\unit\map2\map_type_std.h @@ -98,7 +98,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "set", "set", "{A64449B7-90F ..\..\..\tests\unit\set2\set_type_lazy_list.h = ..\..\..\tests\unit\set2\set_type_lazy_list.h ..\..\..\tests\unit\set2\set_type_michael.h = ..\..\..\tests\unit\set2\set_type_michael.h ..\..\..\tests\unit\set2\set_type_michael_list.h = ..\..\..\tests\unit\set2\set_type_michael_list.h - ..\..\..\tests\unit\set2\set_type_multilevel_hashset.h = ..\..\..\tests\unit\set2\set_type_multilevel_hashset.h + ..\..\..\tests\unit\set2\set_type_feldman_hashset.h = ..\..\..\tests\unit\set2\set_type_feldman_hashset.h ..\..\..\tests\unit\set2\set_type_skip_list.h = ..\..\..\tests\unit\set2\set_type_skip_list.h ..\..\..\tests\unit\set2\set_type_split_list.h = ..\..\..\tests\unit\set2\set_type_split_list.h ..\..\..\tests\unit\set2\set_type_std.h = ..\..\..\tests\unit\set2\set_type_std.h diff --git a/projects/Win/vc12/cds.vcxproj b/projects/Win/vc12/cds.vcxproj index 0ec0c295..f9a9bcdf 100644 --- a/projects/Win/vc12/cds.vcxproj +++ b/projects/Win/vc12/cds.vcxproj @@ -670,8 +670,8 @@ - - + + @@ -687,8 +687,8 @@ - - + + @@ -702,12 +702,12 @@ - - - - - - + + + + + + @@ -761,7 +761,7 @@ - + @@ -773,7 +773,7 @@ - + @@ -781,9 +781,9 @@ - - - + + + diff --git a/projects/Win/vc12/cds.vcxproj.filters b/projects/Win/vc12/cds.vcxproj.filters index 7ecba805..f1b37296 100644 --- a/projects/Win/vc12/cds.vcxproj.filters +++ b/projects/Win/vc12/cds.vcxproj.filters @@ -1178,52 +1178,52 @@ Header Files\cds\intrusive\details - + Header Files\cds\intrusive\impl - + Header Files\cds\intrusive\details - + Header Files\cds\intrusive - + Header Files\cds\intrusive Header Files\cds\algo - + Header Files\cds\container\details - + Header Files\cds\container\impl - + Header Files\cds\container - + Header Files\cds\container - + Header Files\cds\container\details - + Header Files\cds\container\impl - + Header Files\cds\container - + Header Files\cds\container - + Header Files\cds\intrusive - + Header Files\cds\container - + Header Files\cds\container diff --git a/projects/Win/vc12/hdr-test-map.vcxproj b/projects/Win/vc12/hdr-test-map.vcxproj index 674216bc..b8dfdf53 100644 --- a/projects/Win/vc12/hdr-test-map.vcxproj +++ b/projects/Win/vc12/hdr-test-map.vcxproj @@ -546,7 +546,7 @@ - + @@ -567,13 +567,13 @@ - - - - - - - + + + + + + + diff --git a/projects/Win/vc12/hdr-test-map.vcxproj.filters b/projects/Win/vc12/hdr-test-map.vcxproj.filters index a8e47dce..2fe1b481 100644 --- a/projects/Win/vc12/hdr-test-map.vcxproj.filters +++ b/projects/Win/vc12/hdr-test-map.vcxproj.filters @@ -175,25 +175,25 @@ skip_list - + multilvel_hashmap - + multilvel_hashmap - + multilvel_hashmap - + multilvel_hashmap - + multilvel_hashmap - + multilvel_hashmap - + multilvel_hashmap @@ -212,7 +212,7 @@ cuckoo - + multilvel_hashmap diff --git a/projects/Win/vc12/hdr-test-set.vcxproj b/projects/Win/vc12/hdr-test-set.vcxproj index 098bcba1..bc73c2c5 100644 --- a/projects/Win/vc12/hdr-test-set.vcxproj +++ b/projects/Win/vc12/hdr-test-set.vcxproj @@ -541,11 +541,11 @@ - + - + @@ -567,13 +567,13 @@ - - - - - - - + + + + + + + @@ -622,13 +622,13 @@ - - - - - - - + + + + + + + diff --git a/projects/Win/vc12/hdr-test-set.vcxproj.filters b/projects/Win/vc12/hdr-test-set.vcxproj.filters index 0f5788e0..c44ec9d3 100644 --- a/projects/Win/vc12/hdr-test-set.vcxproj.filters +++ b/projects/Win/vc12/hdr-test-set.vcxproj.filters @@ -19,11 +19,11 @@ container\skip_list - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset @@ -51,10 +51,10 @@ {61f94a40-c964-4233-af67-66a1be1e0aab} - + {a878aed0-83c9-4ca7-95bb-74f10aad8bde} - + {5268f225-1474-413e-a1cb-5f00b8df5e1e} @@ -323,47 +323,47 @@ container\skip_list - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset \ No newline at end of file diff --git a/projects/Win/vc12/unit-map-delodd.vcxproj b/projects/Win/vc12/unit-map-delodd.vcxproj index abce74e3..ae311eee 100644 --- a/projects/Win/vc12/unit-map-delodd.vcxproj +++ b/projects/Win/vc12/unit-map-delodd.vcxproj @@ -56,7 +56,7 @@ false - + false diff --git a/projects/Win/vc12/unit-map-find.vcxproj b/projects/Win/vc12/unit-map-find.vcxproj index e8db6c1d..b70d27f0 100644 --- a/projects/Win/vc12/unit-map-find.vcxproj +++ b/projects/Win/vc12/unit-map-find.vcxproj @@ -48,7 +48,7 @@ - + @@ -58,7 +58,7 @@ - + @@ -68,7 +68,7 @@ - + diff --git a/projects/Win/vc12/unit-map-find.vcxproj.filters b/projects/Win/vc12/unit-map-find.vcxproj.filters index 3a6880b2..bb9c849a 100644 --- a/projects/Win/vc12/unit-map-find.vcxproj.filters +++ b/projects/Win/vc12/unit-map-find.vcxproj.filters @@ -82,13 +82,13 @@ map_insfind_int - + map_find_int - + map_find_string - + map_insfind_int diff --git a/projects/Win/vc12/unit-map-insdel-item.vcxproj b/projects/Win/vc12/unit-map-insdel-item.vcxproj index cdcd25db..764bca0a 100644 --- a/projects/Win/vc12/unit-map-insdel-item.vcxproj +++ b/projects/Win/vc12/unit-map-insdel-item.vcxproj @@ -48,7 +48,7 @@ - + @@ -57,7 +57,7 @@ - + diff --git a/projects/Win/vc12/unit-map-insdel-item.vcxproj.filters b/projects/Win/vc12/unit-map-insdel-item.vcxproj.filters index 5aa2b21b..8c0b268a 100644 --- a/projects/Win/vc12/unit-map-insdel-item.vcxproj.filters +++ b/projects/Win/vc12/unit-map-insdel-item.vcxproj.filters @@ -57,10 +57,10 @@ map_insdel_item_string - + map_insdel_item_int - + map_insdel_item_string diff --git a/projects/Win/vc12/unit-map-insdel.vcxproj b/projects/Win/vc12/unit-map-insdel.vcxproj index 11d74752..d3f17705 100644 --- a/projects/Win/vc12/unit-map-insdel.vcxproj +++ b/projects/Win/vc12/unit-map-insdel.vcxproj @@ -48,7 +48,7 @@ - + @@ -57,7 +57,7 @@ - + @@ -67,7 +67,7 @@ - + diff --git a/projects/Win/vc12/unit-map-insdel.vcxproj.filters b/projects/Win/vc12/unit-map-insdel.vcxproj.filters index 0818ac7a..ef09d099 100644 --- a/projects/Win/vc12/unit-map-insdel.vcxproj.filters +++ b/projects/Win/vc12/unit-map-insdel.vcxproj.filters @@ -76,16 +76,16 @@ map_insdel_string - + map_insdel_int map_insdel_int - + map_insdel_func - + map_insdel_string diff --git a/projects/Win/vc12/unit-map-insdelfind.vcxproj b/projects/Win/vc12/unit-map-insdelfind.vcxproj index 37503239..aa969fd1 100644 --- a/projects/Win/vc12/unit-map-insdelfind.vcxproj +++ b/projects/Win/vc12/unit-map-insdelfind.vcxproj @@ -48,7 +48,7 @@ - + diff --git a/projects/Win/vc12/unit-set-delodd.vcxproj b/projects/Win/vc12/unit-set-delodd.vcxproj index 50f87cdd..f412302e 100644 --- a/projects/Win/vc12/unit-set-delodd.vcxproj +++ b/projects/Win/vc12/unit-set-delodd.vcxproj @@ -47,7 +47,7 @@ - + diff --git a/projects/Win/vc12/unit-set-insdel.vcxproj b/projects/Win/vc12/unit-set-insdel.vcxproj index 8e0830af..b40874b9 100644 --- a/projects/Win/vc12/unit-set-insdel.vcxproj +++ b/projects/Win/vc12/unit-set-insdel.vcxproj @@ -47,7 +47,7 @@ - + @@ -55,7 +55,7 @@ - + diff --git a/projects/Win/vc12/unit-set-insdel.vcxproj.filters b/projects/Win/vc12/unit-set-insdel.vcxproj.filters index 74851368..643f5857 100644 --- a/projects/Win/vc12/unit-set-insdel.vcxproj.filters +++ b/projects/Win/vc12/unit-set-insdel.vcxproj.filters @@ -46,10 +46,10 @@ set_insdel_func - + set_insdel_func - + set_insdel_string diff --git a/projects/Win/vc12/unit-set-insdelfind.vcxproj b/projects/Win/vc12/unit-set-insdelfind.vcxproj index 1bcaba07..b6a50a1e 100644 --- a/projects/Win/vc12/unit-set-insdelfind.vcxproj +++ b/projects/Win/vc12/unit-set-insdelfind.vcxproj @@ -47,7 +47,7 @@ - + diff --git a/projects/Win/vc14/cds.sln b/projects/Win/vc14/cds.sln index 4654ba12..7300001d 100644 --- a/projects/Win/vc14/cds.sln +++ b/projects/Win/vc14/cds.sln @@ -10,7 +10,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "multi-threaded test", "mult ..\..\..\tests\unit\print_cuckoo_stat.h = ..\..\..\tests\unit\print_cuckoo_stat.h ..\..\..\tests\unit\print_ellenbintree_stat.h = ..\..\..\tests\unit\print_ellenbintree_stat.h ..\..\..\tests\unit\print_mspriorityqueue_stat.h = ..\..\..\tests\unit\print_mspriorityqueue_stat.h - ..\..\..\tests\unit\print_multilevel_hashset_stat.h = ..\..\..\tests\unit\print_multilevel_hashset_stat.h + ..\..\..\tests\unit\print_feldman_hashset_stat.h = ..\..\..\tests\unit\print_feldman_hashset_stat.h ..\..\..\tests\unit\print_segmentedqueue_stat.h = ..\..\..\tests\unit\print_segmentedqueue_stat.h ..\..\..\tests\unit\print_skip_list_stat.h = ..\..\..\tests\unit\print_skip_list_stat.h ..\..\..\tests\unit\print_split_list_stat.h = ..\..\..\tests\unit\print_split_list_stat.h @@ -80,7 +80,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "map", "map", "{6BB7A27F-FC5 ..\..\..\tests\unit\map2\map_type_lazy_list.h = ..\..\..\tests\unit\map2\map_type_lazy_list.h ..\..\..\tests\unit\map2\map_type_michael.h = ..\..\..\tests\unit\map2\map_type_michael.h ..\..\..\tests\unit\map2\map_type_michael_list.h = ..\..\..\tests\unit\map2\map_type_michael_list.h - ..\..\..\tests\unit\map2\map_type_multilevel_hashmap.h = ..\..\..\tests\unit\map2\map_type_multilevel_hashmap.h + ..\..\..\tests\unit\map2\map_type_feldman_hashmap.h = ..\..\..\tests\unit\map2\map_type_feldman_hashmap.h ..\..\..\tests\unit\map2\map_type_skip_list.h = ..\..\..\tests\unit\map2\map_type_skip_list.h ..\..\..\tests\unit\map2\map_type_split_list.h = ..\..\..\tests\unit\map2\map_type_split_list.h ..\..\..\tests\unit\map2\map_type_std.h = ..\..\..\tests\unit\map2\map_type_std.h @@ -98,7 +98,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "set", "set", "{A64449B7-90F ..\..\..\tests\unit\set2\set_type_lazy_list.h = ..\..\..\tests\unit\set2\set_type_lazy_list.h ..\..\..\tests\unit\set2\set_type_michael.h = ..\..\..\tests\unit\set2\set_type_michael.h ..\..\..\tests\unit\set2\set_type_michael_list.h = ..\..\..\tests\unit\set2\set_type_michael_list.h - ..\..\..\tests\unit\set2\set_type_multilevel_hashset.h = ..\..\..\tests\unit\set2\set_type_multilevel_hashset.h + ..\..\..\tests\unit\set2\set_type_feldman_hashset.h = ..\..\..\tests\unit\set2\set_type_feldman_hashset.h ..\..\..\tests\unit\set2\set_type_skip_list.h = ..\..\..\tests\unit\set2\set_type_skip_list.h ..\..\..\tests\unit\set2\set_type_split_list.h = ..\..\..\tests\unit\set2\set_type_split_list.h ..\..\..\tests\unit\set2\set_type_std.h = ..\..\..\tests\unit\set2\set_type_std.h diff --git a/projects/Win/vc14/cds.vcxproj b/projects/Win/vc14/cds.vcxproj index 997771d8..e706ec52 100644 --- a/projects/Win/vc14/cds.vcxproj +++ b/projects/Win/vc14/cds.vcxproj @@ -775,8 +775,8 @@ - - + + @@ -792,8 +792,8 @@ - - + + @@ -807,12 +807,12 @@ - - - - - - + + + + + + @@ -866,7 +866,7 @@ - + @@ -878,7 +878,7 @@ - + @@ -886,9 +886,9 @@ - - - + + + diff --git a/projects/Win/vc14/cds.vcxproj.filters b/projects/Win/vc14/cds.vcxproj.filters index 7ecba805..f1b37296 100644 --- a/projects/Win/vc14/cds.vcxproj.filters +++ b/projects/Win/vc14/cds.vcxproj.filters @@ -1178,52 +1178,52 @@ Header Files\cds\intrusive\details - + Header Files\cds\intrusive\impl - + Header Files\cds\intrusive\details - + Header Files\cds\intrusive - + Header Files\cds\intrusive Header Files\cds\algo - + Header Files\cds\container\details - + Header Files\cds\container\impl - + Header Files\cds\container - + Header Files\cds\container - + Header Files\cds\container\details - + Header Files\cds\container\impl - + Header Files\cds\container - + Header Files\cds\container - + Header Files\cds\intrusive - + Header Files\cds\container - + Header Files\cds\container diff --git a/projects/Win/vc14/hdr-test-map.vcxproj b/projects/Win/vc14/hdr-test-map.vcxproj index fc21891d..79b3505c 100644 --- a/projects/Win/vc14/hdr-test-map.vcxproj +++ b/projects/Win/vc14/hdr-test-map.vcxproj @@ -645,7 +645,7 @@ - + @@ -666,13 +666,13 @@ - - - - - - - + + + + + + + diff --git a/projects/Win/vc14/hdr-test-map.vcxproj.filters b/projects/Win/vc14/hdr-test-map.vcxproj.filters index a8e47dce..2fe1b481 100644 --- a/projects/Win/vc14/hdr-test-map.vcxproj.filters +++ b/projects/Win/vc14/hdr-test-map.vcxproj.filters @@ -175,25 +175,25 @@ skip_list - + multilvel_hashmap - + multilvel_hashmap - + multilvel_hashmap - + multilvel_hashmap - + multilvel_hashmap - + multilvel_hashmap - + multilvel_hashmap @@ -212,7 +212,7 @@ cuckoo - + multilvel_hashmap diff --git a/projects/Win/vc14/hdr-test-set.vcxproj b/projects/Win/vc14/hdr-test-set.vcxproj index afce40f9..eb9711cc 100644 --- a/projects/Win/vc14/hdr-test-set.vcxproj +++ b/projects/Win/vc14/hdr-test-set.vcxproj @@ -640,11 +640,11 @@ - + - + @@ -666,13 +666,13 @@ - - - - - - - + + + + + + + @@ -721,13 +721,13 @@ - - - - - - - + + + + + + + diff --git a/projects/Win/vc14/hdr-test-set.vcxproj.filters b/projects/Win/vc14/hdr-test-set.vcxproj.filters index d9522f15..4b6cd72a 100644 --- a/projects/Win/vc14/hdr-test-set.vcxproj.filters +++ b/projects/Win/vc14/hdr-test-set.vcxproj.filters @@ -19,11 +19,11 @@ container\skip_list - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset @@ -51,10 +51,10 @@ {61f94a40-c964-4233-af67-66a1be1e0aab} - + {a878aed0-83c9-4ca7-95bb-74f10aad8bde} - + {5268f225-1474-413e-a1cb-5f00b8df5e1e} @@ -323,47 +323,47 @@ container\skip_list - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - intrusive\multilevel_hashset + + intrusive\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset - - container\multilevel_hashset + + container\feldman_hashset \ No newline at end of file diff --git a/projects/Win/vc14/unit-map-delodd.vcxproj b/projects/Win/vc14/unit-map-delodd.vcxproj index 0f2ebc7b..b62b1ec1 100644 --- a/projects/Win/vc14/unit-map-delodd.vcxproj +++ b/projects/Win/vc14/unit-map-delodd.vcxproj @@ -64,7 +64,7 @@ false - + false diff --git a/projects/Win/vc14/unit-map-find.vcxproj b/projects/Win/vc14/unit-map-find.vcxproj index a2353126..ee8b9183 100644 --- a/projects/Win/vc14/unit-map-find.vcxproj +++ b/projects/Win/vc14/unit-map-find.vcxproj @@ -56,7 +56,7 @@ - + @@ -66,7 +66,7 @@ - + @@ -76,7 +76,7 @@ - + diff --git a/projects/Win/vc14/unit-map-find.vcxproj.filters b/projects/Win/vc14/unit-map-find.vcxproj.filters index 3a6880b2..bb9c849a 100644 --- a/projects/Win/vc14/unit-map-find.vcxproj.filters +++ b/projects/Win/vc14/unit-map-find.vcxproj.filters @@ -82,13 +82,13 @@ map_insfind_int - + map_find_int - + map_find_string - + map_insfind_int diff --git a/projects/Win/vc14/unit-map-insdel-item.vcxproj b/projects/Win/vc14/unit-map-insdel-item.vcxproj index c86e7c44..7bab5385 100644 --- a/projects/Win/vc14/unit-map-insdel-item.vcxproj +++ b/projects/Win/vc14/unit-map-insdel-item.vcxproj @@ -56,7 +56,7 @@ - + @@ -65,7 +65,7 @@ - + diff --git a/projects/Win/vc14/unit-map-insdel-item.vcxproj.filters b/projects/Win/vc14/unit-map-insdel-item.vcxproj.filters index 5aa2b21b..8c0b268a 100644 --- a/projects/Win/vc14/unit-map-insdel-item.vcxproj.filters +++ b/projects/Win/vc14/unit-map-insdel-item.vcxproj.filters @@ -57,10 +57,10 @@ map_insdel_item_string - + map_insdel_item_int - + map_insdel_item_string diff --git a/projects/Win/vc14/unit-map-insdel.vcxproj b/projects/Win/vc14/unit-map-insdel.vcxproj index 514c248f..b2ac6a90 100644 --- a/projects/Win/vc14/unit-map-insdel.vcxproj +++ b/projects/Win/vc14/unit-map-insdel.vcxproj @@ -56,7 +56,7 @@ - + @@ -65,7 +65,7 @@ - + @@ -75,7 +75,7 @@ - + diff --git a/projects/Win/vc14/unit-map-insdel.vcxproj.filters b/projects/Win/vc14/unit-map-insdel.vcxproj.filters index 0818ac7a..ef09d099 100644 --- a/projects/Win/vc14/unit-map-insdel.vcxproj.filters +++ b/projects/Win/vc14/unit-map-insdel.vcxproj.filters @@ -76,16 +76,16 @@ map_insdel_string - + map_insdel_int map_insdel_int - + map_insdel_func - + map_insdel_string diff --git a/projects/Win/vc14/unit-map-insdelfind.vcxproj b/projects/Win/vc14/unit-map-insdelfind.vcxproj index aef3bdad..a62d2f13 100644 --- a/projects/Win/vc14/unit-map-insdelfind.vcxproj +++ b/projects/Win/vc14/unit-map-insdelfind.vcxproj @@ -56,7 +56,7 @@ - + diff --git a/projects/Win/vc14/unit-set-delodd.vcxproj b/projects/Win/vc14/unit-set-delodd.vcxproj index 8981a8eb..f5fed26b 100644 --- a/projects/Win/vc14/unit-set-delodd.vcxproj +++ b/projects/Win/vc14/unit-set-delodd.vcxproj @@ -55,7 +55,7 @@ - + diff --git a/projects/Win/vc14/unit-set-insdel.vcxproj b/projects/Win/vc14/unit-set-insdel.vcxproj index 1cc826c3..9a8ad1dc 100644 --- a/projects/Win/vc14/unit-set-insdel.vcxproj +++ b/projects/Win/vc14/unit-set-insdel.vcxproj @@ -55,7 +55,7 @@ - + @@ -63,7 +63,7 @@ - + diff --git a/projects/Win/vc14/unit-set-insdel.vcxproj.filters b/projects/Win/vc14/unit-set-insdel.vcxproj.filters index 74851368..643f5857 100644 --- a/projects/Win/vc14/unit-set-insdel.vcxproj.filters +++ b/projects/Win/vc14/unit-set-insdel.vcxproj.filters @@ -46,10 +46,10 @@ set_insdel_func - + set_insdel_func - + set_insdel_string diff --git a/projects/Win/vc14/unit-set-insdelfind.vcxproj b/projects/Win/vc14/unit-set-insdelfind.vcxproj index 9d1009a4..614d6046 100644 --- a/projects/Win/vc14/unit-set-insdelfind.vcxproj +++ b/projects/Win/vc14/unit-set-insdelfind.vcxproj @@ -55,7 +55,7 @@ - + diff --git a/projects/source.test-hdr.mk b/projects/source.test-hdr.mk index 3e202ed4..7ae0cf05 100644 --- a/projects/source.test-hdr.mk +++ b/projects/source.test-hdr.mk @@ -15,13 +15,13 @@ CDS_TESTHDR_MAP := \ tests/test-hdr/map/hdr_michael_map_lazy_rcu_shb.cpp \ tests/test-hdr/map/hdr_michael_map_lazy_rcu_sht.cpp \ tests/test-hdr/map/hdr_michael_map_lazy_nogc.cpp \ - tests/test-hdr/map/hdr_multilevel_hashmap_hp.cpp \ - tests/test-hdr/map/hdr_multilevel_hashmap_dhp.cpp \ - tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpb.cpp \ - tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpi.cpp \ - tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpt.cpp \ - tests/test-hdr/map/hdr_multilevel_hashmap_rcu_shb.cpp \ - tests/test-hdr/map/hdr_multilevel_hashmap_rcu_sht.cpp \ + tests/test-hdr/map/hdr_feldman_hashmap_hp.cpp \ + tests/test-hdr/map/hdr_feldman_hashmap_dhp.cpp \ + tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpb.cpp \ + tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpi.cpp \ + tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpt.cpp \ + tests/test-hdr/map/hdr_feldman_hashmap_rcu_shb.cpp \ + tests/test-hdr/map/hdr_feldman_hashmap_rcu_sht.cpp \ tests/test-hdr/map/hdr_refinable_hashmap_hashmap_std.cpp \ tests/test-hdr/map/hdr_refinable_hashmap_boost_list.cpp \ tests/test-hdr/map/hdr_refinable_hashmap_list.cpp \ @@ -136,13 +136,13 @@ 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_multilevel_hashset_dhp.cpp \ - tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpi.cpp \ - tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpb.cpp \ - tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpt.cpp \ - tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_shb.cpp \ - tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_sht.cpp \ + tests/test-hdr/set/hdr_intrusive_feldman_hashset_hp.cpp \ + tests/test-hdr/set/hdr_intrusive_feldman_hashset_dhp.cpp \ + tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpi.cpp \ + tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpb.cpp \ + tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpt.cpp \ + tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_shb.cpp \ + tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_sht.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 \ @@ -184,13 +184,13 @@ CDS_TESTHDR_SET := \ tests/test-hdr/set/hdr_michael_set_lazy_rcu_shb.cpp \ tests/test-hdr/set/hdr_michael_set_lazy_rcu_sht.cpp \ tests/test-hdr/set/hdr_michael_set_lazy_nogc.cpp \ - tests/test-hdr/set/hdr_multilevel_hashset_hp.cpp \ - tests/test-hdr/set/hdr_multilevel_hashset_dhp.cpp \ - tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpb.cpp \ - tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpi.cpp \ - tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpt.cpp \ - tests/test-hdr/set/hdr_multilevel_hashset_rcu_shb.cpp \ - tests/test-hdr/set/hdr_multilevel_hashset_rcu_sht.cpp \ + tests/test-hdr/set/hdr_feldman_hashset_hp.cpp \ + tests/test-hdr/set/hdr_feldman_hashset_dhp.cpp \ + tests/test-hdr/set/hdr_feldman_hashset_rcu_gpb.cpp \ + tests/test-hdr/set/hdr_feldman_hashset_rcu_gpi.cpp \ + tests/test-hdr/set/hdr_feldman_hashset_rcu_gpt.cpp \ + tests/test-hdr/set/hdr_feldman_hashset_rcu_shb.cpp \ + tests/test-hdr/set/hdr_feldman_hashset_rcu_sht.cpp \ tests/test-hdr/set/hdr_refinable_hashset_hashset_std.cpp \ tests/test-hdr/set/hdr_refinable_hashset_boost_flat_set.cpp \ tests/test-hdr/set/hdr_refinable_hashset_boost_list.cpp \ diff --git a/projects/source.unit.map.mk b/projects/source.unit.map.mk index 8367de57..1db4e0e2 100644 --- a/projects/source.unit.map.mk +++ b/projects/source.unit.map.mk @@ -5,7 +5,7 @@ CDSUNIT_MAP_SOURCES := \ tests/unit/map2/map_find_int_cuckoo.cpp \ tests/unit/map2/map_find_int_ellentree.cpp \ tests/unit/map2/map_find_int_michael.cpp \ - tests/unit/map2/map_find_int_multilevelhashmap.cpp \ + tests/unit/map2/map_find_int_feldmanhashmap.cpp \ tests/unit/map2/map_find_int_skip.cpp \ tests/unit/map2/map_find_int_split.cpp \ tests/unit/map2/map_find_int_striped.cpp \ @@ -15,7 +15,7 @@ CDSUNIT_MAP_SOURCES := \ tests/unit/map2/map_find_string_cuckoo.cpp \ tests/unit/map2/map_find_string_ellentree.cpp \ tests/unit/map2/map_find_string_michael.cpp \ - tests/unit/map2/map_find_string_multilevelhashmap.cpp \ + tests/unit/map2/map_find_string_feldmanhashmap.cpp \ tests/unit/map2/map_find_string_skip.cpp \ tests/unit/map2/map_find_string_split.cpp \ tests/unit/map2/map_find_string_striped.cpp \ @@ -25,7 +25,7 @@ CDSUNIT_MAP_SOURCES := \ tests/unit/map2/map_insfind_int_cuckoo.cpp \ tests/unit/map2/map_insfind_int_ellentree.cpp \ tests/unit/map2/map_insfind_int_michael.cpp \ - tests/unit/map2/map_insfind_int_multilevelhashmap.cpp \ + tests/unit/map2/map_insfind_int_feldmanhashmap.cpp \ tests/unit/map2/map_insfind_int_skip.cpp \ tests/unit/map2/map_insfind_int_split.cpp \ tests/unit/map2/map_insfind_int_striped.cpp \ @@ -35,7 +35,7 @@ CDSUNIT_MAP_SOURCES := \ tests/unit/map2/map_insdel_func_cuckoo.cpp \ tests/unit/map2/map_insdel_func_ellentree.cpp \ tests/unit/map2/map_insdel_func_michael.cpp \ - tests/unit/map2/map_insdel_func_multilevelhashmap.cpp \ + tests/unit/map2/map_insdel_func_feldmanhashmap.cpp \ tests/unit/map2/map_insdel_func_skip.cpp \ tests/unit/map2/map_insdel_func_split.cpp \ tests/unit/map2/map_insdel_func_striped.cpp \ @@ -44,7 +44,7 @@ CDSUNIT_MAP_SOURCES := \ tests/unit/map2/map_insdel_int_cuckoo.cpp \ tests/unit/map2/map_insdel_int_ellentree.cpp \ tests/unit/map2/map_insdel_int_michael.cpp \ - tests/unit/map2/map_insdel_int_multilevelhashmap.cpp \ + tests/unit/map2/map_insdel_int_feldmanhashmap.cpp \ tests/unit/map2/map_insdel_int_skip.cpp \ tests/unit/map2/map_insdel_int_split.cpp \ tests/unit/map2/map_insdel_int_striped.cpp \ @@ -54,7 +54,7 @@ CDSUNIT_MAP_SOURCES := \ tests/unit/map2/map_insdel_item_int_cuckoo.cpp \ tests/unit/map2/map_insdel_item_int_ellentree.cpp \ tests/unit/map2/map_insdel_item_int_michael.cpp \ - tests/unit/map2/map_insdel_item_int_multilevelhashmap.cpp \ + tests/unit/map2/map_insdel_item_int_feldmanhashmap.cpp \ tests/unit/map2/map_insdel_item_int_skip.cpp \ tests/unit/map2/map_insdel_item_int_split.cpp \ tests/unit/map2/map_insdel_item_int_striped.cpp \ @@ -63,7 +63,7 @@ CDSUNIT_MAP_SOURCES := \ tests/unit/map2/map_insdel_item_string_cuckoo.cpp \ tests/unit/map2/map_insdel_item_string_ellentree.cpp \ tests/unit/map2/map_insdel_item_string_michael.cpp \ - tests/unit/map2/map_insdel_item_string_multilevelhashmap.cpp \ + tests/unit/map2/map_insdel_item_string_feldmanhashmap.cpp \ tests/unit/map2/map_insdel_item_string_skip.cpp \ tests/unit/map2/map_insdel_item_string_split.cpp \ tests/unit/map2/map_insdel_item_string_striped.cpp \ @@ -72,7 +72,7 @@ CDSUNIT_MAP_SOURCES := \ tests/unit/map2/map_insdel_string_cuckoo.cpp \ tests/unit/map2/map_insdel_string_ellentree.cpp \ tests/unit/map2/map_insdel_string_michael.cpp \ - tests/unit/map2/map_insdel_string_multilevelhashmap.cpp \ + tests/unit/map2/map_insdel_string_feldmanhashmap.cpp \ tests/unit/map2/map_insdel_string_skip.cpp \ tests/unit/map2/map_insdel_string_split.cpp \ tests/unit/map2/map_insdel_string_striped.cpp \ @@ -82,7 +82,7 @@ CDSUNIT_MAP_SOURCES := \ tests/unit/map2/map_insdelfind_cuckoo.cpp \ tests/unit/map2/map_insdelfind_ellentree.cpp \ tests/unit/map2/map_insdelfind_michael.cpp \ - tests/unit/map2/map_insdelfind_multilevelhashmap.cpp \ + tests/unit/map2/map_insdelfind_feldmanhashmap.cpp \ tests/unit/map2/map_insdelfind_skip.cpp \ tests/unit/map2/map_insdelfind_split.cpp \ tests/unit/map2/map_insdelfind_striped.cpp \ @@ -92,6 +92,6 @@ CDSUNIT_MAP_SOURCES := \ tests/unit/map2/map_delodd_cuckoo.cpp \ tests/unit/map2/map_delodd_ellentree.cpp \ tests/unit/map2/map_delodd_michael.cpp \ - tests/unit/map2/map_delodd_multilevelhashmap.cpp \ + tests/unit/map2/map_delodd_feldmanhashmap.cpp \ tests/unit/map2/map_delodd_skip.cpp \ tests/unit/map2/map_delodd_split.cpp \ diff --git a/projects/source.unit.set.mk b/projects/source.unit.set.mk index 49688bad..46178fdd 100644 --- a/projects/source.unit.set.mk +++ b/projects/source.unit.set.mk @@ -4,7 +4,7 @@ CDSUNIT_SET_SOURCES := \ tests/unit/set2/set_insdel_func_cuckoo.cpp \ tests/unit/set2/set_insdel_func_ellentree.cpp \ tests/unit/set2/set_insdel_func_michael.cpp \ - tests/unit/set2/set_insdel_func_multilevelhashset.cpp \ + tests/unit/set2/set_insdel_func_feldmanhashset.cpp \ tests/unit/set2/set_insdel_func_skip.cpp \ tests/unit/set2/set_insdel_func_split.cpp \ tests/unit/set2/set_insdel_func_striped.cpp \ @@ -12,7 +12,7 @@ CDSUNIT_SET_SOURCES := \ tests/unit/set2/set_insdel_string_cuckoo.cpp \ tests/unit/set2/set_insdel_string_ellentree.cpp \ tests/unit/set2/set_insdel_string_michael.cpp \ - tests/unit/set2/set_insdel_string_multilevelhashset.cpp \ + tests/unit/set2/set_insdel_string_feldmanhashset.cpp \ tests/unit/set2/set_insdel_string_skip.cpp \ tests/unit/set2/set_insdel_string_split.cpp \ tests/unit/set2/set_insdel_string_striped.cpp \ @@ -21,7 +21,7 @@ CDSUNIT_SET_SOURCES := \ tests/unit/set2/set_insdelfind_cuckoo.cpp \ tests/unit/set2/set_insdelfind_ellentree.cpp \ tests/unit/set2/set_insdelfind_michael.cpp \ - tests/unit/set2/set_insdelfind_multilevelhashset.cpp \ + tests/unit/set2/set_insdelfind_feldmanhashset.cpp \ tests/unit/set2/set_insdelfind_skip.cpp \ tests/unit/set2/set_insdelfind_split.cpp \ tests/unit/set2/set_insdelfind_striped.cpp \ @@ -30,6 +30,6 @@ CDSUNIT_SET_SOURCES := \ tests/unit/set2/set_delodd_cuckoo.cpp \ tests/unit/set2/set_delodd_ellentree.cpp \ tests/unit/set2/set_delodd_michael.cpp \ - tests/unit/set2/set_delodd_multilevelhashset.cpp \ + tests/unit/set2/set_delodd_feldmanhashset.cpp \ tests/unit/set2/set_delodd_skip.cpp \ tests/unit/set2/set_delodd_split.cpp \ diff --git a/tests/data/test-debug.conf b/tests/data/test-debug.conf index f7b05d65..ce46294d 100644 --- a/tests/data/test-debug.conf +++ b/tests/data/test-debug.conf @@ -127,9 +127,9 @@ CuckooInitialSize=256 CuckooProbesetSize=8 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_find_string] ThreadCount=2 @@ -143,9 +143,9 @@ CuckooInitialSize=256 CuckooProbesetSize=8 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDel_int] InsertThreadCount=4 @@ -159,9 +159,9 @@ CuckooInitialSize=256 CuckooProbesetSize=8 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDel_func] InsertThreadCount=4 @@ -176,9 +176,9 @@ CuckooInitialSize=256 CuckooProbesetSize=8 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDel_Item_int] ThreadCount=4 @@ -192,9 +192,9 @@ CuckooInitialSize=256 CuckooProbesetSize=8 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDel_string] InsertThreadCount=4 @@ -208,9 +208,9 @@ CuckooInitialSize=256 CuckooProbesetSize=8 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDel_Item_string] ThreadCount=4 @@ -224,9 +224,9 @@ CuckooInitialSize=256 CuckooProbesetSize=8 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsFind_int] ThreadCount=0 @@ -238,9 +238,9 @@ CuckooInitialSize=256 CuckooProbesetSize=8 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDelFind] InitialMapSize=50000 @@ -255,9 +255,9 @@ CuckooInitialSize=256 CuckooProbesetSize=8 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_DelOdd] MapSize=50000 @@ -271,6 +271,6 @@ CuckooInitialSize=256 CuckooProbesetSize=8 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 diff --git a/tests/data/test-express.conf b/tests/data/test-express.conf index 3fd1f3cd..c58393c8 100644 --- a/tests/data/test-express.conf +++ b/tests/data/test-express.conf @@ -125,9 +125,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_find_string] ThreadCount=8 @@ -141,9 +141,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDel_int] InsertThreadCount=4 @@ -157,9 +157,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDel_func] InsertThreadCount=4 @@ -174,9 +174,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDel_Item_int] ThreadCount=8 @@ -190,9 +190,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDel_string] InsertThreadCount=4 @@ -206,9 +206,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDel_Item_string] ThreadCount=8 @@ -222,9 +222,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsFind_int] ThreadCount=0 @@ -236,9 +236,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_InsDelFind] InitialMapSize=500000 @@ -253,9 +253,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 [Map_DelOdd] MapSize=500000 @@ -269,6 +269,6 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=8 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=8 +FeldmanMapArrayBits=4 diff --git a/tests/data/test.conf b/tests/data/test.conf index 257a7def..f5284ecd 100644 --- a/tests/data/test.conf +++ b/tests/data/test.conf @@ -120,9 +120,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=10 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=10 +FeldmanMapArrayBits=4 [Map_find_string] ThreadCount=8 @@ -136,9 +136,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=10 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=10 +FeldmanMapArrayBits=4 [Map_InsDel_int] InsertThreadCount=4 @@ -152,9 +152,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=10 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=10 +FeldmanMapArrayBits=4 [Map_InsDel_func] InsertThreadCount=4 @@ -169,9 +169,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=10 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=10 +FeldmanMapArrayBits=4 [Map_InsDel_Item_int] ThreadCount=8 @@ -185,9 +185,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=10 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=10 +FeldmanMapArrayBits=4 [Map_InsDel_string] InsertThreadCount=4 @@ -201,9 +201,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=10 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=10 +FeldmanMapArrayBits=4 [Map_InsDel_Item_string] ThreadCount=8 @@ -217,9 +217,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=10 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=10 +FeldmanMapArrayBits=4 [Map_InsFind_int] ThreadCount=0 @@ -231,9 +231,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=10 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=10 +FeldmanMapArrayBits=4 [Map_InsDelFind] InitialMapSize=500000 @@ -248,9 +248,9 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=10 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=10 +FeldmanMapArrayBits=4 [Map_DelOdd] @@ -265,6 +265,6 @@ CuckooInitialSize=1024 CuckooProbesetSize=16 # 0 - use default CuckooProbesetThreshold=0 -# *** MultiLevelHashMap properties -MultiLevelMapHeadBits=10 -MultiLevelMapArrayBits=4 +# *** FeldmanHashMap properties +FeldmanMapHeadBits=10 +FeldmanMapArrayBits=4 diff --git a/tests/test-hdr/CMakeLists.txt b/tests/test-hdr/CMakeLists.txt index e90e9462..c93157a1 100644 --- a/tests/test-hdr/CMakeLists.txt +++ b/tests/test-hdr/CMakeLists.txt @@ -17,13 +17,13 @@ set(CDS_TESTHDR_MAP map/hdr_michael_map_lazy_rcu_shb.cpp map/hdr_michael_map_lazy_rcu_sht.cpp map/hdr_michael_map_lazy_nogc.cpp - map/hdr_multilevel_hashmap_hp.cpp - map/hdr_multilevel_hashmap_dhp.cpp - map/hdr_multilevel_hashmap_rcu_gpb.cpp - map/hdr_multilevel_hashmap_rcu_gpi.cpp - map/hdr_multilevel_hashmap_rcu_gpt.cpp - map/hdr_multilevel_hashmap_rcu_shb.cpp - map/hdr_multilevel_hashmap_rcu_sht.cpp + map/hdr_feldman_hashmap_hp.cpp + map/hdr_feldman_hashmap_dhp.cpp + map/hdr_feldman_hashmap_rcu_gpb.cpp + map/hdr_feldman_hashmap_rcu_gpi.cpp + map/hdr_feldman_hashmap_rcu_gpt.cpp + map/hdr_feldman_hashmap_rcu_shb.cpp + map/hdr_feldman_hashmap_rcu_sht.cpp map/hdr_refinable_hashmap_hashmap_std.cpp map/hdr_refinable_hashmap_boost_list.cpp map/hdr_refinable_hashmap_list.cpp @@ -138,13 +138,13 @@ set(CDS_TESTHDR_QUEUE queue/hdr_vyukov_mpmc_cyclic.cpp) set(CDS_TESTHDR_SET - set/hdr_intrusive_multilevel_hashset_hp.cpp - set/hdr_intrusive_multilevel_hashset_dhp.cpp - set/hdr_intrusive_multilevel_hashset_rcu_gpi.cpp - set/hdr_intrusive_multilevel_hashset_rcu_gpb.cpp - set/hdr_intrusive_multilevel_hashset_rcu_gpt.cpp - set/hdr_intrusive_multilevel_hashset_rcu_shb.cpp - set/hdr_intrusive_multilevel_hashset_rcu_sht.cpp + set/hdr_intrusive_feldman_hashset_hp.cpp + set/hdr_intrusive_feldman_hashset_dhp.cpp + set/hdr_intrusive_feldman_hashset_rcu_gpi.cpp + set/hdr_intrusive_feldman_hashset_rcu_gpb.cpp + set/hdr_intrusive_feldman_hashset_rcu_gpt.cpp + set/hdr_intrusive_feldman_hashset_rcu_shb.cpp + set/hdr_intrusive_feldman_hashset_rcu_sht.cpp set/hdr_intrusive_refinable_hashset_avlset.cpp set/hdr_intrusive_refinable_hashset_list.cpp set/hdr_intrusive_refinable_hashset_set.cpp @@ -186,13 +186,13 @@ set(CDS_TESTHDR_SET set/hdr_michael_set_lazy_rcu_shb.cpp set/hdr_michael_set_lazy_rcu_sht.cpp set/hdr_michael_set_lazy_nogc.cpp - set/hdr_multilevel_hashset_hp.cpp - set/hdr_multilevel_hashset_dhp.cpp - set/hdr_multilevel_hashset_rcu_gpb.cpp - set/hdr_multilevel_hashset_rcu_gpi.cpp - set/hdr_multilevel_hashset_rcu_gpt.cpp - set/hdr_multilevel_hashset_rcu_shb.cpp - set/hdr_multilevel_hashset_rcu_sht.cpp + set/hdr_feldman_hashset_hp.cpp + set/hdr_feldman_hashset_dhp.cpp + set/hdr_feldman_hashset_rcu_gpb.cpp + set/hdr_feldman_hashset_rcu_gpi.cpp + set/hdr_feldman_hashset_rcu_gpt.cpp + set/hdr_feldman_hashset_rcu_shb.cpp + set/hdr_feldman_hashset_rcu_sht.cpp set/hdr_refinable_hashset_hashset_std.cpp set/hdr_refinable_hashset_boost_flat_set.cpp set/hdr_refinable_hashset_boost_list.cpp diff --git a/tests/test-hdr/map/hdr_multilevel_hashmap.h b/tests/test-hdr/map/hdr_feldman_hashmap.h similarity index 99% rename from tests/test-hdr/map/hdr_multilevel_hashmap.h rename to tests/test-hdr/map/hdr_feldman_hashmap.h index 8d0bf2c6..b8fc5a7a 100644 --- a/tests/test-hdr/map/hdr_multilevel_hashmap.h +++ b/tests/test-hdr/map/hdr_feldman_hashmap.h @@ -1,7 +1,7 @@ //$$CDS-header$$ -#ifndef CDSTEST_HDR_MULTILEVEL_HASHMAP_H -#define CDSTEST_HDR_MULTILEVEL_HASHMAP_H +#ifndef CDSTEST_HDR_FELDMAN_HASHMAP_H +#define CDSTEST_HDR_FELDMAN_HASHMAP_H #include "cppunit/cppunit_proxy.h" @@ -15,7 +15,7 @@ namespace map { namespace cc = cds::container; namespace co = cds::opt; - class MultiLevelHashMapHdrTest : public CppUnitMini::TestCase + class FeldmanHashMapHdrTest : public CppUnitMini::TestCase { struct Item { @@ -699,7 +699,7 @@ namespace map { void rcu_sht_hash128_4_3(); void rcu_sht_hash128_4_3_stat(); - CPPUNIT_TEST_SUITE(MultiLevelHashMapHdrTest) + CPPUNIT_TEST_SUITE(FeldmanHashMapHdrTest) CPPUNIT_TEST(hp_nohash) CPPUNIT_TEST(hp_nohash_stat) CPPUNIT_TEST(hp_nohash_5_3) @@ -796,4 +796,4 @@ namespace map { } // namespace map -#endif //#ifndef CDSTEST_HDR_MULTILEVEL_HASHMAP_H +#endif //#ifndef CDSTEST_HDR_FELDMAN_HASHMAP_H diff --git a/tests/test-hdr/map/hdr_feldman_hashmap_dhp.cpp b/tests/test-hdr/map/hdr_feldman_hashmap_dhp.cpp new file mode 100644 index 00000000..de6aef85 --- /dev/null +++ b/tests/test-hdr/map/hdr_feldman_hashmap_dhp.cpp @@ -0,0 +1,198 @@ +//$$CDS-header$$ + +#include "map/hdr_feldman_hashmap.h" +#include +#include "unit/print_feldman_hashset_stat.h" + +namespace map { + namespace { + typedef cds::gc::DHP gc_type; + } // namespace + + void FeldmanHashMapHdrTest::dhp_nohash() + { + typedef cc::FeldmanHashMap< gc_type, size_t, Item > map_type; + + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::dhp_stdhash() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::dhp_hash128() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 2); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::dhp_nohash_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 2); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + >::type + > map_type2; + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::dhp_stdhash_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 2); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::hash< std::hash> + >::type + > map_type2; + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::dhp_hash128_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef hash128::make hash; + typedef hash128::cmp compare; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 2); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::hash< hash128::make > + , co::compare< hash128::cmp > + >::type + > map_type2; + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::dhp_nohash_5_3() + { + typedef cc::FeldmanHashMap< gc_type, size_t, Item > map_type; + + test_hp(5, 3); + } + + + void FeldmanHashMapHdrTest::dhp_stdhash_5_3() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + + test_hp(5, 3); + } + + void FeldmanHashMapHdrTest::dhp_nohash_5_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(5, 3); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::back_off< cds::backoff::empty > + >::type + > map_type2; + test_hp(5, 3); + } + + void FeldmanHashMapHdrTest::dhp_stdhash_5_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(5, 3); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::back_off< cds::backoff::empty > + ,co::hash< std::hash> + >::type + > map_type2; + test_hp(5, 3); + } + + void FeldmanHashMapHdrTest::dhp_hash128_4_3() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 3); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_hp(4, 3); + } + + void FeldmanHashMapHdrTest::dhp_hash128_4_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + typedef cc::feldman_hashmap::stat<> stat; + typedef co::v::sequential_consistent memory_model; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 3); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + , co::stat< cc::feldman_hashmap::stat<>> + , co::memory_model< co::v::sequential_consistent > + >::type + > map_type2; + test_hp(4, 3); + } +} // namespace map + +CPPUNIT_TEST_SUITE_REGISTRATION(map::FeldmanHashMapHdrTest); diff --git a/tests/test-hdr/map/hdr_feldman_hashmap_hp.cpp b/tests/test-hdr/map/hdr_feldman_hashmap_hp.cpp new file mode 100644 index 00000000..2c4df61f --- /dev/null +++ b/tests/test-hdr/map/hdr_feldman_hashmap_hp.cpp @@ -0,0 +1,198 @@ +//$$CDS-header$$ + +#include "map/hdr_feldman_hashmap.h" +#include +#include "unit/print_feldman_hashset_stat.h" + +namespace map { + namespace { + typedef cds::gc::HP gc_type; + } // namespace + + void FeldmanHashMapHdrTest::hp_nohash() + { + typedef cc::FeldmanHashMap< gc_type, size_t, Item > map_type; + + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::hp_stdhash() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::hp_hash128() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 2); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::hp_nohash_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 2); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + >::type + > map_type2; + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::hp_stdhash_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 2); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::hash< std::hash> + >::type + > map_type2; + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::hp_hash128_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef hash128::make hash; + typedef hash128::cmp compare; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 2); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::hash< hash128::make > + , co::compare< hash128::cmp > + >::type + > map_type2; + test_hp(4, 2); + } + + void FeldmanHashMapHdrTest::hp_nohash_5_3() + { + typedef cc::FeldmanHashMap< gc_type, size_t, Item > map_type; + + test_hp(5, 3); + } + + + void FeldmanHashMapHdrTest::hp_stdhash_5_3() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + + test_hp(5, 3); + } + + void FeldmanHashMapHdrTest::hp_nohash_5_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(5, 3); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::back_off< cds::backoff::empty > + >::type + > map_type2; + test_hp(5, 3); + } + + void FeldmanHashMapHdrTest::hp_stdhash_5_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(5, 3); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::back_off< cds::backoff::empty > + ,co::hash< std::hash> + >::type + > map_type2; + test_hp(5, 3); + } + + void FeldmanHashMapHdrTest::hp_hash128_4_3() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 3); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_hp(4, 3); + } + + void FeldmanHashMapHdrTest::hp_hash128_4_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + typedef cc::feldman_hashmap::stat<> stat; + typedef co::v::sequential_consistent memory_model; + }; + typedef cc::FeldmanHashMap< gc_type, size_t, Item, traits > map_type; + test_hp(4, 3); + + typedef cc::FeldmanHashMap< gc_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + , co::stat< cc::feldman_hashmap::stat<>> + , co::memory_model< co::v::sequential_consistent > + >::type + > map_type2; + test_hp(4, 3); + } +} // namespace map + +CPPUNIT_TEST_SUITE_REGISTRATION(map::FeldmanHashMapHdrTest); diff --git a/tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpb.cpp b/tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpb.cpp new file mode 100644 index 00000000..87582cdb --- /dev/null +++ b/tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpb.cpp @@ -0,0 +1,197 @@ +//$$CDS-header$$ + +#include "map/hdr_feldman_hashmap.h" +#include +#include +#include "unit/print_feldman_hashset_stat.h" + +namespace map { + namespace { + typedef cds::urcu::gc< cds::urcu::general_buffered<>> rcu_type; + } // namespace + + void FeldmanHashMapHdrTest::rcu_gpb_nohash() + { + typedef cc::FeldmanHashMap< rcu_type, size_t, Item > map_type; + + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpb_stdhash() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpb_hash128() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpb_nohash_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpb_stdhash_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::hash> + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpb_hash128_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef hash128::make hash; + typedef hash128::cmp compare; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::hash< hash128::make > + , co::compare< hash128::cmp > + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpb_nohash_5_3() + { + typedef cc::FeldmanHashMap< rcu_type, size_t, Item > map_type; + + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpb_stdhash_5_3() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpb_nohash_5_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(5, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::back_off< cds::backoff::empty > + >::type + > map_type2; + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpb_stdhash_5_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(5, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::back_off< cds::backoff::empty > + ,co::hash< std::hash> + >::type + > map_type2; + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpb_hash128_4_3() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_rcu(4, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpb_hash128_4_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + typedef cc::feldman_hashmap::stat<> stat; + typedef co::v::sequential_consistent memory_model; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + , co::stat< cc::feldman_hashmap::stat<>> + , co::memory_model< co::v::sequential_consistent > + >::type + > map_type2; + test_rcu(4, 3); + } + +} // namespace map diff --git a/tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpi.cpp b/tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpi.cpp new file mode 100644 index 00000000..145a47ae --- /dev/null +++ b/tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpi.cpp @@ -0,0 +1,197 @@ +//$$CDS-header$$ + +#include "map/hdr_feldman_hashmap.h" +#include +#include +#include "unit/print_feldman_hashset_stat.h" + +namespace map { + namespace { + typedef cds::urcu::gc< cds::urcu::general_instant<>> rcu_type; + } // namespace + + void FeldmanHashMapHdrTest::rcu_gpi_nohash() + { + typedef cc::FeldmanHashMap< rcu_type, size_t, Item > map_type; + + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpi_stdhash() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpi_hash128() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpi_nohash_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpi_stdhash_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::hash> + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpi_hash128_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef hash128::make hash; + typedef hash128::cmp compare; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::hash< hash128::make > + , co::compare< hash128::cmp > + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpi_nohash_5_3() + { + typedef cc::FeldmanHashMap< rcu_type, size_t, Item > map_type; + + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpi_stdhash_5_3() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpi_nohash_5_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(5, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::back_off< cds::backoff::empty > + >::type + > map_type2; + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpi_stdhash_5_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(5, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::back_off< cds::backoff::empty > + ,co::hash< std::hash> + >::type + > map_type2; + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpi_hash128_4_3() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_rcu(4, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpi_hash128_4_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + typedef cc::feldman_hashmap::stat<> stat; + typedef co::v::sequential_consistent memory_model; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + , co::stat< cc::feldman_hashmap::stat<>> + , co::memory_model< co::v::sequential_consistent > + >::type + > map_type2; + test_rcu(4, 3); + } + +} // namespace map diff --git a/tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpt.cpp b/tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpt.cpp new file mode 100644 index 00000000..534ab886 --- /dev/null +++ b/tests/test-hdr/map/hdr_feldman_hashmap_rcu_gpt.cpp @@ -0,0 +1,197 @@ +//$$CDS-header$$ + +#include "map/hdr_feldman_hashmap.h" +#include +#include +#include "unit/print_feldman_hashset_stat.h" + +namespace map { + namespace { + typedef cds::urcu::gc< cds::urcu::general_threaded<>> rcu_type; + } // namespace + + void FeldmanHashMapHdrTest::rcu_gpt_nohash() + { + typedef cc::FeldmanHashMap< rcu_type, size_t, Item > map_type; + + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpt_stdhash() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpt_hash128() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpt_nohash_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpt_stdhash_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::hash> + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpt_hash128_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef hash128::make hash; + typedef hash128::cmp compare; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::hash< hash128::make > + , co::compare< hash128::cmp > + >::type + > map_type2; + test_rcu(4, 2); + } + + void FeldmanHashMapHdrTest::rcu_gpt_nohash_5_3() + { + typedef cc::FeldmanHashMap< rcu_type, size_t, Item > map_type; + + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpt_stdhash_5_3() + { + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpt_nohash_5_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(5, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::back_off< cds::backoff::empty > + >::type + > map_type2; + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpt_stdhash_5_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(5, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::back_off< cds::backoff::empty > + ,co::hash< std::hash> + >::type + > map_type2; + test_rcu(5, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpt_hash128_4_3() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_rcu(4, 3); + } + + void FeldmanHashMapHdrTest::rcu_gpt_hash128_4_3_stat() + { + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + typedef cc::feldman_hashmap::stat<> stat; + typedef co::v::sequential_consistent memory_model; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + , co::stat< cc::feldman_hashmap::stat<>> + , co::memory_model< co::v::sequential_consistent > + >::type + > map_type2; + test_rcu(4, 3); + } + +} // namespace map diff --git a/tests/test-hdr/map/hdr_feldman_hashmap_rcu_shb.cpp b/tests/test-hdr/map/hdr_feldman_hashmap_rcu_shb.cpp new file mode 100644 index 00000000..b9b34ad4 --- /dev/null +++ b/tests/test-hdr/map/hdr_feldman_hashmap_rcu_shb.cpp @@ -0,0 +1,223 @@ +//$$CDS-header$$ + +#include "map/hdr_feldman_hashmap.h" +#include +#include +#include "unit/print_feldman_hashset_stat.h" + +namespace map { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + namespace { + typedef cds::urcu::gc< cds::urcu::signal_buffered<>> rcu_type; + } // namespace +#endif + + void FeldmanHashMapHdrTest::rcu_shb_nohash() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef cc::FeldmanHashMap< rcu_type, size_t, Item > map_type; + + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_stdhash() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_hash128() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_nohash_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + >::type + > map_type2; + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_stdhash_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::hash> + >::type + > map_type2; + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_hash128_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef hash128::make hash; + typedef hash128::cmp compare; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::hash< hash128::make > + , co::compare< hash128::cmp > + >::type + > map_type2; + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_nohash_5_3() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef cc::FeldmanHashMap< rcu_type, size_t, Item > map_type; + + test_rcu(5, 3); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_stdhash_5_3() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + + test_rcu(5, 3); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_nohash_5_3_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(5, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::back_off< cds::backoff::empty > + >::type + > map_type2; + test_rcu(5, 3); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_stdhash_5_3_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(5, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::back_off< cds::backoff::empty > + ,co::hash< std::hash> + >::type + > map_type2; + test_rcu(5, 3); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_hash128_4_3() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_rcu(4, 3); +#endif + } + + void FeldmanHashMapHdrTest::rcu_shb_hash128_4_3_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + typedef cc::feldman_hashmap::stat<> stat; + typedef co::v::sequential_consistent memory_model; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + , co::stat< cc::feldman_hashmap::stat<>> + , co::memory_model< co::v::sequential_consistent > + >::type + > map_type2; + test_rcu(4, 3); +#endif + } + +} // namespace map diff --git a/tests/test-hdr/map/hdr_feldman_hashmap_rcu_sht.cpp b/tests/test-hdr/map/hdr_feldman_hashmap_rcu_sht.cpp new file mode 100644 index 00000000..ce040861 --- /dev/null +++ b/tests/test-hdr/map/hdr_feldman_hashmap_rcu_sht.cpp @@ -0,0 +1,223 @@ +//$$CDS-header$$ + +#include "map/hdr_feldman_hashmap.h" +#include +#include +#include "unit/print_feldman_hashset_stat.h" + +namespace map { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + namespace { + typedef cds::urcu::gc< cds::urcu::signal_threaded<>> rcu_type; + } // namespace +#endif + + void FeldmanHashMapHdrTest::rcu_sht_nohash() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef cc::FeldmanHashMap< rcu_type, size_t, Item > map_type; + + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_stdhash() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_hash128() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_nohash_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + >::type + > map_type2; + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_stdhash_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::hash> + >::type + > map_type2; + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_hash128_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef hash128::make hash; + typedef hash128::cmp compare; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 2); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::hash< hash128::make > + , co::compare< hash128::cmp > + >::type + > map_type2; + test_rcu(4, 2); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_nohash_5_3() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef cc::FeldmanHashMap< rcu_type, size_t, Item > map_type; + + test_rcu(5, 3); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_stdhash_5_3() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + + test_rcu(5, 3); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_nohash_5_3_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(5, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + , co::back_off< cds::backoff::empty > + >::type + > map_type2; + test_rcu(5, 3); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_stdhash_5_3_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef cc::feldman_hashmap::stat<> stat; + typedef cds::backoff::empty back_off; + typedef std::hash hash; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(5, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::stat< cc::feldman_hashmap::stat<>> + ,co::back_off< cds::backoff::empty > + ,co::hash< std::hash> + >::type + > map_type2; + test_rcu(5, 3); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_hash128_4_3() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + >::type + > map_type2; + test_rcu(4, 3); +#endif + } + + void FeldmanHashMapHdrTest::rcu_sht_hash128_4_3_stat() + { +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + struct traits : public cc::feldman_hashmap::traits { + typedef hash128::make hash; + typedef hash128::less less; + typedef cc::feldman_hashmap::stat<> stat; + typedef co::v::sequential_consistent memory_model; + }; + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, traits > map_type; + test_rcu(4, 3); + + typedef cc::FeldmanHashMap< rcu_type, size_t, Item, + typename cc::feldman_hashmap::make_traits< + co::hash< hash128::make > + , co::less< hash128::less > + , co::stat< cc::feldman_hashmap::stat<>> + , co::memory_model< co::v::sequential_consistent > + >::type + > map_type2; + test_rcu(4, 3); +#endif + } + +} // namespace map diff --git a/tests/test-hdr/map/hdr_multilevel_hashmap_dhp.cpp b/tests/test-hdr/map/hdr_multilevel_hashmap_dhp.cpp deleted file mode 100644 index 89e8e60f..00000000 --- a/tests/test-hdr/map/hdr_multilevel_hashmap_dhp.cpp +++ /dev/null @@ -1,198 +0,0 @@ -//$$CDS-header$$ - -#include "map/hdr_multilevel_hashmap.h" -#include -#include "unit/print_multilevel_hashset_stat.h" - -namespace map { - namespace { - typedef cds::gc::DHP gc_type; - } // namespace - - void MultiLevelHashMapHdrTest::dhp_nohash() - { - typedef cc::MultiLevelHashMap< gc_type, size_t, Item > map_type; - - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::dhp_stdhash() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::dhp_hash128() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 2); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::dhp_nohash_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 2); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - >::type - > map_type2; - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::dhp_stdhash_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 2); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::hash< std::hash> - >::type - > map_type2; - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::dhp_hash128_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef hash128::make hash; - typedef hash128::cmp compare; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 2); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::hash< hash128::make > - , co::compare< hash128::cmp > - >::type - > map_type2; - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::dhp_nohash_5_3() - { - typedef cc::MultiLevelHashMap< gc_type, size_t, Item > map_type; - - test_hp(5, 3); - } - - - void MultiLevelHashMapHdrTest::dhp_stdhash_5_3() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - - test_hp(5, 3); - } - - void MultiLevelHashMapHdrTest::dhp_nohash_5_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(5, 3); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::back_off< cds::backoff::empty > - >::type - > map_type2; - test_hp(5, 3); - } - - void MultiLevelHashMapHdrTest::dhp_stdhash_5_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(5, 3); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::back_off< cds::backoff::empty > - ,co::hash< std::hash> - >::type - > map_type2; - test_hp(5, 3); - } - - void MultiLevelHashMapHdrTest::dhp_hash128_4_3() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 3); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_hp(4, 3); - } - - void MultiLevelHashMapHdrTest::dhp_hash128_4_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - typedef cc::multilevel_hashmap::stat<> stat; - typedef co::v::sequential_consistent memory_model; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 3); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - , co::stat< cc::multilevel_hashmap::stat<>> - , co::memory_model< co::v::sequential_consistent > - >::type - > map_type2; - test_hp(4, 3); - } -} // namespace map - -CPPUNIT_TEST_SUITE_REGISTRATION(map::MultiLevelHashMapHdrTest); diff --git a/tests/test-hdr/map/hdr_multilevel_hashmap_hp.cpp b/tests/test-hdr/map/hdr_multilevel_hashmap_hp.cpp deleted file mode 100644 index 8eca0d95..00000000 --- a/tests/test-hdr/map/hdr_multilevel_hashmap_hp.cpp +++ /dev/null @@ -1,198 +0,0 @@ -//$$CDS-header$$ - -#include "map/hdr_multilevel_hashmap.h" -#include -#include "unit/print_multilevel_hashset_stat.h" - -namespace map { - namespace { - typedef cds::gc::HP gc_type; - } // namespace - - void MultiLevelHashMapHdrTest::hp_nohash() - { - typedef cc::MultiLevelHashMap< gc_type, size_t, Item > map_type; - - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::hp_stdhash() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::hp_hash128() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 2); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::hp_nohash_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 2); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - >::type - > map_type2; - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::hp_stdhash_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 2); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::hash< std::hash> - >::type - > map_type2; - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::hp_hash128_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef hash128::make hash; - typedef hash128::cmp compare; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 2); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::hash< hash128::make > - , co::compare< hash128::cmp > - >::type - > map_type2; - test_hp(4, 2); - } - - void MultiLevelHashMapHdrTest::hp_nohash_5_3() - { - typedef cc::MultiLevelHashMap< gc_type, size_t, Item > map_type; - - test_hp(5, 3); - } - - - void MultiLevelHashMapHdrTest::hp_stdhash_5_3() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - - test_hp(5, 3); - } - - void MultiLevelHashMapHdrTest::hp_nohash_5_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(5, 3); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::back_off< cds::backoff::empty > - >::type - > map_type2; - test_hp(5, 3); - } - - void MultiLevelHashMapHdrTest::hp_stdhash_5_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(5, 3); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::back_off< cds::backoff::empty > - ,co::hash< std::hash> - >::type - > map_type2; - test_hp(5, 3); - } - - void MultiLevelHashMapHdrTest::hp_hash128_4_3() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 3); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_hp(4, 3); - } - - void MultiLevelHashMapHdrTest::hp_hash128_4_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - typedef cc::multilevel_hashmap::stat<> stat; - typedef co::v::sequential_consistent memory_model; - }; - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, traits > map_type; - test_hp(4, 3); - - typedef cc::MultiLevelHashMap< gc_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - , co::stat< cc::multilevel_hashmap::stat<>> - , co::memory_model< co::v::sequential_consistent > - >::type - > map_type2; - test_hp(4, 3); - } -} // namespace map - -CPPUNIT_TEST_SUITE_REGISTRATION(map::MultiLevelHashMapHdrTest); diff --git a/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpb.cpp b/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpb.cpp deleted file mode 100644 index 15d12185..00000000 --- a/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpb.cpp +++ /dev/null @@ -1,197 +0,0 @@ -//$$CDS-header$$ - -#include "map/hdr_multilevel_hashmap.h" -#include -#include -#include "unit/print_multilevel_hashset_stat.h" - -namespace map { - namespace { - typedef cds::urcu::gc< cds::urcu::general_buffered<>> rcu_type; - } // namespace - - void MultiLevelHashMapHdrTest::rcu_gpb_nohash() - { - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item > map_type; - - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_stdhash() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_hash128() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_nohash_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_stdhash_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::hash> - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_hash128_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef hash128::make hash; - typedef hash128::cmp compare; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::hash< hash128::make > - , co::compare< hash128::cmp > - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_nohash_5_3() - { - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item > map_type; - - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_stdhash_5_3() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_nohash_5_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(5, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::back_off< cds::backoff::empty > - >::type - > map_type2; - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_stdhash_5_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(5, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::back_off< cds::backoff::empty > - ,co::hash< std::hash> - >::type - > map_type2; - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_hash128_4_3() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_rcu(4, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpb_hash128_4_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - typedef cc::multilevel_hashmap::stat<> stat; - typedef co::v::sequential_consistent memory_model; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - , co::stat< cc::multilevel_hashmap::stat<>> - , co::memory_model< co::v::sequential_consistent > - >::type - > map_type2; - test_rcu(4, 3); - } - -} // namespace map diff --git a/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpi.cpp b/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpi.cpp deleted file mode 100644 index 349c29de..00000000 --- a/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpi.cpp +++ /dev/null @@ -1,197 +0,0 @@ -//$$CDS-header$$ - -#include "map/hdr_multilevel_hashmap.h" -#include -#include -#include "unit/print_multilevel_hashset_stat.h" - -namespace map { - namespace { - typedef cds::urcu::gc< cds::urcu::general_instant<>> rcu_type; - } // namespace - - void MultiLevelHashMapHdrTest::rcu_gpi_nohash() - { - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item > map_type; - - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_stdhash() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_hash128() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_nohash_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_stdhash_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::hash> - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_hash128_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef hash128::make hash; - typedef hash128::cmp compare; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::hash< hash128::make > - , co::compare< hash128::cmp > - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_nohash_5_3() - { - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item > map_type; - - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_stdhash_5_3() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_nohash_5_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(5, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::back_off< cds::backoff::empty > - >::type - > map_type2; - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_stdhash_5_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(5, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::back_off< cds::backoff::empty > - ,co::hash< std::hash> - >::type - > map_type2; - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_hash128_4_3() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_rcu(4, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpi_hash128_4_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - typedef cc::multilevel_hashmap::stat<> stat; - typedef co::v::sequential_consistent memory_model; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - , co::stat< cc::multilevel_hashmap::stat<>> - , co::memory_model< co::v::sequential_consistent > - >::type - > map_type2; - test_rcu(4, 3); - } - -} // namespace map diff --git a/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpt.cpp b/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpt.cpp deleted file mode 100644 index 155035c2..00000000 --- a/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_gpt.cpp +++ /dev/null @@ -1,197 +0,0 @@ -//$$CDS-header$$ - -#include "map/hdr_multilevel_hashmap.h" -#include -#include -#include "unit/print_multilevel_hashset_stat.h" - -namespace map { - namespace { - typedef cds::urcu::gc< cds::urcu::general_threaded<>> rcu_type; - } // namespace - - void MultiLevelHashMapHdrTest::rcu_gpt_nohash() - { - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item > map_type; - - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_stdhash() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_hash128() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_nohash_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_stdhash_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::hash> - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_hash128_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef hash128::make hash; - typedef hash128::cmp compare; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::hash< hash128::make > - , co::compare< hash128::cmp > - >::type - > map_type2; - test_rcu(4, 2); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_nohash_5_3() - { - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item > map_type; - - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_stdhash_5_3() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_nohash_5_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(5, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::back_off< cds::backoff::empty > - >::type - > map_type2; - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_stdhash_5_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(5, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::back_off< cds::backoff::empty > - ,co::hash< std::hash> - >::type - > map_type2; - test_rcu(5, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_hash128_4_3() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_rcu(4, 3); - } - - void MultiLevelHashMapHdrTest::rcu_gpt_hash128_4_3_stat() - { - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - typedef cc::multilevel_hashmap::stat<> stat; - typedef co::v::sequential_consistent memory_model; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - , co::stat< cc::multilevel_hashmap::stat<>> - , co::memory_model< co::v::sequential_consistent > - >::type - > map_type2; - test_rcu(4, 3); - } - -} // namespace map diff --git a/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_shb.cpp b/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_shb.cpp deleted file mode 100644 index 5eb4de4a..00000000 --- a/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_shb.cpp +++ /dev/null @@ -1,223 +0,0 @@ -//$$CDS-header$$ - -#include "map/hdr_multilevel_hashmap.h" -#include -#include -#include "unit/print_multilevel_hashset_stat.h" - -namespace map { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - namespace { - typedef cds::urcu::gc< cds::urcu::signal_buffered<>> rcu_type; - } // namespace -#endif - - void MultiLevelHashMapHdrTest::rcu_shb_nohash() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item > map_type; - - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_stdhash() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_hash128() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_nohash_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - >::type - > map_type2; - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_stdhash_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::hash> - >::type - > map_type2; - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_hash128_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef hash128::make hash; - typedef hash128::cmp compare; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::hash< hash128::make > - , co::compare< hash128::cmp > - >::type - > map_type2; - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_nohash_5_3() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item > map_type; - - test_rcu(5, 3); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_stdhash_5_3() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - - test_rcu(5, 3); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_nohash_5_3_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(5, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::back_off< cds::backoff::empty > - >::type - > map_type2; - test_rcu(5, 3); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_stdhash_5_3_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(5, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::back_off< cds::backoff::empty > - ,co::hash< std::hash> - >::type - > map_type2; - test_rcu(5, 3); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_hash128_4_3() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_rcu(4, 3); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_shb_hash128_4_3_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - typedef cc::multilevel_hashmap::stat<> stat; - typedef co::v::sequential_consistent memory_model; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - , co::stat< cc::multilevel_hashmap::stat<>> - , co::memory_model< co::v::sequential_consistent > - >::type - > map_type2; - test_rcu(4, 3); -#endif - } - -} // namespace map diff --git a/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_sht.cpp b/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_sht.cpp deleted file mode 100644 index 91f3d555..00000000 --- a/tests/test-hdr/map/hdr_multilevel_hashmap_rcu_sht.cpp +++ /dev/null @@ -1,223 +0,0 @@ -//$$CDS-header$$ - -#include "map/hdr_multilevel_hashmap.h" -#include -#include -#include "unit/print_multilevel_hashset_stat.h" - -namespace map { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - namespace { - typedef cds::urcu::gc< cds::urcu::signal_threaded<>> rcu_type; - } // namespace -#endif - - void MultiLevelHashMapHdrTest::rcu_sht_nohash() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item > map_type; - - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_stdhash() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_hash128() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_nohash_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - >::type - > map_type2; - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_stdhash_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::hash> - >::type - > map_type2; - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_hash128_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef hash128::make hash; - typedef hash128::cmp compare; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 2); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::hash< hash128::make > - , co::compare< hash128::cmp > - >::type - > map_type2; - test_rcu(4, 2); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_nohash_5_3() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item > map_type; - - test_rcu(5, 3); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_stdhash_5_3() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - - test_rcu(5, 3); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_nohash_5_3_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(5, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - , co::back_off< cds::backoff::empty > - >::type - > map_type2; - test_rcu(5, 3); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_stdhash_5_3_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef cc::multilevel_hashmap::stat<> stat; - typedef cds::backoff::empty back_off; - typedef std::hash hash; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(5, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::stat< cc::multilevel_hashmap::stat<>> - ,co::back_off< cds::backoff::empty > - ,co::hash< std::hash> - >::type - > map_type2; - test_rcu(5, 3); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_hash128_4_3() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - >::type - > map_type2; - test_rcu(4, 3); -#endif - } - - void MultiLevelHashMapHdrTest::rcu_sht_hash128_4_3_stat() - { -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - struct traits : public cc::multilevel_hashmap::traits { - typedef hash128::make hash; - typedef hash128::less less; - typedef cc::multilevel_hashmap::stat<> stat; - typedef co::v::sequential_consistent memory_model; - }; - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, traits > map_type; - test_rcu(4, 3); - - typedef cc::MultiLevelHashMap< rcu_type, size_t, Item, - typename cc::multilevel_hashmap::make_traits< - co::hash< hash128::make > - , co::less< hash128::less > - , co::stat< cc::multilevel_hashmap::stat<>> - , co::memory_model< co::v::sequential_consistent > - >::type - > map_type2; - test_rcu(4, 3); -#endif - } - -} // namespace map diff --git a/tests/test-hdr/set/hdr_multilevel_hashset.h b/tests/test-hdr/set/hdr_feldman_hashset.h similarity index 99% rename from tests/test-hdr/set/hdr_multilevel_hashset.h rename to tests/test-hdr/set/hdr_feldman_hashset.h index e61d3629..e2595706 100644 --- a/tests/test-hdr/set/hdr_multilevel_hashset.h +++ b/tests/test-hdr/set/hdr_feldman_hashset.h @@ -1,7 +1,7 @@ //$$CDS-header$$ -#ifndef CDSTEST_HDR_MULTILEVEL_HASHSET_H -#define CDSTEST_HDR_MULTILEVEL_HASHSET_H +#ifndef CDSTEST_HDR_FELDMAN_HASHSET_H +#define CDSTEST_HDR_FELDMAN_HASHSET_H #include "cppunit/cppunit_proxy.h" @@ -15,7 +15,7 @@ namespace set { namespace cc = cds::container; namespace co = cds::opt; - class MultiLevelHashSetHdrTest : public CppUnitMini::TestCase + class FeldmanHashSetHdrTest : public CppUnitMini::TestCase { template struct Arg @@ -744,7 +744,7 @@ namespace set { void rcu_sht_hash128_4_3(); void rcu_sht_hash128_4_3_stat(); - CPPUNIT_TEST_SUITE(MultiLevelHashSetHdrTest) + CPPUNIT_TEST_SUITE(FeldmanHashSetHdrTest) CPPUNIT_TEST(hp_nohash) CPPUNIT_TEST(hp_nohash_stat) CPPUNIT_TEST(hp_nohash_5_3) @@ -840,4 +840,4 @@ namespace set { } // namespace set -#endif // #ifndef CDSTEST_HDR_MULTILEVEL_HASHSET_H +#endif // #ifndef CDSTEST_HDR_FELDMAN_HASHSET_H diff --git a/tests/test-hdr/set/hdr_multilevel_hashset_dhp.cpp b/tests/test-hdr/set/hdr_feldman_hashset_dhp.cpp similarity index 52% rename from tests/test-hdr/set/hdr_multilevel_hashset_dhp.cpp rename to tests/test-hdr/set/hdr_feldman_hashset_dhp.cpp index 02989fda..ac1758d3 100644 --- a/tests/test-hdr/set/hdr_multilevel_hashset_dhp.cpp +++ b/tests/test-hdr/set/hdr_feldman_hashset_dhp.cpp @@ -1,293 +1,293 @@ //$$CDS-header$$ -#include "set/hdr_multilevel_hashset.h" -#include -#include "unit/print_multilevel_hashset_stat.h" +#include "set/hdr_feldman_hashset.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { namespace { typedef cds::gc::DHP gc_type; } // namespace - void MultiLevelHashSetHdrTest::dhp_nohash() + void FeldmanHashSetHdrTest::dhp_nohash() { typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_hp>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_hp>(4, 2); } - void MultiLevelHashSetHdrTest::dhp_stdhash() + void FeldmanHashSetHdrTest::dhp_stdhash() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_hp>(4, 2); } - void MultiLevelHashSetHdrTest::dhp_hash128() + void FeldmanHashSetHdrTest::dhp_hash128() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::less less; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_hp(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> , co::less< hash_type::less > >::type > set_type2; test_hp(4, 2); } - void MultiLevelHashSetHdrTest::dhp_nohash_stat() + void FeldmanHashSetHdrTest::dhp_nohash_stat() { typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_hp>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + , co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_hp>(4, 2); } - void MultiLevelHashSetHdrTest::dhp_stdhash_stat() + void FeldmanHashSetHdrTest::dhp_stdhash_stat() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_hp>(4, 2); } - void MultiLevelHashSetHdrTest::dhp_hash128_stat() + void FeldmanHashSetHdrTest::dhp_hash128_stat() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::cmp compare; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; test_hp(4, 2); } - void MultiLevelHashSetHdrTest::dhp_nohash_5_3() + void FeldmanHashSetHdrTest::dhp_nohash_5_3() { typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_hp>(5, 3); } - void MultiLevelHashSetHdrTest::dhp_stdhash_5_3() + void FeldmanHashSetHdrTest::dhp_stdhash_5_3() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_hp>(5, 3); } - void MultiLevelHashSetHdrTest::dhp_hash128_4_3() + void FeldmanHashSetHdrTest::dhp_hash128_4_3() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef co::v::sequential_consistent memory_model; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> ,co::memory_model< co::v::sequential_consistent > >::type > set_type2; test_hp(4, 3); } - void MultiLevelHashSetHdrTest::dhp_nohash_5_3_stat() + void FeldmanHashSetHdrTest::dhp_nohash_5_3_stat() { typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_hp>(5, 3); } - void MultiLevelHashSetHdrTest::dhp_stdhash_5_3_stat() + void FeldmanHashSetHdrTest::dhp_stdhash_5_3_stat() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_hp>(5, 3); } - void MultiLevelHashSetHdrTest::dhp_hash128_4_3_stat() + void FeldmanHashSetHdrTest::dhp_hash128_4_3_stat() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + , co::stat< cc::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_multilevel_hashset_hp.cpp b/tests/test-hdr/set/hdr_feldman_hashset_hp.cpp similarity index 52% rename from tests/test-hdr/set/hdr_multilevel_hashset_hp.cpp rename to tests/test-hdr/set/hdr_feldman_hashset_hp.cpp index 11e6f160..724f9d8e 100644 --- a/tests/test-hdr/set/hdr_multilevel_hashset_hp.cpp +++ b/tests/test-hdr/set/hdr_feldman_hashset_hp.cpp @@ -1,293 +1,293 @@ //$$CDS-header$$ -#include "set/hdr_multilevel_hashset.h" -#include -#include "unit/print_multilevel_hashset_stat.h" +#include "set/hdr_feldman_hashset.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { namespace { typedef cds::gc::HP gc_type; } // namespace - void MultiLevelHashSetHdrTest::hp_nohash() + void FeldmanHashSetHdrTest::hp_nohash() { typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_hp>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_hp>(4, 2); } - void MultiLevelHashSetHdrTest::hp_stdhash() + void FeldmanHashSetHdrTest::hp_stdhash() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_hp>(4, 2); } - void MultiLevelHashSetHdrTest::hp_hash128() + void FeldmanHashSetHdrTest::hp_hash128() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::less less; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_hp(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> , co::less< hash_type::less > >::type > set_type2; test_hp(4, 2); } - void MultiLevelHashSetHdrTest::hp_nohash_stat() + void FeldmanHashSetHdrTest::hp_nohash_stat() { typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_hp>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + , co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_hp>(4, 2); } - void MultiLevelHashSetHdrTest::hp_stdhash_stat() + void FeldmanHashSetHdrTest::hp_stdhash_stat() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_hp>(4, 2); } - void MultiLevelHashSetHdrTest::hp_hash128_stat() + void FeldmanHashSetHdrTest::hp_hash128_stat() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::cmp compare; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; test_hp(4, 2); } - void MultiLevelHashSetHdrTest::hp_nohash_5_3() + void FeldmanHashSetHdrTest::hp_nohash_5_3() { typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_hp>(5, 3); } - void MultiLevelHashSetHdrTest::hp_stdhash_5_3() + void FeldmanHashSetHdrTest::hp_stdhash_5_3() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_hp>(5, 3); } - void MultiLevelHashSetHdrTest::hp_hash128_4_3() + void FeldmanHashSetHdrTest::hp_hash128_4_3() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef co::v::sequential_consistent memory_model; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> ,co::memory_model< co::v::sequential_consistent > >::type > set_type2; test_hp(4, 3); } - void MultiLevelHashSetHdrTest::hp_nohash_5_3_stat() + void FeldmanHashSetHdrTest::hp_nohash_5_3_stat() { typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_hp>(5, 3); } - void MultiLevelHashSetHdrTest::hp_stdhash_5_3_stat() + void FeldmanHashSetHdrTest::hp_stdhash_5_3_stat() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_hp>(5, 3); } - void MultiLevelHashSetHdrTest::hp_hash128_4_3_stat() + void FeldmanHashSetHdrTest::hp_hash128_4_3_stat() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef cc::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< gc_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + , co::stat< cc::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type @@ -298,4 +298,4 @@ namespace set { } // namespace set -CPPUNIT_TEST_SUITE_REGISTRATION(set::MultiLevelHashSetHdrTest); +CPPUNIT_TEST_SUITE_REGISTRATION(set::FeldmanHashSetHdrTest); diff --git a/tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpb.cpp b/tests/test-hdr/set/hdr_feldman_hashset_rcu_gpb.cpp similarity index 52% rename from tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpb.cpp rename to tests/test-hdr/set/hdr_feldman_hashset_rcu_gpb.cpp index b44bb6ec..0eacbc44 100644 --- a/tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpb.cpp +++ b/tests/test-hdr/set/hdr_feldman_hashset_rcu_gpb.cpp @@ -1,294 +1,294 @@ //$$CDS-header$$ -#include "set/hdr_multilevel_hashset.h" +#include "set/hdr_feldman_hashset.h" #include -#include -#include "unit/print_multilevel_hashset_stat.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { namespace { typedef cds::urcu::gc> rcu_type; } // namespace - void MultiLevelHashSetHdrTest::rcu_gpb_nohash() + void FeldmanHashSetHdrTest::rcu_gpb_nohash() { typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpb_stdhash() + void FeldmanHashSetHdrTest::rcu_gpb_stdhash() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpb_hash128() + void FeldmanHashSetHdrTest::rcu_gpb_hash128() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::less less; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_rcu(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> , co::less< hash_type::less > >::type > set_type2; test_rcu(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpb_nohash_stat() + void FeldmanHashSetHdrTest::rcu_gpb_nohash_stat() { typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + , co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpb_stdhash_stat() + void FeldmanHashSetHdrTest::rcu_gpb_stdhash_stat() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpb_hash128_stat() + void FeldmanHashSetHdrTest::rcu_gpb_hash128_stat() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::cmp compare; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; test_rcu(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpb_nohash_5_3() + void FeldmanHashSetHdrTest::rcu_gpb_nohash_5_3() { typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpb_stdhash_5_3() + void FeldmanHashSetHdrTest::rcu_gpb_stdhash_5_3() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpb_hash128_4_3() + void FeldmanHashSetHdrTest::rcu_gpb_hash128_4_3() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef co::v::sequential_consistent memory_model; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> ,co::memory_model< co::v::sequential_consistent > >::type > set_type2; test_rcu(4, 3); } - void MultiLevelHashSetHdrTest::rcu_gpb_nohash_5_3_stat() + void FeldmanHashSetHdrTest::rcu_gpb_nohash_5_3_stat() { typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpb_stdhash_5_3_stat() + void FeldmanHashSetHdrTest::rcu_gpb_stdhash_5_3_stat() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpb_hash128_4_3_stat() + void FeldmanHashSetHdrTest::rcu_gpb_hash128_4_3_stat() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + , co::stat< cc::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpi.cpp b/tests/test-hdr/set/hdr_feldman_hashset_rcu_gpi.cpp similarity index 52% rename from tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpi.cpp rename to tests/test-hdr/set/hdr_feldman_hashset_rcu_gpi.cpp index 946a5fe3..50b51b10 100644 --- a/tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpi.cpp +++ b/tests/test-hdr/set/hdr_feldman_hashset_rcu_gpi.cpp @@ -1,294 +1,294 @@ //$$CDS-header$$ -#include "set/hdr_multilevel_hashset.h" +#include "set/hdr_feldman_hashset.h" #include -#include -#include "unit/print_multilevel_hashset_stat.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { namespace { typedef cds::urcu::gc> rcu_type; } // namespace - void MultiLevelHashSetHdrTest::rcu_gpi_nohash() + void FeldmanHashSetHdrTest::rcu_gpi_nohash() { typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpi_stdhash() + void FeldmanHashSetHdrTest::rcu_gpi_stdhash() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpi_hash128() + void FeldmanHashSetHdrTest::rcu_gpi_hash128() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::less less; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_rcu(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> , co::less< hash_type::less > >::type > set_type2; test_rcu(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpi_nohash_stat() + void FeldmanHashSetHdrTest::rcu_gpi_nohash_stat() { typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + , co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpi_stdhash_stat() + void FeldmanHashSetHdrTest::rcu_gpi_stdhash_stat() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpi_hash128_stat() + void FeldmanHashSetHdrTest::rcu_gpi_hash128_stat() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::cmp compare; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; test_rcu(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpi_nohash_5_3() + void FeldmanHashSetHdrTest::rcu_gpi_nohash_5_3() { typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpi_stdhash_5_3() + void FeldmanHashSetHdrTest::rcu_gpi_stdhash_5_3() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpi_hash128_4_3() + void FeldmanHashSetHdrTest::rcu_gpi_hash128_4_3() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef co::v::sequential_consistent memory_model; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> ,co::memory_model< co::v::sequential_consistent > >::type > set_type2; test_rcu(4, 3); } - void MultiLevelHashSetHdrTest::rcu_gpi_nohash_5_3_stat() + void FeldmanHashSetHdrTest::rcu_gpi_nohash_5_3_stat() { typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpi_stdhash_5_3_stat() + void FeldmanHashSetHdrTest::rcu_gpi_stdhash_5_3_stat() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpi_hash128_4_3_stat() + void FeldmanHashSetHdrTest::rcu_gpi_hash128_4_3_stat() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + , co::stat< cc::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpt.cpp b/tests/test-hdr/set/hdr_feldman_hashset_rcu_gpt.cpp similarity index 52% rename from tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpt.cpp rename to tests/test-hdr/set/hdr_feldman_hashset_rcu_gpt.cpp index a209533b..620a8ee7 100644 --- a/tests/test-hdr/set/hdr_multilevel_hashset_rcu_gpt.cpp +++ b/tests/test-hdr/set/hdr_feldman_hashset_rcu_gpt.cpp @@ -1,294 +1,294 @@ //$$CDS-header$$ -#include "set/hdr_multilevel_hashset.h" +#include "set/hdr_feldman_hashset.h" #include -#include -#include "unit/print_multilevel_hashset_stat.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { namespace { typedef cds::urcu::gc> rcu_type; } // namespace - void MultiLevelHashSetHdrTest::rcu_gpt_nohash() + void FeldmanHashSetHdrTest::rcu_gpt_nohash() { typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpt_stdhash() + void FeldmanHashSetHdrTest::rcu_gpt_stdhash() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpt_hash128() + void FeldmanHashSetHdrTest::rcu_gpt_hash128() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::less less; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_rcu(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> , co::less< hash_type::less > >::type > set_type2; test_rcu(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpt_nohash_stat() + void FeldmanHashSetHdrTest::rcu_gpt_nohash_stat() { typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + , co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpt_stdhash_stat() + void FeldmanHashSetHdrTest::rcu_gpt_stdhash_stat() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpt_hash128_stat() + void FeldmanHashSetHdrTest::rcu_gpt_hash128_stat() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::cmp compare; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; test_rcu(4, 2); } - void MultiLevelHashSetHdrTest::rcu_gpt_nohash_5_3() + void FeldmanHashSetHdrTest::rcu_gpt_nohash_5_3() { typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpt_stdhash_5_3() + void FeldmanHashSetHdrTest::rcu_gpt_stdhash_5_3() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpt_hash128_4_3() + void FeldmanHashSetHdrTest::rcu_gpt_hash128_4_3() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef co::v::sequential_consistent memory_model; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> ,co::memory_model< co::v::sequential_consistent > >::type > set_type2; test_rcu(4, 3); } - void MultiLevelHashSetHdrTest::rcu_gpt_nohash_5_3_stat() + void FeldmanHashSetHdrTest::rcu_gpt_nohash_5_3_stat() { typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpt_stdhash_5_3_stat() + void FeldmanHashSetHdrTest::rcu_gpt_stdhash_5_3_stat() { typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void MultiLevelHashSetHdrTest::rcu_gpt_hash128_4_3_stat() + void FeldmanHashSetHdrTest::rcu_gpt_hash128_4_3_stat() { typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + , co::stat< cc::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_multilevel_hashset_rcu_shb.cpp b/tests/test-hdr/set/hdr_feldman_hashset_rcu_shb.cpp similarity index 55% rename from tests/test-hdr/set/hdr_multilevel_hashset_rcu_shb.cpp rename to tests/test-hdr/set/hdr_feldman_hashset_rcu_shb.cpp index eaf261c2..67811de4 100644 --- a/tests/test-hdr/set/hdr_multilevel_hashset_rcu_shb.cpp +++ b/tests/test-hdr/set/hdr_feldman_hashset_rcu_shb.cpp @@ -1,9 +1,9 @@ //$$CDS-header$$ -#include "set/hdr_multilevel_hashset.h" +#include "set/hdr_feldman_hashset.h" #include -#include -#include "unit/print_multilevel_hashset_stat.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED @@ -12,73 +12,73 @@ namespace set { } // namespace #endif - void MultiLevelHashSetHdrTest::rcu_shb_nohash() + void FeldmanHashSetHdrTest::rcu_shb_nohash() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_rcu>(4, 2); #endif } - void MultiLevelHashSetHdrTest::rcu_shb_stdhash() + void FeldmanHashSetHdrTest::rcu_shb_stdhash() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_rcu>(4, 2); #endif } - void MultiLevelHashSetHdrTest::rcu_shb_hash128() + void FeldmanHashSetHdrTest::rcu_shb_hash128() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::less less; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_rcu(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> , co::less< hash_type::less > >::type > set_type2; @@ -86,79 +86,79 @@ namespace set { #endif } - void MultiLevelHashSetHdrTest::rcu_shb_nohash_stat() + void FeldmanHashSetHdrTest::rcu_shb_nohash_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + , co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); #endif } - void MultiLevelHashSetHdrTest::rcu_shb_stdhash_stat() + void FeldmanHashSetHdrTest::rcu_shb_stdhash_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); #endif } - void MultiLevelHashSetHdrTest::rcu_shb_hash128_stat() + void FeldmanHashSetHdrTest::rcu_shb_hash128_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::cmp compare; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; @@ -166,73 +166,73 @@ namespace set { #endif } - void MultiLevelHashSetHdrTest::rcu_shb_nohash_5_3() + void FeldmanHashSetHdrTest::rcu_shb_nohash_5_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_rcu>(5, 3); #endif } - void MultiLevelHashSetHdrTest::rcu_shb_stdhash_5_3() + void FeldmanHashSetHdrTest::rcu_shb_stdhash_5_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_rcu>(5, 3); #endif } - void MultiLevelHashSetHdrTest::rcu_shb_hash128_4_3() + void FeldmanHashSetHdrTest::rcu_shb_hash128_4_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef co::v::sequential_consistent memory_model; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> ,co::memory_model< co::v::sequential_consistent > >::type > set_type2; @@ -240,80 +240,80 @@ namespace set { #endif } - void MultiLevelHashSetHdrTest::rcu_shb_nohash_5_3_stat() + void FeldmanHashSetHdrTest::rcu_shb_nohash_5_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); #endif } - void MultiLevelHashSetHdrTest::rcu_shb_stdhash_5_3_stat() + void FeldmanHashSetHdrTest::rcu_shb_stdhash_5_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); #endif } - void MultiLevelHashSetHdrTest::rcu_shb_hash128_4_3_stat() + void FeldmanHashSetHdrTest::rcu_shb_hash128_4_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + , co::stat< cc::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_multilevel_hashset_rcu_sht.cpp b/tests/test-hdr/set/hdr_feldman_hashset_rcu_sht.cpp similarity index 55% rename from tests/test-hdr/set/hdr_multilevel_hashset_rcu_sht.cpp rename to tests/test-hdr/set/hdr_feldman_hashset_rcu_sht.cpp index 9147939c..1a2100a1 100644 --- a/tests/test-hdr/set/hdr_multilevel_hashset_rcu_sht.cpp +++ b/tests/test-hdr/set/hdr_feldman_hashset_rcu_sht.cpp @@ -1,9 +1,9 @@ //$$CDS-header$$ -#include "set/hdr_multilevel_hashset.h" +#include "set/hdr_feldman_hashset.h" #include -#include -#include "unit/print_multilevel_hashset_stat.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED @@ -12,73 +12,73 @@ namespace set { } // namespace #endif - void MultiLevelHashSetHdrTest::rcu_sht_nohash() + void FeldmanHashSetHdrTest::rcu_sht_nohash() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_rcu>(4, 2); #endif } - void MultiLevelHashSetHdrTest::rcu_sht_stdhash() + void FeldmanHashSetHdrTest::rcu_sht_stdhash() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_rcu>(4, 2); #endif } - void MultiLevelHashSetHdrTest::rcu_sht_hash128() + void FeldmanHashSetHdrTest::rcu_sht_hash128() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::less less; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_rcu(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> , co::less< hash_type::less > >::type > set_type2; @@ -86,79 +86,79 @@ namespace set { #endif } - void MultiLevelHashSetHdrTest::rcu_sht_nohash_stat() + void FeldmanHashSetHdrTest::rcu_sht_nohash_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits : public cc::multilevel_hashset::traits + struct traits : public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + , co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); #endif } - void MultiLevelHashSetHdrTest::rcu_sht_stdhash_stat() + void FeldmanHashSetHdrTest::rcu_sht_stdhash_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); #endif } - void MultiLevelHashSetHdrTest::rcu_sht_hash128_stat() + void FeldmanHashSetHdrTest::rcu_sht_hash128_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef hash128::cmp compare; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 2); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; @@ -166,73 +166,73 @@ namespace set { #endif } - void MultiLevelHashSetHdrTest::rcu_sht_nohash_5_3() + void FeldmanHashSetHdrTest::rcu_sht_nohash_5_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> >::type > set_type2; test_rcu>(5, 3); #endif } - void MultiLevelHashSetHdrTest::rcu_sht_stdhash_5_3() + void FeldmanHashSetHdrTest::rcu_sht_stdhash_5_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> >::type > set_type2; test_rcu>(5, 3); #endif } - void MultiLevelHashSetHdrTest::rcu_sht_hash128_4_3() + void FeldmanHashSetHdrTest::rcu_sht_hash128_4_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; typedef co::v::sequential_consistent memory_model; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> ,co::memory_model< co::v::sequential_consistent > >::type > set_type2; @@ -240,80 +240,80 @@ namespace set { #endif } - void MultiLevelHashSetHdrTest::rcu_sht_nohash_5_3_stat() + void FeldmanHashSetHdrTest::rcu_sht_nohash_5_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_key hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_key> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_key> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); #endif } - void MultiLevelHashSetHdrTest::rcu_sht_stdhash_5_3_stat() + void FeldmanHashSetHdrTest::rcu_sht_stdhash_5_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - ,co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + ,co::stat< cc::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); #endif } - void MultiLevelHashSetHdrTest::rcu_sht_hash128_4_3_stat() + void FeldmanHashSetHdrTest::rcu_sht_hash128_4_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public cc::multilevel_hashset::traits + struct traits: public cc::feldman_hashset::traits { typedef get_hash hash_accessor; - typedef cc::multilevel_hashset::stat<> stat; + typedef cc::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef cc::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef cc::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef cc::MultiLevelHashSet< + typedef cc::FeldmanHashSet< rcu_type, Item, - typename cc::multilevel_hashset::make_traits< - cc::multilevel_hashset::hash_accessor< get_hash> - , co::stat< cc::multilevel_hashset::stat<>> + typename cc::feldman_hashset::make_traits< + cc::feldman_hashset::hash_accessor< get_hash> + , co::stat< cc::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset.h b/tests/test-hdr/set/hdr_intrusive_feldman_hashset.h similarity index 98% rename from tests/test-hdr/set/hdr_intrusive_multilevel_hashset.h rename to tests/test-hdr/set/hdr_intrusive_feldman_hashset.h index 551fd9b7..dd7b9d31 100644 --- a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset.h +++ b/tests/test-hdr/set/hdr_intrusive_feldman_hashset.h @@ -1,7 +1,7 @@ //$$CDS-header$$ -#ifndef CDSTEST_HDR_INTRUSIVE_MULTILEVEL_HASHSET_H -#define CDSTEST_HDR_INTRUSIVE_MULTILEVEL_HASHSET_H +#ifndef CDSTEST_HDR_INTRUSIVE_FELDMAN_HASHSET_H +#define CDSTEST_HDR_INTRUSIVE_FELDMAN_HASHSET_H #include "cppunit/cppunit_proxy.h" @@ -15,7 +15,7 @@ namespace set { namespace ci = cds::intrusive; namespace co = cds::opt; - class IntrusiveMultiLevelHashSetHdrTest: public CppUnitMini::TestCase + class IntrusiveFeldmanHashSetHdrTest: public CppUnitMini::TestCase { template struct Item @@ -689,7 +689,7 @@ namespace set { void rcu_sht_hash128_4_3(); void rcu_sht_hash128_4_3_stat(); - CPPUNIT_TEST_SUITE(IntrusiveMultiLevelHashSetHdrTest) + CPPUNIT_TEST_SUITE(IntrusiveFeldmanHashSetHdrTest) CPPUNIT_TEST(hp_nohash) CPPUNIT_TEST(hp_nohash_stat) CPPUNIT_TEST(hp_nohash_5_3) @@ -786,4 +786,4 @@ namespace set { }; } // namespace set -#endif // #ifndef CDSTEST_HDR_INTRUSIVE_MULTILEVEL_HASHSET_H +#endif // #ifndef CDSTEST_HDR_INTRUSIVE_FELDMAN_HASHSET_H diff --git a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_dhp.cpp b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_dhp.cpp similarity index 56% rename from tests/test-hdr/set/hdr_intrusive_multilevel_hashset_dhp.cpp rename to tests/test-hdr/set/hdr_intrusive_feldman_hashset_dhp.cpp index 5c0d5b5a..d1ddcc60 100644 --- a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_dhp.cpp +++ b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_dhp.cpp @@ -1,81 +1,81 @@ //$$CDS-header$$ -#include "set/hdr_intrusive_multilevel_hashset.h" -#include -#include "unit/print_multilevel_hashset_stat.h" +#include "set/hdr_intrusive_feldman_hashset.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { namespace { typedef cds::gc::DHP gc_type; } // namespace - void IntrusiveMultiLevelHashSetHdrTest::dhp_nohash() + void IntrusiveFeldmanHashSetHdrTest::dhp_nohash() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_hp>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; test_hp>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_stdhash() + void IntrusiveFeldmanHashSetHdrTest::dhp_stdhash() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; test_hp>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_hash128() + void IntrusiveFeldmanHashSetHdrTest::dhp_hash128() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::less less; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_hp(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > , ci::opt::less< hash_type::less > >::type @@ -83,153 +83,153 @@ namespace set { test_hp(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_nohash_stat() + void IntrusiveFeldmanHashSetHdrTest::dhp_nohash_stat() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_hp>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_hp>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_stdhash_stat() + void IntrusiveFeldmanHashSetHdrTest::dhp_stdhash_stat() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_hp>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_hash128_stat() + void IntrusiveFeldmanHashSetHdrTest::dhp_hash128_stat() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::cmp compare; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; test_hp(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_nohash_5_3() + void IntrusiveFeldmanHashSetHdrTest::dhp_nohash_5_3() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_hp>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; test_hp>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_stdhash_5_3() + void IntrusiveFeldmanHashSetHdrTest::dhp_stdhash_5_3() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; test_hp>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_hash128_4_3() + void IntrusiveFeldmanHashSetHdrTest::dhp_hash128_4_3() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef co::v::sequential_consistent memory_model; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > ,co::memory_model< co::v::sequential_consistent > >::type @@ -237,81 +237,81 @@ namespace set { test_hp(4, 3); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_nohash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::dhp_nohash_5_3_stat() { typedef size_t key_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_hp>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_stdhash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::dhp_stdhash_5_3_stat() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_hp>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::dhp_hash128_4_3_stat() + void IntrusiveFeldmanHashSetHdrTest::dhp_hash128_4_3_stat() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_hp.cpp b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_hp.cpp similarity index 56% rename from tests/test-hdr/set/hdr_intrusive_multilevel_hashset_hp.cpp rename to tests/test-hdr/set/hdr_intrusive_feldman_hashset_hp.cpp index 341204a2..8e5117e4 100644 --- a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_hp.cpp +++ b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_hp.cpp @@ -1,81 +1,81 @@ //$$CDS-header$$ -#include "set/hdr_intrusive_multilevel_hashset.h" -#include -#include "unit/print_multilevel_hashset_stat.h" +#include "set/hdr_intrusive_feldman_hashset.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { namespace { typedef cds::gc::HP gc_type; } // namespace - void IntrusiveMultiLevelHashSetHdrTest::hp_nohash() + void IntrusiveFeldmanHashSetHdrTest::hp_nohash() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_hp>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; test_hp>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::hp_stdhash() + void IntrusiveFeldmanHashSetHdrTest::hp_stdhash() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; test_hp>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::hp_hash128() + void IntrusiveFeldmanHashSetHdrTest::hp_hash128() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::less less; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_hp(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > , ci::opt::less< hash_type::less > >::type @@ -83,153 +83,153 @@ namespace set { test_hp(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::hp_nohash_stat() + void IntrusiveFeldmanHashSetHdrTest::hp_nohash_stat() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_hp>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_hp>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::hp_stdhash_stat() + void IntrusiveFeldmanHashSetHdrTest::hp_stdhash_stat() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_hp>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::hp_hash128_stat() + void IntrusiveFeldmanHashSetHdrTest::hp_hash128_stat() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::cmp compare; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; test_hp(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::hp_nohash_5_3() + void IntrusiveFeldmanHashSetHdrTest::hp_nohash_5_3() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_hp>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; test_hp>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::hp_stdhash_5_3() + void IntrusiveFeldmanHashSetHdrTest::hp_stdhash_5_3() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; test_hp>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::hp_hash128_4_3() + void IntrusiveFeldmanHashSetHdrTest::hp_hash128_4_3() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef co::v::sequential_consistent memory_model; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > ,co::memory_model< co::v::sequential_consistent > >::type @@ -237,81 +237,81 @@ namespace set { test_hp(4, 3); } - void IntrusiveMultiLevelHashSetHdrTest::hp_nohash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::hp_nohash_5_3_stat() { typedef size_t key_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_hp>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::hp_stdhash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::hp_stdhash_5_3_stat() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_hp>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_hp>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::hp_hash128_4_3_stat() + void IntrusiveFeldmanHashSetHdrTest::hp_hash128_4_3_stat() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef ci::MultiLevelHashSet< gc_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< gc_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_hp(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< gc_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type @@ -321,4 +321,4 @@ namespace set { } // namespace set -CPPUNIT_TEST_SUITE_REGISTRATION(set::IntrusiveMultiLevelHashSetHdrTest); +CPPUNIT_TEST_SUITE_REGISTRATION(set::IntrusiveFeldmanHashSetHdrTest); diff --git a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpb.cpp b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpb.cpp similarity index 56% rename from tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpb.cpp rename to tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpb.cpp index 72f02b8f..c0aa5573 100644 --- a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpb.cpp +++ b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpb.cpp @@ -1,82 +1,82 @@ //$$CDS-header$$ -#include "set/hdr_intrusive_multilevel_hashset.h" +#include "set/hdr_intrusive_feldman_hashset.h" #include -#include -#include "unit/print_multilevel_hashset_stat.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { namespace { typedef cds::urcu::gc> rcu_type; } // namespace - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_nohash() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_nohash() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_stdhash() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_stdhash() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_hash128() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_hash128() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::less less; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_rcu(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > , ci::opt::less< hash_type::less > >::type @@ -84,153 +84,153 @@ namespace set { test_rcu(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_nohash_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_nohash_stat() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_stdhash_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_stdhash_stat() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_hash128_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_hash128_stat() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::cmp compare; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; test_rcu(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_nohash_5_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_nohash_5_3() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_stdhash_5_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_stdhash_5_3() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_hash128_4_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_hash128_4_3() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef co::v::sequential_consistent memory_model; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > ,co::memory_model< co::v::sequential_consistent > >::type @@ -238,81 +238,81 @@ namespace set { test_rcu(4, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_nohash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_nohash_5_3_stat() { typedef size_t key_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_stdhash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_stdhash_5_3_stat() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpb_hash128_4_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpb_hash128_4_3_stat() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpi.cpp b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpi.cpp similarity index 56% rename from tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpi.cpp rename to tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpi.cpp index f61730f6..f1b0f430 100644 --- a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpi.cpp +++ b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpi.cpp @@ -1,82 +1,82 @@ //$$CDS-header$$ -#include "set/hdr_intrusive_multilevel_hashset.h" +#include "set/hdr_intrusive_feldman_hashset.h" #include -#include -#include "unit/print_multilevel_hashset_stat.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { namespace { typedef cds::urcu::gc> rcu_type; } // namespace - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_nohash() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_nohash() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_stdhash() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_stdhash() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_hash128() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_hash128() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::less less; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_rcu(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > , ci::opt::less< hash_type::less > >::type @@ -84,153 +84,153 @@ namespace set { test_rcu(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_nohash_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_nohash_stat() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_stdhash_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_stdhash_stat() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_hash128_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_hash128_stat() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::cmp compare; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; test_rcu(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_nohash_5_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_nohash_5_3() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_stdhash_5_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_stdhash_5_3() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_hash128_4_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_hash128_4_3() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef co::v::sequential_consistent memory_model; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > ,co::memory_model< co::v::sequential_consistent > >::type @@ -238,81 +238,81 @@ namespace set { test_rcu(4, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_nohash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_nohash_5_3_stat() { typedef size_t key_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_stdhash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_stdhash_5_3_stat() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpi_hash128_4_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpi_hash128_4_3_stat() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpt.cpp b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpt.cpp similarity index 56% rename from tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpt.cpp rename to tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpt.cpp index da4e9d52..222fe31d 100644 --- a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_gpt.cpp +++ b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_gpt.cpp @@ -1,82 +1,82 @@ //$$CDS-header$$ -#include "set/hdr_intrusive_multilevel_hashset.h" +#include "set/hdr_intrusive_feldman_hashset.h" #include -#include -#include "unit/print_multilevel_hashset_stat.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { namespace { typedef cds::urcu::gc> rcu_type; } // namespace - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_nohash() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_nohash() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_stdhash() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_stdhash() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_hash128() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_hash128() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::less less; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_rcu(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > , ci::opt::less< hash_type::less > >::type @@ -84,153 +84,153 @@ namespace set { test_rcu(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_nohash_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_nohash_stat() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_stdhash_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_stdhash_stat() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_hash128_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_hash128_stat() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::cmp compare; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; test_rcu(4, 2); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_nohash_5_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_nohash_5_3() { typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_stdhash_5_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_stdhash_5_3() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_hash128_4_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_hash128_4_3() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef co::v::sequential_consistent memory_model; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > ,co::memory_model< co::v::sequential_consistent > >::type @@ -238,81 +238,81 @@ namespace set { test_rcu(4, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_nohash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_nohash_5_3_stat() { typedef size_t key_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_stdhash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_stdhash_5_3_stat() { typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); } - void IntrusiveMultiLevelHashSetHdrTest::rcu_gpt_hash128_4_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_gpt_hash128_4_3_stat() { typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_shb.cpp b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_shb.cpp similarity index 58% rename from tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_shb.cpp rename to tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_shb.cpp index b1236812..317b4390 100644 --- a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_shb.cpp +++ b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_shb.cpp @@ -1,9 +1,9 @@ //$$CDS-header$$ -#include "set/hdr_intrusive_multilevel_hashset.h" +#include "set/hdr_intrusive_feldman_hashset.h" #include -#include -#include "unit/print_multilevel_hashset_stat.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED @@ -12,25 +12,25 @@ namespace set { } // namespace #endif - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_nohash() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_nohash() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; @@ -38,25 +38,25 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_stdhash() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_stdhash() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; @@ -64,26 +64,26 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_hash128() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_hash128() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::less less; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_rcu(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > , ci::opt::less< hash_type::less > >::type @@ -92,85 +92,85 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_nohash_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_nohash_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_stdhash_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_stdhash_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_hash128_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_hash128_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::cmp compare; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; @@ -178,25 +178,25 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_nohash_5_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_nohash_5_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; @@ -204,25 +204,25 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_stdhash_5_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_stdhash_5_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; @@ -230,26 +230,26 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_hash128_4_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_hash128_4_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef co::v::sequential_consistent memory_model; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > ,co::memory_model< co::v::sequential_consistent > >::type @@ -258,86 +258,86 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_nohash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_nohash_5_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_stdhash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_stdhash_5_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_shb_hash128_4_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_shb_hash128_4_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_sht.cpp b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_sht.cpp similarity index 58% rename from tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_sht.cpp rename to tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_sht.cpp index 6ade6cf7..67e181d5 100644 --- a/tests/test-hdr/set/hdr_intrusive_multilevel_hashset_rcu_sht.cpp +++ b/tests/test-hdr/set/hdr_intrusive_feldman_hashset_rcu_sht.cpp @@ -1,9 +1,9 @@ //$$CDS-header$$ -#include "set/hdr_intrusive_multilevel_hashset.h" +#include "set/hdr_intrusive_feldman_hashset.h" #include -#include -#include "unit/print_multilevel_hashset_stat.h" +#include +#include "unit/print_feldman_hashset_stat.h" namespace set { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED @@ -12,25 +12,25 @@ namespace set { } // namespace #endif - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_nohash() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_nohash() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; @@ -38,25 +38,25 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_stdhash() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_stdhash() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; @@ -64,26 +64,26 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_hash128() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_hash128() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::less less; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash128!!!" ); test_rcu(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > , ci::opt::less< hash_type::less > >::type @@ -92,85 +92,85 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_nohash_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_nohash_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_stdhash_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_stdhash_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(4, 2); #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_hash128_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_hash128_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef hash128::cmp compare; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 2); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> ,co::compare< hash128::cmp > >::type > set_type2; @@ -178,25 +178,25 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_nohash_5_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_nohash_5_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits : public ci::multilevel_hashset::traits + struct traits : public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!"); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > >::type > set_type2; @@ -204,25 +204,25 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_stdhash_5_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_stdhash_5_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > >::type > set_type2; @@ -230,26 +230,26 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_hash128_4_3() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_hash128_4_3() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; typedef co::v::sequential_consistent memory_model; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > ,co::memory_model< co::v::sequential_consistent > >::type @@ -258,86 +258,86 @@ namespace set { #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_nohash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_nohash_5_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t key_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_key hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_key> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_key> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_stdhash_5_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_stdhash_5_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef size_t hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, size_t>::value, "set::hash_type != size_t!!!" ); test_rcu>(5, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - ,co::stat< ci::multilevel_hashset::stat<>> + ,co::stat< ci::feldman_hashset::stat<>> >::type > set_type2; test_rcu>(5, 3); #endif } - void IntrusiveMultiLevelHashSetHdrTest::rcu_sht_hash128_4_3_stat() + void IntrusiveFeldmanHashSetHdrTest::rcu_sht_hash128_4_3_stat() { #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED typedef hash128 hash_type; - struct traits: public ci::multilevel_hashset::traits + struct traits: public ci::feldman_hashset::traits { typedef get_hash hash_accessor; typedef item_disposer disposer; - typedef ci::multilevel_hashset::stat<> stat; + typedef ci::feldman_hashset::stat<> stat; typedef hash128::less less; typedef hash128::cmp compare; }; - typedef ci::MultiLevelHashSet< rcu_type, Item, traits > set_type; + typedef ci::FeldmanHashSet< rcu_type, Item, traits > set_type; static_assert(std::is_same< typename set_type::hash_type, hash_type>::value, "set::hash_type != hash_type!!!" ); test_rcu(4, 3); - typedef ci::MultiLevelHashSet< + typedef ci::FeldmanHashSet< rcu_type, Item, - typename ci::multilevel_hashset::make_traits< - ci::multilevel_hashset::hash_accessor< get_hash> + typename ci::feldman_hashset::make_traits< + ci::feldman_hashset::hash_accessor< get_hash> , ci::opt::disposer< item_disposer > - , co::stat< ci::multilevel_hashset::stat<>> + , co::stat< ci::feldman_hashset::stat<>> , co::less< hash_type::less > , co::compare< hash128::cmp > >::type diff --git a/tests/unit/map2/CMakeLists.txt b/tests/unit/map2/CMakeLists.txt index 454721ae..dc30aa0e 100644 --- a/tests/unit/map2/CMakeLists.txt +++ b/tests/unit/map2/CMakeLists.txt @@ -6,7 +6,7 @@ set(CDSUNIT_MAP_SOURCES map_find_int_cuckoo.cpp map_find_int_ellentree.cpp map_find_int_michael.cpp - map_find_int_multilevelhashmap.cpp + map_find_int_feldmanhashmap.cpp map_find_int_skip.cpp map_find_int_split.cpp map_find_int_striped.cpp @@ -16,7 +16,7 @@ set(CDSUNIT_MAP_SOURCES map_find_string_cuckoo.cpp map_find_string_ellentree.cpp map_find_string_michael.cpp - map_find_string_multilevelhashmap.cpp + map_find_string_feldmanhashmap.cpp map_find_string_skip.cpp map_find_string_split.cpp map_find_string_striped.cpp @@ -36,7 +36,7 @@ set(CDSUNIT_MAP_SOURCES map_insdel_func_cuckoo.cpp map_insdel_func_ellentree.cpp map_insdel_func_michael.cpp - map_insdel_func_multilevelhashmap.cpp + map_insdel_func_feldmanhashmap.cpp map_insdel_func_skip.cpp map_insdel_func_split.cpp map_insdel_func_striped.cpp @@ -45,7 +45,7 @@ set(CDSUNIT_MAP_SOURCES map_insdel_int_cuckoo.cpp map_insdel_int_ellentree.cpp map_insdel_int_michael.cpp - map_insdel_int_multilevelhashmap.cpp + map_insdel_int_feldmanhashmap.cpp map_insdel_int_skip.cpp map_insdel_int_split.cpp map_insdel_int_striped.cpp @@ -55,7 +55,7 @@ set(CDSUNIT_MAP_SOURCES map_insdel_item_int_cuckoo.cpp map_insdel_item_int_ellentree.cpp map_insdel_item_int_michael.cpp - map_insdel_item_int_multilevelhashmap.cpp + map_insdel_item_int_feldmanhashmap.cpp map_insdel_item_int_skip.cpp map_insdel_item_int_split.cpp map_insdel_item_int_striped.cpp @@ -64,7 +64,7 @@ set(CDSUNIT_MAP_SOURCES map_insdel_item_string_cuckoo.cpp map_insdel_item_string_ellentree.cpp map_insdel_item_string_michael.cpp - map_insdel_item_string_multilevelhashmap.cpp + map_insdel_item_string_feldmanhashmap.cpp map_insdel_item_string_skip.cpp map_insdel_item_string_split.cpp map_insdel_item_string_striped.cpp @@ -73,7 +73,7 @@ set(CDSUNIT_MAP_SOURCES map_insdel_string_cuckoo.cpp map_insdel_string_ellentree.cpp map_insdel_string_michael.cpp - map_insdel_string_multilevelhashmap.cpp + map_insdel_string_feldmanhashmap.cpp map_insdel_string_skip.cpp map_insdel_string_split.cpp map_insdel_string_striped.cpp @@ -83,7 +83,7 @@ set(CDSUNIT_MAP_SOURCES map_insdelfind_cuckoo.cpp map_insdelfind_ellentree.cpp map_insdelfind_michael.cpp - map_insdelfind_multilevelhashmap.cpp + map_insdelfind_feldmanhashmap.cpp map_insdelfind_skip.cpp map_insdelfind_split.cpp map_insdelfind_striped.cpp @@ -93,7 +93,7 @@ set(CDSUNIT_MAP_SOURCES map_delodd_cuckoo.cpp map_delodd_ellentree.cpp map_delodd_michael.cpp - map_delodd_multilevelhashmap.cpp + map_delodd_feldmanhashmap.cpp map_delodd_split.cpp map_delodd_skip.cpp ) diff --git a/tests/unit/map2/map_defs.h b/tests/unit/map2/map_defs.h index 8de1ba64..b44879de 100644 --- a/tests/unit/map2/map_defs.h +++ b/tests/unit/map2/map_defs.h @@ -727,351 +727,351 @@ // ************************************************************************************** -// MultiLevelHashMap +// FeldmanHashMap // fixed-sized key - no hash function is necessary -#undef CDSUNIT_DECLARE_MultiLevelHashMap_fixed -#undef CDSUNIT_DECLARE_MultiLevelHashMap_fixed_RCU_Signal -#undef CDSUNIT_TEST_MultiLevelHashMap_fixed -#undef CDSUNIT_TEST_MultiLevelHashMap_fixed_RCU_Signal +#undef CDSUNIT_DECLARE_FeldmanHashMap_fixed +#undef CDSUNIT_DECLARE_FeldmanHashMap_fixed_RCU_Signal +#undef CDSUNIT_TEST_FeldmanHashMap_fixed +#undef CDSUNIT_TEST_FeldmanHashMap_fixed_RCU_Signal #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashMap_fixed_RCU_Signal \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_fixed) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_fixed) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_fixed_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashMap_fixed_RCU_Signal \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_fixed) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_fixed_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_fixed) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_fixed_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashMap_fixed_RCU_Signal \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_fixed) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_fixed_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_fixed) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_fixed_stat) \ + +# define CDSUNIT_TEST_FeldmanHashMap_fixed_RCU_Signal \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_fixed) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_fixed_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_fixed) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_fixed_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashMap_fixed_RCU_Signal -# define CDSUNIT_TEST_MultiLevelHashMap_fixed_RCU_Signal +# define CDSUNIT_DECLARE_FeldmanHashMap_fixed_RCU_Signal +# define CDSUNIT_TEST_FeldmanHashMap_fixed_RCU_Signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashMap_fixed \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_fixed) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_fixed) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_fixed) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_fixed) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_fixed) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_fixed_stat) \ - CDSUNIT_DECLARE_MultiLevelHashMap_fixed_RCU_Signal - -#define CDSUNIT_TEST_MultiLevelHashMap_fixed \ - CPPUNIT_TEST(MultiLevelHashMap_hp_fixed) \ - CPPUNIT_TEST(MultiLevelHashMap_hp_fixed_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_fixed) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_fixed_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_fixed) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_fixed_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_fixed) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_fixed_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_fixed) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_fixed_stat) \ - CDSUNIT_TEST_MultiLevelHashMap_fixed_RCU_Signal +#define CDSUNIT_DECLARE_FeldmanHashMap_fixed \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_fixed) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_fixed_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_fixed) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_fixed_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_fixed) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_fixed_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_fixed) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_fixed_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_fixed) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_fixed_stat) \ + CDSUNIT_DECLARE_FeldmanHashMap_fixed_RCU_Signal + +#define CDSUNIT_TEST_FeldmanHashMap_fixed \ + CPPUNIT_TEST(FeldmanHashMap_hp_fixed) \ + CPPUNIT_TEST(FeldmanHashMap_hp_fixed_stat) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_fixed) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_fixed_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_fixed) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_fixed_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_fixed) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_fixed_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_fixed) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_fixed_stat) \ + CDSUNIT_TEST_FeldmanHashMap_fixed_RCU_Signal // std::hash -#undef CDSUNIT_DECLARE_MultiLevelHashMap_stdhash -#undef CDSUNIT_DECLARE_MultiLevelHashMap_stdhash_RCU_Signal -#undef CDSUNIT_TEST_MultiLevelHashMap_stdhash -#undef CDSUNIT_TEST_MultiLevelHashMap_stdhash_RCU_Signal +#undef CDSUNIT_DECLARE_FeldmanHashMap_stdhash +#undef CDSUNIT_DECLARE_FeldmanHashMap_stdhash_RCU_Signal +#undef CDSUNIT_TEST_FeldmanHashMap_stdhash +#undef CDSUNIT_TEST_FeldmanHashMap_stdhash_RCU_Signal #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashMap_stdhash_RCU_Signal \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_stdhash) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_stdhash) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_stdhash_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashMap_stdhash_RCU_Signal \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_stdhash) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_stdhash_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_stdhash) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_stdhash_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashMap_stdhash_RCU_Signal \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_stdhash) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_stdhash) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_stdhash_stat) \ + +# define CDSUNIT_TEST_FeldmanHashMap_stdhash_RCU_Signal \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_stdhash) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_stdhash_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_stdhash) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_stdhash_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashMap_stdhash_RCU_Signal -# define CDSUNIT_TEST_MultiLevelHashMap_stdhash_RCU_Signal +# define CDSUNIT_DECLARE_FeldmanHashMap_stdhash_RCU_Signal +# define CDSUNIT_TEST_FeldmanHashMap_stdhash_RCU_Signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashMap_stdhash \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_stdhash) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_stdhash) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_stdhash) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_stdhash) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_stdhash) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_stdhash_stat) \ - CDSUNIT_DECLARE_MultiLevelHashMap_stdhash_RCU_Signal - -#define CDSUNIT_TEST_MultiLevelHashMap_stdhash \ - CPPUNIT_TEST(MultiLevelHashMap_hp_stdhash) \ - CPPUNIT_TEST(MultiLevelHashMap_hp_stdhash_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_stdhash) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_stdhash_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_stdhash) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_stdhash_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_stdhash) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_stdhash_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_stdhash) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_stdhash_stat) \ - CDSUNIT_TEST_MultiLevelHashMap_stdhash_RCU_Signal +#define CDSUNIT_DECLARE_FeldmanHashMap_stdhash \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_stdhash) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_stdhash) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_stdhash) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_stdhash) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_stdhash) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_stdhash_stat) \ + CDSUNIT_DECLARE_FeldmanHashMap_stdhash_RCU_Signal + +#define CDSUNIT_TEST_FeldmanHashMap_stdhash \ + CPPUNIT_TEST(FeldmanHashMap_hp_stdhash) \ + CPPUNIT_TEST(FeldmanHashMap_hp_stdhash_stat) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_stdhash) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_stdhash_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_stdhash) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_stdhash_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_stdhash) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_stdhash_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_stdhash) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_stdhash_stat) \ + CDSUNIT_TEST_FeldmanHashMap_stdhash_RCU_Signal // MD5 -#undef CDSUNIT_DECLARE_MultiLevelHashMap_md5 -#undef CDSUNIT_DECLARE_MultiLevelHashMap_md5_RCU_Signal -#undef CDSUNIT_TEST_MultiLevelHashMap_md5 -#undef CDSUNIT_TEST_MultiLevelHashMap_md5_RCU_Signal +#undef CDSUNIT_DECLARE_FeldmanHashMap_md5 +#undef CDSUNIT_DECLARE_FeldmanHashMap_md5_RCU_Signal +#undef CDSUNIT_TEST_FeldmanHashMap_md5 +#undef CDSUNIT_TEST_FeldmanHashMap_md5_RCU_Signal #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashMap_md5_RCU_Signal \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_md5) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_md5_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_md5) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_md5_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashMap_md5_RCU_Signal \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_md5) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_md5_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_md5) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_md5_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashMap_md5_RCU_Signal \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_md5) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_md5_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_md5) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_md5_stat) \ + +# define CDSUNIT_TEST_FeldmanHashMap_md5_RCU_Signal \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_md5) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_md5_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_md5) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_md5_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashMap_md5_RCU_Signal -# define CDSUNIT_TEST_MultiLevelHashMap_md5_RCU_Signal +# define CDSUNIT_DECLARE_FeldmanHashMap_md5_RCU_Signal +# define CDSUNIT_TEST_FeldmanHashMap_md5_RCU_Signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashMap_md5 \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_md5) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_md5_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_md5) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_md5_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_md5) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_md5_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_md5) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_md5_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_md5) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_md5_stat) \ - CDSUNIT_DECLARE_MultiLevelHashMap_md5_RCU_Signal - -#define CDSUNIT_TEST_MultiLevelHashMap_md5 \ - CPPUNIT_TEST(MultiLevelHashMap_hp_md5) \ - CPPUNIT_TEST(MultiLevelHashMap_hp_md5_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_md5) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_md5_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_md5) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_md5_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_md5) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_md5_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_md5) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_md5_stat) \ - CDSUNIT_TEST_MultiLevelHashMap_md5_RCU_Signal +#define CDSUNIT_DECLARE_FeldmanHashMap_md5 \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_md5) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_md5_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_md5) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_md5_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_md5) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_md5_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_md5) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_md5_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_md5) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_md5_stat) \ + CDSUNIT_DECLARE_FeldmanHashMap_md5_RCU_Signal + +#define CDSUNIT_TEST_FeldmanHashMap_md5 \ + CPPUNIT_TEST(FeldmanHashMap_hp_md5) \ + CPPUNIT_TEST(FeldmanHashMap_hp_md5_stat) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_md5) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_md5_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_md5) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_md5_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_md5) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_md5_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_md5) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_md5_stat) \ + CDSUNIT_TEST_FeldmanHashMap_md5_RCU_Signal // SHA256 -#undef CDSUNIT_DECLARE_MultiLevelHashMap_sha256 -#undef CDSUNIT_DECLARE_MultiLevelHashMap_sha256_RCU_Signal -#undef CDSUNIT_TEST_MultiLevelHashMap_sha256 -#undef CDSUNIT_TEST_MultiLevelHashMap_sha256_RCU_Signal +#undef CDSUNIT_DECLARE_FeldmanHashMap_sha256 +#undef CDSUNIT_DECLARE_FeldmanHashMap_sha256_RCU_Signal +#undef CDSUNIT_TEST_FeldmanHashMap_sha256 +#undef CDSUNIT_TEST_FeldmanHashMap_sha256_RCU_Signal #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashMap_sha256_RCU_Signal \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_sha256) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_sha256) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_sha256_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashMap_sha256_RCU_Signal \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_sha256) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_sha256_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_sha256) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_sha256_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashMap_sha256_RCU_Signal \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_sha256) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_sha256_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_sha256) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_sha256_stat) \ + +# define CDSUNIT_TEST_FeldmanHashMap_sha256_RCU_Signal \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_sha256) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_sha256_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_sha256) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_sha256_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashMap_sha256_RCU_Signal -# define CDSUNIT_TEST_MultiLevelHashMap_sha256_RCU_Signal +# define CDSUNIT_DECLARE_FeldmanHashMap_sha256_RCU_Signal +# define CDSUNIT_TEST_FeldmanHashMap_sha256_RCU_Signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashMap_sha256 \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_sha256) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_sha256) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_sha256) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_sha256) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_sha256) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_sha256_stat) \ - CDSUNIT_DECLARE_MultiLevelHashMap_sha256_RCU_Signal - -#define CDSUNIT_TEST_MultiLevelHashMap_sha256 \ - CPPUNIT_TEST(MultiLevelHashMap_hp_sha256) \ - CPPUNIT_TEST(MultiLevelHashMap_hp_sha256_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_sha256) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_sha256_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_sha256) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_sha256_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_sha256) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_sha256_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_sha256) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_sha256_stat) \ - CDSUNIT_TEST_MultiLevelHashMap_sha256_RCU_Signal +#define CDSUNIT_DECLARE_FeldmanHashMap_sha256 \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_sha256) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_sha256_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_sha256) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_sha256_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_sha256) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_sha256_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_sha256) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_sha256_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_sha256) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_sha256_stat) \ + CDSUNIT_DECLARE_FeldmanHashMap_sha256_RCU_Signal + +#define CDSUNIT_TEST_FeldmanHashMap_sha256 \ + CPPUNIT_TEST(FeldmanHashMap_hp_sha256) \ + CPPUNIT_TEST(FeldmanHashMap_hp_sha256_stat) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_sha256) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_sha256_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_sha256) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_sha256_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_sha256) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_sha256_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_sha256) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_sha256_stat) \ + CDSUNIT_TEST_FeldmanHashMap_sha256_RCU_Signal // CityHash - only for 64bit -#undef CDSUNIT_DECLARE_MultiLevelHashMap_city128_RCU_Signal -#undef CDSUNIT_TEST_MultiLevelHashMap_city128_RCU_Signal +#undef CDSUNIT_DECLARE_FeldmanHashMap_city128_RCU_Signal +#undef CDSUNIT_TEST_FeldmanHashMap_city128_RCU_Signal #if CDS_BUILD_BITS == 64 -#undef CDSUNIT_DECLARE_MultiLevelHashMap_city64 -#undef CDSUNIT_DECLARE_MultiLevelHashMap_city64_RCU_Signal -#undef CDSUNIT_TEST_MultiLevelHashMap_city64 -#undef CDSUNIT_TEST_MultiLevelHashMap_city64_RCU_Signal +#undef CDSUNIT_DECLARE_FeldmanHashMap_city64 +#undef CDSUNIT_DECLARE_FeldmanHashMap_city64_RCU_Signal +#undef CDSUNIT_TEST_FeldmanHashMap_city64 +#undef CDSUNIT_TEST_FeldmanHashMap_city64_RCU_Signal #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashMap_city64_RCU_Signal \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_city64) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_city64_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_city64) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_city64_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashMap_city64_RCU_Signal \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_city64) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_city64_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_city64) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_city64_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashMap_city64_RCU_Signal \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_city64) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_city64_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_city64) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_city64_stat) \ + +# define CDSUNIT_TEST_FeldmanHashMap_city64_RCU_Signal \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_city64) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_city64_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_city64) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_city64_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashMap_city64_RCU_Signal -# define CDSUNIT_TEST_MultiLevelHashMap_city64_RCU_Signal +# define CDSUNIT_DECLARE_FeldmanHashMap_city64_RCU_Signal +# define CDSUNIT_TEST_FeldmanHashMap_city64_RCU_Signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashMap_city64 \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_city64) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_city64_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_city64) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_city64_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_city64) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_city64_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_city64) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_city64_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_city64) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_city64_stat) \ - CDSUNIT_DECLARE_MultiLevelHashMap_city64_RCU_Signal - -#define CDSUNIT_TEST_MultiLevelHashMap_city64 \ - CPPUNIT_TEST(MultiLevelHashMap_hp_city64) \ - CPPUNIT_TEST(MultiLevelHashMap_hp_city64_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_city64) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_city64_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_city64) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_city64_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_city64) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_city64_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_city64) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_city64_stat) \ - CDSUNIT_TEST_MultiLevelHashMap_city64_RCU_Signal - -#undef CDSUNIT_DECLARE_MultiLevelHashMap_city128 -#undef CDSUNIT_DECLARE_MultiLevelHashMap_city128_RCU_Signal -#undef CDSUNIT_TEST_MultiLevelHashMap_city128 -#undef CDSUNIT_TEST_MultiLevelHashMap_city128_RCU_Signal +#define CDSUNIT_DECLARE_FeldmanHashMap_city64 \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_city64) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_city64_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_city64) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_city64_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_city64) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_city64_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_city64) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_city64_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_city64) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_city64_stat) \ + CDSUNIT_DECLARE_FeldmanHashMap_city64_RCU_Signal + +#define CDSUNIT_TEST_FeldmanHashMap_city64 \ + CPPUNIT_TEST(FeldmanHashMap_hp_city64) \ + CPPUNIT_TEST(FeldmanHashMap_hp_city64_stat) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_city64) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_city64_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_city64) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_city64_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_city64) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_city64_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_city64) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_city64_stat) \ + CDSUNIT_TEST_FeldmanHashMap_city64_RCU_Signal + +#undef CDSUNIT_DECLARE_FeldmanHashMap_city128 +#undef CDSUNIT_DECLARE_FeldmanHashMap_city128_RCU_Signal +#undef CDSUNIT_TEST_FeldmanHashMap_city128 +#undef CDSUNIT_TEST_FeldmanHashMap_city128_RCU_Signal #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashMap_city128_RCU_Signal \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_city128) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_shb_city128_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_city128) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_sht_city128_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashMap_city128_RCU_Signal \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_city128) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_shb_city128_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_city128) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_sht_city128_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashMap_city128_RCU_Signal \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_city128) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_shb_city128_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_city128) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_sht_city128_stat) \ + +# define CDSUNIT_TEST_FeldmanHashMap_city128_RCU_Signal \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_city128) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_shb_city128_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_city128) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_sht_city128_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashMap_city128_RCU_Signal -# define CDSUNIT_TEST_MultiLevelHashMap_city128_RCU_Signal +# define CDSUNIT_DECLARE_FeldmanHashMap_city128_RCU_Signal +# define CDSUNIT_TEST_FeldmanHashMap_city128_RCU_Signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashMap_city128 \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_city128) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_hp_city128_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_city128) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_dhp_city128_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_city128) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpi_city128_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_city128) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpb_city128_stat) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_city128) \ - TEST_CASE(tag_MultiLevelHashMap, MultiLevelHashMap_rcu_gpt_city128_stat) \ - CDSUNIT_DECLARE_MultiLevelHashMap_city128_RCU_Signal - -#define CDSUNIT_TEST_MultiLevelHashMap_city128 \ - CPPUNIT_TEST(MultiLevelHashMap_hp_city128) \ - CPPUNIT_TEST(MultiLevelHashMap_hp_city128_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_city128) \ - CPPUNIT_TEST(MultiLevelHashMap_dhp_city128_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_city128) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpi_city128_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_city128) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpb_city128_stat) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_city128) \ - CPPUNIT_TEST(MultiLevelHashMap_rcu_gpt_city128_stat) \ - CDSUNIT_TEST_MultiLevelHashMap_city128_RCU_Signal - -#define CDSUNIT_DECLARE_MultiLevelHashMap_city \ - CDSUNIT_DECLARE_MultiLevelHashMap_city64 \ - CDSUNIT_DECLARE_MultiLevelHashMap_city128 - -#define CDSUNIT_TEST_MultiLevelHashMap_city \ - CDSUNIT_TEST_MultiLevelHashMap_city64 \ - CDSUNIT_TEST_MultiLevelHashMap_city128 +#define CDSUNIT_DECLARE_FeldmanHashMap_city128 \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_city128) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_hp_city128_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_city128) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_dhp_city128_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_city128) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpi_city128_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_city128) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpb_city128_stat) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_city128) \ + TEST_CASE(tag_FeldmanHashMap, FeldmanHashMap_rcu_gpt_city128_stat) \ + CDSUNIT_DECLARE_FeldmanHashMap_city128_RCU_Signal + +#define CDSUNIT_TEST_FeldmanHashMap_city128 \ + CPPUNIT_TEST(FeldmanHashMap_hp_city128) \ + CPPUNIT_TEST(FeldmanHashMap_hp_city128_stat) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_city128) \ + CPPUNIT_TEST(FeldmanHashMap_dhp_city128_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_city128) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpi_city128_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_city128) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpb_city128_stat) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_city128) \ + CPPUNIT_TEST(FeldmanHashMap_rcu_gpt_city128_stat) \ + CDSUNIT_TEST_FeldmanHashMap_city128_RCU_Signal + +#define CDSUNIT_DECLARE_FeldmanHashMap_city \ + CDSUNIT_DECLARE_FeldmanHashMap_city64 \ + CDSUNIT_DECLARE_FeldmanHashMap_city128 + +#define CDSUNIT_TEST_FeldmanHashMap_city \ + CDSUNIT_TEST_FeldmanHashMap_city64 \ + CDSUNIT_TEST_FeldmanHashMap_city128 #else // 32bit -# define CDSUNIT_DECLARE_MultiLevelHashMap_city -# define CDSUNIT_TEST_MultiLevelHashMap_city +# define CDSUNIT_DECLARE_FeldmanHashMap_city +# define CDSUNIT_TEST_FeldmanHashMap_city #endif // #if CDS_BUILD_BITS == 64 -#undef CDSUNIT_DECLARE_MultiLevelHashMap -#undef CDSUNIT_TEST_MultiLevelHashMap - -#define CDSUNIT_DECLARE_MultiLevelHashMap \ - CDSUNIT_DECLARE_MultiLevelHashMap_fixed \ - CDSUNIT_DECLARE_MultiLevelHashMap_stdhash \ - CDSUNIT_DECLARE_MultiLevelHashMap_md5 \ - CDSUNIT_DECLARE_MultiLevelHashMap_sha256 \ - CDSUNIT_DECLARE_MultiLevelHashMap_city \ - -#define CDSUNIT_TEST_MultiLevelHashMap \ - CDSUNIT_TEST_MultiLevelHashMap_fixed \ - CDSUNIT_TEST_MultiLevelHashMap_stdhash \ - CDSUNIT_TEST_MultiLevelHashMap_md5 \ - CDSUNIT_TEST_MultiLevelHashMap_sha256 \ - CDSUNIT_TEST_MultiLevelHashMap_city +#undef CDSUNIT_DECLARE_FeldmanHashMap +#undef CDSUNIT_TEST_FeldmanHashMap + +#define CDSUNIT_DECLARE_FeldmanHashMap \ + CDSUNIT_DECLARE_FeldmanHashMap_fixed \ + CDSUNIT_DECLARE_FeldmanHashMap_stdhash \ + CDSUNIT_DECLARE_FeldmanHashMap_md5 \ + CDSUNIT_DECLARE_FeldmanHashMap_sha256 \ + CDSUNIT_DECLARE_FeldmanHashMap_city \ + +#define CDSUNIT_TEST_FeldmanHashMap \ + CDSUNIT_TEST_FeldmanHashMap_fixed \ + CDSUNIT_TEST_FeldmanHashMap_stdhash \ + CDSUNIT_TEST_FeldmanHashMap_md5 \ + CDSUNIT_TEST_FeldmanHashMap_sha256 \ + CDSUNIT_TEST_FeldmanHashMap_city diff --git a/tests/unit/map2/map_delodd.cpp b/tests/unit/map2/map_delodd.cpp index 69b78ab5..8d933e7d 100644 --- a/tests/unit/map2/map_delodd.cpp +++ b/tests/unit/map2/map_delodd.cpp @@ -17,8 +17,8 @@ namespace map2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize ); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold ); - c_nMultiLevelMap_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelMap_HeadBits); - c_nMultiLevelMap_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelMap_ArrayBits); + c_nFeldmanMap_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanMap_HeadBits); + c_nFeldmanMap_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanMap_ArrayBits); if ( c_nInsThreadCount == 0 ) c_nInsThreadCount = cds::OS::topology::processor_count(); diff --git a/tests/unit/map2/map_delodd.h b/tests/unit/map2/map_delodd.h index 7c90e6b7..9b39b8d8 100644 --- a/tests/unit/map2/map_delodd.h +++ b/tests/unit/map2/map_delodd.h @@ -125,8 +125,8 @@ namespace map2 { size_t c_nCuckooProbesetSize = 16; // CuckooMap probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooMap probeset threshold (0 - use default) - size_t c_nMultiLevelMap_HeadBits = 10; - size_t c_nMultiLevelMap_ArrayBits = 4; + size_t c_nFeldmanMap_HeadBits = 10; + size_t c_nFeldmanMap_ArrayBits = 4; bool c_bPrintGCState = true; @@ -163,7 +163,7 @@ namespace map2 { void operator()( bool /*bNew*/, Q const&, V& ) {} - // MultiLevelHashMap + // FeldmanHashMap template void operator()( Q&, Q*) {} @@ -773,8 +773,8 @@ namespace map2 { CDSUNIT_DECLARE_SkipListMap CDSUNIT_DECLARE_EllenBinTreeMap CDSUNIT_DECLARE_BronsonAVLTreeMap - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city CDSUNIT_DECLARE_CuckooMap CPPUNIT_TEST_SUITE(Map_DelOdd) @@ -783,8 +783,8 @@ namespace map2 { CDSUNIT_TEST_SkipListMap CDSUNIT_TEST_EllenBinTreeMap CDSUNIT_TEST_BronsonAVLTreeMap - CDSUNIT_TEST_MultiLevelHashMap_fixed - CDSUNIT_TEST_MultiLevelHashMap_city + CDSUNIT_TEST_FeldmanHashMap_fixed + CDSUNIT_TEST_FeldmanHashMap_city CDSUNIT_TEST_CuckooMap CPPUNIT_TEST_SUITE_END(); diff --git a/tests/unit/map2/map_delodd_multilevelhashmap.cpp b/tests/unit/map2/map_delodd_feldmanhashmap.cpp similarity index 64% rename from tests/unit/map2/map_delodd_multilevelhashmap.cpp rename to tests/unit/map2/map_delodd_feldmanhashmap.cpp index b337daa3..11c4d749 100644 --- a/tests/unit/map2/map_delodd_multilevelhashmap.cpp +++ b/tests/unit/map2/map_delodd_feldmanhashmap.cpp @@ -1,13 +1,13 @@ //$$CDS-header$$ #include "map2/map_delodd.h" -#include "map2/map_type_multilevel_hashmap.h" +#include "map2/map_type_feldman_hashmap.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Map_DelOdd::X() { run_test::X>(); } #include "map2/map_defs.h" namespace map2 { - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city } // namespace map2 diff --git a/tests/unit/map2/map_find_int.cpp b/tests/unit/map2/map_find_int.cpp index 0cd09317..e763b55d 100644 --- a/tests/unit/map2/map_find_int.cpp +++ b/tests/unit/map2/map_find_int.cpp @@ -40,8 +40,8 @@ namespace map2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold); - c_nMultiLevelMap_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelMap_HeadBits); - c_nMultiLevelMap_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelMap_ArrayBits); + c_nFeldmanMap_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanMap_HeadBits); + c_nFeldmanMap_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanMap_ArrayBits); if ( c_nThreadCount == 0 ) c_nThreadCount = std::thread::hardware_concurrency(); diff --git a/tests/unit/map2/map_find_int.h b/tests/unit/map2/map_find_int.h index 9e73d4c9..2250f924 100644 --- a/tests/unit/map2/map_find_int.h +++ b/tests/unit/map2/map_find_int.h @@ -26,8 +26,8 @@ namespace map2 { size_t c_nCuckooProbesetSize = 16; // CuckooMap probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooMap probeset threshold (o - use default) - size_t c_nMultiLevelMap_HeadBits = 10; - size_t c_nMultiLevelMap_ArrayBits = 4; + size_t c_nFeldmanMap_HeadBits = 10; + size_t c_nFeldmanMap_ArrayBits = 4; size_t c_nLoadFactor; // current load factor @@ -227,7 +227,7 @@ namespace map2 { CDSUNIT_DECLARE_SkipListMap_nogc CDSUNIT_DECLARE_EllenBinTreeMap CDSUNIT_DECLARE_BronsonAVLTreeMap - CDSUNIT_DECLARE_MultiLevelHashMap + CDSUNIT_DECLARE_FeldmanHashMap CDSUNIT_DECLARE_StripedMap CDSUNIT_DECLARE_RefinableMap CDSUNIT_DECLARE_CuckooMap @@ -243,7 +243,7 @@ namespace map2 { CDSUNIT_TEST_SkipListMap_nogc CDSUNIT_TEST_EllenBinTreeMap CDSUNIT_TEST_BronsonAVLTreeMap - CDSUNIT_TEST_MultiLevelHashMap + CDSUNIT_TEST_FeldmanHashMap CDSUNIT_TEST_CuckooMap CDSUNIT_TEST_StripedMap CDSUNIT_TEST_RefinableMap diff --git a/tests/unit/map2/map_find_int_multilevelhashmap.cpp b/tests/unit/map2/map_find_int_feldmanhashmap.cpp similarity index 74% rename from tests/unit/map2/map_find_int_multilevelhashmap.cpp rename to tests/unit/map2/map_find_int_feldmanhashmap.cpp index e606fe01..7049ce26 100644 --- a/tests/unit/map2/map_find_int_multilevelhashmap.cpp +++ b/tests/unit/map2/map_find_int_feldmanhashmap.cpp @@ -1,12 +1,12 @@ //$$CDS-header$$ #include "map2/map_find_int.h" -#include "map2/map_type_multilevel_hashmap.h" +#include "map2/map_type_feldman_hashmap.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Map_find_int::X() { run_test::X>(); } #include "map2/map_defs.h" namespace map2 { - CDSUNIT_DECLARE_MultiLevelHashMap + CDSUNIT_DECLARE_FeldmanHashMap } // namespace map2 diff --git a/tests/unit/map2/map_find_string.cpp b/tests/unit/map2/map_find_string.cpp index 6ccadef3..ec08b9bc 100644 --- a/tests/unit/map2/map_find_string.cpp +++ b/tests/unit/map2/map_find_string.cpp @@ -43,8 +43,8 @@ namespace map2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold); - c_nMultiLevelMap_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelMap_HeadBits); - c_nMultiLevelMap_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelMap_ArrayBits); + c_nFeldmanMap_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanMap_HeadBits); + c_nFeldmanMap_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanMap_ArrayBits); if ( c_nThreadCount == 0 ) c_nThreadCount = std::thread::hardware_concurrency(); diff --git a/tests/unit/map2/map_find_string.h b/tests/unit/map2/map_find_string.h index 36e99089..cbba772c 100644 --- a/tests/unit/map2/map_find_string.h +++ b/tests/unit/map2/map_find_string.h @@ -23,8 +23,8 @@ namespace map2 { size_t c_nCuckooProbesetSize = 16; // CuckooMap probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooMap probeset threshold (o - use default) - size_t c_nMultiLevelMap_HeadBits = 10; - size_t c_nMultiLevelMap_ArrayBits = 4; + size_t c_nFeldmanMap_HeadBits = 10; + size_t c_nFeldmanMap_ArrayBits = 4; size_t c_nLoadFactor; // current load factor @@ -216,9 +216,9 @@ namespace map2 { CDSUNIT_DECLARE_SkipListMap_nogc CDSUNIT_DECLARE_EllenBinTreeMap CDSUNIT_DECLARE_BronsonAVLTreeMap - CDSUNIT_DECLARE_MultiLevelHashMap_md5 - CDSUNIT_DECLARE_MultiLevelHashMap_sha256 - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_md5 + CDSUNIT_DECLARE_FeldmanHashMap_sha256 + CDSUNIT_DECLARE_FeldmanHashMap_city CDSUNIT_DECLARE_StripedMap CDSUNIT_DECLARE_RefinableMap CDSUNIT_DECLARE_CuckooMap @@ -234,9 +234,9 @@ namespace map2 { CDSUNIT_TEST_SkipListMap_nogc CDSUNIT_TEST_EllenBinTreeMap CDSUNIT_TEST_BronsonAVLTreeMap - CDSUNIT_TEST_MultiLevelHashMap_md5 - CDSUNIT_TEST_MultiLevelHashMap_sha256 - CDSUNIT_TEST_MultiLevelHashMap_city + CDSUNIT_TEST_FeldmanHashMap_md5 + CDSUNIT_TEST_FeldmanHashMap_sha256 + CDSUNIT_TEST_FeldmanHashMap_city CDSUNIT_TEST_CuckooMap CDSUNIT_TEST_StripedMap CDSUNIT_TEST_RefinableMap diff --git a/tests/unit/map2/map_find_string_multilevelhashmap.cpp b/tests/unit/map2/map_find_string_feldmanhashmap.cpp similarity index 59% rename from tests/unit/map2/map_find_string_multilevelhashmap.cpp rename to tests/unit/map2/map_find_string_feldmanhashmap.cpp index 92d001c2..af6121ef 100644 --- a/tests/unit/map2/map_find_string_multilevelhashmap.cpp +++ b/tests/unit/map2/map_find_string_feldmanhashmap.cpp @@ -1,14 +1,14 @@ //$$CDS-header$$ #include "map2/map_find_string.h" -#include "map2/map_type_multilevel_hashmap.h" +#include "map2/map_type_feldman_hashmap.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Map_find_string::X() { run_test::X>(); } #include "map2/map_defs.h" namespace map2 { - CDSUNIT_DECLARE_MultiLevelHashMap_md5 - CDSUNIT_DECLARE_MultiLevelHashMap_sha256 - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_md5 + CDSUNIT_DECLARE_FeldmanHashMap_sha256 + CDSUNIT_DECLARE_FeldmanHashMap_city } // namespace map2 diff --git a/tests/unit/map2/map_insdel_func.cpp b/tests/unit/map2/map_insdel_func.cpp index f96723e1..cebd7c5a 100644 --- a/tests/unit/map2/map_insdel_func.cpp +++ b/tests/unit/map2/map_insdel_func.cpp @@ -19,8 +19,8 @@ namespace map2 { c_nCuckooProbesetSize = cfg.getULong("CuckooProbesetSize", static_cast(c_nCuckooProbesetSize) ); c_nCuckooProbesetThreshold = cfg.getULong("CuckooProbesetThreshold", static_cast(c_nCuckooProbesetThreshold) ); - c_nMultiLevelMap_HeadBits = cfg.getULong("MultiLevelMapHeadBits", static_cast(c_nMultiLevelMap_HeadBits) ); - c_nMultiLevelMap_ArrayBits = cfg.getULong("MultiLevelMapArrayBits", static_cast(c_nMultiLevelMap_ArrayBits) ); + c_nFeldmanMap_HeadBits = cfg.getULong("FeldmanMapHeadBits", static_cast(c_nFeldmanMap_HeadBits) ); + c_nFeldmanMap_ArrayBits = cfg.getULong("FeldmanMapArrayBits", static_cast(c_nFeldmanMap_ArrayBits) ); } } // namespace map2 diff --git a/tests/unit/map2/map_insdel_func.h b/tests/unit/map2/map_insdel_func.h index 797c5e23..78fa6bb7 100644 --- a/tests/unit/map2/map_insdel_func.h +++ b/tests/unit/map2/map_insdel_func.h @@ -27,8 +27,8 @@ namespace map2 { size_t c_nCuckooProbesetSize = 16; // CuckooMap probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooMap probeset threshold (o - use default) - size_t c_nMultiLevelMap_HeadBits = 10; - size_t c_nMultiLevelMap_ArrayBits = 4; + size_t c_nFeldmanMap_HeadBits = 10; + size_t c_nFeldmanMap_ArrayBits = 4; size_t c_nLoadFactor; // current load factor @@ -214,7 +214,7 @@ namespace map2 { operator()( bNew, val.first, val.second ); } - // For MultiLevelHashMap + // For FeldmanHashMap template void operator()( Val& cur, Val * old ) { @@ -550,8 +550,8 @@ namespace map2 { CDSUNIT_DECLARE_SkipListMap CDSUNIT_DECLARE_EllenBinTreeMap CDSUNIT_DECLARE_BronsonAVLTreeMap - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city CDSUNIT_DECLARE_StripedMap CDSUNIT_DECLARE_RefinableMap CDSUNIT_DECLARE_CuckooMap @@ -562,8 +562,8 @@ namespace map2 { CDSUNIT_TEST_SkipListMap CDSUNIT_TEST_EllenBinTreeMap CDSUNIT_TEST_BronsonAVLTreeMap - CDSUNIT_TEST_MultiLevelHashMap_fixed - CDSUNIT_TEST_MultiLevelHashMap_city + CDSUNIT_TEST_FeldmanHashMap_fixed + CDSUNIT_TEST_FeldmanHashMap_city CDSUNIT_TEST_CuckooMap CDSUNIT_TEST_StripedMap CDSUNIT_TEST_RefinableMap diff --git a/tests/unit/map2/map_insdel_func_multilevelhashmap.cpp b/tests/unit/map2/map_insdel_func_feldmanhashmap.cpp similarity index 65% rename from tests/unit/map2/map_insdel_func_multilevelhashmap.cpp rename to tests/unit/map2/map_insdel_func_feldmanhashmap.cpp index b79e71e8..3e1bf3ad 100644 --- a/tests/unit/map2/map_insdel_func_multilevelhashmap.cpp +++ b/tests/unit/map2/map_insdel_func_feldmanhashmap.cpp @@ -1,13 +1,13 @@ //$$CDS-header$$ #include "map2/map_insdel_func.h" -#include "map2/map_type_multilevel_hashmap.h" +#include "map2/map_type_feldman_hashmap.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Map_InsDel_func::X() { run_test::X>(); } #include "map2/map_defs.h" namespace map2 { - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city } // namespace map2 diff --git a/tests/unit/map2/map_insdel_int.cpp b/tests/unit/map2/map_insdel_int.cpp index cd636039..4c051e9a 100644 --- a/tests/unit/map2/map_insdel_int.cpp +++ b/tests/unit/map2/map_insdel_int.cpp @@ -18,8 +18,8 @@ namespace map2 { c_nCuckooProbesetSize = cfg.getULong("CuckooProbesetSize", static_cast(c_nCuckooProbesetSize) ); c_nCuckooProbesetThreshold = cfg.getULong("CuckooProbesetThreshold", static_cast(c_nCuckooProbesetThreshold) ); - c_nMultiLevelMap_HeadBits = cfg.getULong("MultiLevelMapHeadBits", static_cast(c_nMultiLevelMap_HeadBits) ); - c_nMultiLevelMap_ArrayBits = cfg.getULong("MultiLevelMapArrayBits", static_cast(c_nMultiLevelMap_ArrayBits) ); + c_nFeldmanMap_HeadBits = cfg.getULong("FeldmanMapHeadBits", static_cast(c_nFeldmanMap_HeadBits) ); + c_nFeldmanMap_ArrayBits = cfg.getULong("FeldmanMapArrayBits", static_cast(c_nFeldmanMap_ArrayBits) ); c_bPrintGCState = cfg.getBool("PrintGCStateFlag", c_bPrintGCState ); diff --git a/tests/unit/map2/map_insdel_int.h b/tests/unit/map2/map_insdel_int.h index 2f7f8a93..20e3720f 100644 --- a/tests/unit/map2/map_insdel_int.h +++ b/tests/unit/map2/map_insdel_int.h @@ -22,8 +22,8 @@ namespace map2 { size_t c_nCuckooProbesetSize = 16; // CuckooMap probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooMap probeset threshold (o - use default) - size_t c_nMultiLevelMap_HeadBits = 10; - size_t c_nMultiLevelMap_ArrayBits = 4; + size_t c_nFeldmanMap_HeadBits = 10; + size_t c_nFeldmanMap_ArrayBits = 4; bool c_bPrintGCState = true; @@ -251,8 +251,8 @@ namespace map2 { CDSUNIT_DECLARE_SkipListMap CDSUNIT_DECLARE_EllenBinTreeMap CDSUNIT_DECLARE_BronsonAVLTreeMap - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city CDSUNIT_DECLARE_StripedMap CDSUNIT_DECLARE_RefinableMap CDSUNIT_DECLARE_CuckooMap @@ -264,8 +264,8 @@ namespace map2 { CDSUNIT_TEST_SkipListMap CDSUNIT_TEST_EllenBinTreeMap CDSUNIT_TEST_BronsonAVLTreeMap - CDSUNIT_TEST_MultiLevelHashMap_fixed - CDSUNIT_TEST_MultiLevelHashMap_city + CDSUNIT_TEST_FeldmanHashMap_fixed + CDSUNIT_TEST_FeldmanHashMap_city CDSUNIT_TEST_CuckooMap CDSUNIT_TEST_StripedMap CDSUNIT_TEST_RefinableMap diff --git a/tests/unit/map2/map_insdel_int_multilevelhashmap.cpp b/tests/unit/map2/map_insdel_int_feldmanhashmap.cpp similarity index 65% rename from tests/unit/map2/map_insdel_int_multilevelhashmap.cpp rename to tests/unit/map2/map_insdel_int_feldmanhashmap.cpp index 1ac91ec9..64868315 100644 --- a/tests/unit/map2/map_insdel_int_multilevelhashmap.cpp +++ b/tests/unit/map2/map_insdel_int_feldmanhashmap.cpp @@ -1,13 +1,13 @@ //$$CDS-header$$ #include "map2/map_insdel_int.h" -#include "map2/map_type_multilevel_hashmap.h" +#include "map2/map_type_feldman_hashmap.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Map_InsDel_int::X() { run_test::X>(); } #include "map2/map_defs.h" namespace map2 { - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city } // namespace map2 diff --git a/tests/unit/map2/map_insdel_item_int.cpp b/tests/unit/map2/map_insdel_item_int.cpp index 12e93805..69d39908 100644 --- a/tests/unit/map2/map_insdel_item_int.cpp +++ b/tests/unit/map2/map_insdel_item_int.cpp @@ -18,8 +18,8 @@ namespace map2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold); - c_nMultiLevelMap_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelMap_HeadBits); - c_nMultiLevelMap_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelMap_ArrayBits); + c_nFeldmanMap_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanMap_HeadBits); + c_nFeldmanMap_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanMap_ArrayBits); if ( c_nThreadCount == 0 ) c_nThreadCount = std::thread::hardware_concurrency() * 2; diff --git a/tests/unit/map2/map_insdel_item_int.h b/tests/unit/map2/map_insdel_item_int.h index fffbf8c4..a4f01add 100644 --- a/tests/unit/map2/map_insdel_item_int.h +++ b/tests/unit/map2/map_insdel_item_int.h @@ -22,8 +22,8 @@ namespace map2 { size_t c_nCuckooProbesetSize = 16; // CuckooMap probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooMap probeset threshold (o - use default) - size_t c_nMultiLevelMap_HeadBits = 10; - size_t c_nMultiLevelMap_ArrayBits = 4; + size_t c_nFeldmanMap_HeadBits = 10; + size_t c_nFeldmanMap_ArrayBits = 4; size_t c_nGoalItem; size_t c_nLoadFactor = 2; // current load factor @@ -63,7 +63,7 @@ namespace map2 { val = key; } - // for MultiLevelHashMap + // for FeldmanHashMap void operator()( std::pair& item, std::pair * pOld ) { if ( !pOld ) @@ -276,8 +276,8 @@ namespace map2 { CDSUNIT_DECLARE_SkipListMap CDSUNIT_DECLARE_EllenBinTreeMap CDSUNIT_DECLARE_BronsonAVLTreeMap - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city CDSUNIT_DECLARE_StripedMap CDSUNIT_DECLARE_RefinableMap CDSUNIT_DECLARE_CuckooMap @@ -289,8 +289,8 @@ namespace map2 { CDSUNIT_TEST_SkipListMap CDSUNIT_TEST_EllenBinTreeMap CDSUNIT_TEST_BronsonAVLTreeMap - CDSUNIT_TEST_MultiLevelHashMap_fixed - CDSUNIT_TEST_MultiLevelHashMap_city + CDSUNIT_TEST_FeldmanHashMap_fixed + CDSUNIT_TEST_FeldmanHashMap_city CDSUNIT_TEST_CuckooMap CDSUNIT_TEST_StripedMap CDSUNIT_TEST_RefinableMap diff --git a/tests/unit/map2/map_insdel_item_int_multilevelhashmap.cpp b/tests/unit/map2/map_insdel_item_int_feldmanhashmap.cpp similarity index 66% rename from tests/unit/map2/map_insdel_item_int_multilevelhashmap.cpp rename to tests/unit/map2/map_insdel_item_int_feldmanhashmap.cpp index 4bd37b74..2a6e3ba5 100644 --- a/tests/unit/map2/map_insdel_item_int_multilevelhashmap.cpp +++ b/tests/unit/map2/map_insdel_item_int_feldmanhashmap.cpp @@ -1,13 +1,13 @@ //$$CDS-header$$ #include "map2/map_insdel_item_int.h" -#include "map2/map_type_multilevel_hashmap.h" +#include "map2/map_type_feldman_hashmap.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Map_InsDel_Item_int::X() { run_test::X>(); } #include "map2/map_defs.h" namespace map2 { - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city } // namespace map2 diff --git a/tests/unit/map2/map_insdel_item_string.cpp b/tests/unit/map2/map_insdel_item_string.cpp index a8c125be..46679f27 100644 --- a/tests/unit/map2/map_insdel_item_string.cpp +++ b/tests/unit/map2/map_insdel_item_string.cpp @@ -18,8 +18,8 @@ namespace map2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold); - c_nMultiLevelMap_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelMap_HeadBits); - c_nMultiLevelMap_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelMap_ArrayBits); + c_nFeldmanMap_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanMap_HeadBits); + c_nFeldmanMap_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanMap_ArrayBits); if ( c_nThreadCount == 0 ) c_nThreadCount = std::thread::hardware_concurrency() * 2; diff --git a/tests/unit/map2/map_insdel_item_string.h b/tests/unit/map2/map_insdel_item_string.h index f7e41dc1..56ef762e 100644 --- a/tests/unit/map2/map_insdel_item_string.h +++ b/tests/unit/map2/map_insdel_item_string.h @@ -22,8 +22,8 @@ namespace map2 { size_t c_nCuckooProbesetSize = 16; // CuckooMap probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooMap probeset threshold (o - use default) - size_t c_nMultiLevelMap_HeadBits = 10; - size_t c_nMultiLevelMap_ArrayBits = 4; + size_t c_nFeldmanMap_HeadBits = 10; + size_t c_nFeldmanMap_ArrayBits = 4; size_t c_nGoalItem; size_t c_nLoadFactor = 2; // current load factor @@ -257,9 +257,9 @@ namespace map2 { CDSUNIT_DECLARE_SkipListMap CDSUNIT_DECLARE_EllenBinTreeMap CDSUNIT_DECLARE_BronsonAVLTreeMap - CDSUNIT_DECLARE_MultiLevelHashMap_md5 - CDSUNIT_DECLARE_MultiLevelHashMap_sha256 - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_md5 + CDSUNIT_DECLARE_FeldmanHashMap_sha256 + CDSUNIT_DECLARE_FeldmanHashMap_city CDSUNIT_DECLARE_StripedMap CDSUNIT_DECLARE_RefinableMap CDSUNIT_DECLARE_CuckooMap @@ -271,9 +271,9 @@ namespace map2 { CDSUNIT_TEST_SkipListMap CDSUNIT_TEST_EllenBinTreeMap CDSUNIT_TEST_BronsonAVLTreeMap - CDSUNIT_TEST_MultiLevelHashMap_md5 - CDSUNIT_TEST_MultiLevelHashMap_sha256 - CDSUNIT_TEST_MultiLevelHashMap_city + CDSUNIT_TEST_FeldmanHashMap_md5 + CDSUNIT_TEST_FeldmanHashMap_sha256 + CDSUNIT_TEST_FeldmanHashMap_city CDSUNIT_TEST_CuckooMap CDSUNIT_TEST_StripedMap CDSUNIT_TEST_RefinableMap diff --git a/tests/unit/map2/map_insdel_item_string_multilevelhashmap.cpp b/tests/unit/map2/map_insdel_item_string_feldmanhashmap.cpp similarity index 60% rename from tests/unit/map2/map_insdel_item_string_multilevelhashmap.cpp rename to tests/unit/map2/map_insdel_item_string_feldmanhashmap.cpp index 0d75f795..659d0e65 100644 --- a/tests/unit/map2/map_insdel_item_string_multilevelhashmap.cpp +++ b/tests/unit/map2/map_insdel_item_string_feldmanhashmap.cpp @@ -1,14 +1,14 @@ //$$CDS-header$$ #include "map2/map_insdel_item_string.h" -#include "map2/map_type_multilevel_hashmap.h" +#include "map2/map_type_feldman_hashmap.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Map_InsDel_Item_string::X() { run_test::X>(); } #include "map2/map_defs.h" namespace map2 { - CDSUNIT_DECLARE_MultiLevelHashMap_md5 - CDSUNIT_DECLARE_MultiLevelHashMap_sha256 - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_md5 + CDSUNIT_DECLARE_FeldmanHashMap_sha256 + CDSUNIT_DECLARE_FeldmanHashMap_city } // namespace map2 diff --git a/tests/unit/map2/map_insdel_string.cpp b/tests/unit/map2/map_insdel_string.cpp index e52c8276..6354966d 100644 --- a/tests/unit/map2/map_insdel_string.cpp +++ b/tests/unit/map2/map_insdel_string.cpp @@ -18,8 +18,8 @@ namespace map2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold); - c_nMultiLevelMap_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelMap_HeadBits); - c_nMultiLevelMap_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelMap_ArrayBits); + c_nFeldmanMap_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanMap_HeadBits); + c_nFeldmanMap_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanMap_ArrayBits); if ( c_nInsertThreadCount == 0 ) c_nInsertThreadCount = std::thread::hardware_concurrency(); diff --git a/tests/unit/map2/map_insdel_string.h b/tests/unit/map2/map_insdel_string.h index b1fe41be..8c71f081 100644 --- a/tests/unit/map2/map_insdel_string.h +++ b/tests/unit/map2/map_insdel_string.h @@ -22,8 +22,8 @@ namespace map2 { size_t c_nCuckooProbesetSize = 16; // CuckooMap probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooMap probeset threshold (o - use default) - size_t c_nMultiLevelMap_HeadBits = 10; - size_t c_nMultiLevelMap_ArrayBits = 4; + size_t c_nFeldmanMap_HeadBits = 10; + size_t c_nFeldmanMap_ArrayBits = 4; bool c_bPrintGCState = true; @@ -256,8 +256,8 @@ namespace map2 { CDSUNIT_DECLARE_SkipListMap CDSUNIT_DECLARE_EllenBinTreeMap CDSUNIT_DECLARE_BronsonAVLTreeMap - CDSUNIT_DECLARE_MultiLevelHashMap_sha256 - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_sha256 + CDSUNIT_DECLARE_FeldmanHashMap_city CDSUNIT_DECLARE_StripedMap CDSUNIT_DECLARE_RefinableMap CDSUNIT_DECLARE_CuckooMap @@ -269,8 +269,8 @@ namespace map2 { CDSUNIT_TEST_SkipListMap CDSUNIT_TEST_EllenBinTreeMap CDSUNIT_TEST_BronsonAVLTreeMap - CDSUNIT_TEST_MultiLevelHashMap_sha256 - CDSUNIT_TEST_MultiLevelHashMap_city + CDSUNIT_TEST_FeldmanHashMap_sha256 + CDSUNIT_TEST_FeldmanHashMap_city CDSUNIT_TEST_CuckooMap CDSUNIT_TEST_StripedMap CDSUNIT_TEST_RefinableMap diff --git a/tests/unit/map2/map_insdel_string_multilevelhashmap.cpp b/tests/unit/map2/map_insdel_string_feldmanhashmap.cpp similarity index 65% rename from tests/unit/map2/map_insdel_string_multilevelhashmap.cpp rename to tests/unit/map2/map_insdel_string_feldmanhashmap.cpp index 9651f0d8..60cc3513 100644 --- a/tests/unit/map2/map_insdel_string_multilevelhashmap.cpp +++ b/tests/unit/map2/map_insdel_string_feldmanhashmap.cpp @@ -1,13 +1,13 @@ //$$CDS-header$$ #include "map2/map_insdel_string.h" -#include "map2/map_type_multilevel_hashmap.h" +#include "map2/map_type_feldman_hashmap.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Map_InsDel_string::X() { run_test::X>(); } #include "map2/map_defs.h" namespace map2 { - CDSUNIT_DECLARE_MultiLevelHashMap_sha256 - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_sha256 + CDSUNIT_DECLARE_FeldmanHashMap_city } // namespace map2 diff --git a/tests/unit/map2/map_insdelfind.cpp b/tests/unit/map2/map_insdelfind.cpp index 9f343de7..2f8cfeee 100644 --- a/tests/unit/map2/map_insdelfind.cpp +++ b/tests/unit/map2/map_insdelfind.cpp @@ -20,8 +20,8 @@ namespace map2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold); - c_nMultiLevelMap_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelMap_HeadBits); - c_nMultiLevelMap_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelMap_ArrayBits); + c_nFeldmanMap_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanMap_HeadBits); + c_nFeldmanMap_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanMap_ArrayBits); if ( c_nThreadCount == 0 ) c_nThreadCount = std::thread::hardware_concurrency() * 2; diff --git a/tests/unit/map2/map_insdelfind.h b/tests/unit/map2/map_insdelfind.h index 102498e1..636b9ab6 100644 --- a/tests/unit/map2/map_insdelfind.h +++ b/tests/unit/map2/map_insdelfind.h @@ -23,8 +23,8 @@ namespace map2 { size_t c_nCuckooProbesetSize = 16; // CuckooMap probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooMap probeset threshold (o - use default) - size_t c_nMultiLevelMap_HeadBits = 10; - size_t c_nMultiLevelMap_ArrayBits = 4; + size_t c_nFeldmanMap_HeadBits = 10; + size_t c_nFeldmanMap_ArrayBits = 4; size_t c_nLoadFactor = 2; // current load factor @@ -84,7 +84,7 @@ namespace map2 { void operator()( bool /*bNew*/, map_value_type& /*cur*/, Q const& /*val*/ ) {} - // MultiLevelHashMap + // FeldmanHashMap void operator()( map_value_type& /*cur*/, map_value_type * /*old*/) {} @@ -255,8 +255,8 @@ namespace map2 { CDSUNIT_DECLARE_SkipListMap CDSUNIT_DECLARE_EllenBinTreeMap CDSUNIT_DECLARE_BronsonAVLTreeMap - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city CDSUNIT_DECLARE_StripedMap CDSUNIT_DECLARE_RefinableMap CDSUNIT_DECLARE_CuckooMap @@ -268,8 +268,8 @@ namespace map2 { CDSUNIT_TEST_SkipListMap CDSUNIT_TEST_EllenBinTreeMap CDSUNIT_TEST_BronsonAVLTreeMap - CDSUNIT_TEST_MultiLevelHashMap_fixed - CDSUNIT_TEST_MultiLevelHashMap_city + CDSUNIT_TEST_FeldmanHashMap_fixed + CDSUNIT_TEST_FeldmanHashMap_city CDSUNIT_TEST_CuckooMap CDSUNIT_TEST_StripedMap CDSUNIT_TEST_RefinableMap diff --git a/tests/unit/map2/map_insdelfind_multilevelhashmap.cpp b/tests/unit/map2/map_insdelfind_feldmanhashmap.cpp similarity index 65% rename from tests/unit/map2/map_insdelfind_multilevelhashmap.cpp rename to tests/unit/map2/map_insdelfind_feldmanhashmap.cpp index 2eadd2d0..1321f576 100644 --- a/tests/unit/map2/map_insdelfind_multilevelhashmap.cpp +++ b/tests/unit/map2/map_insdelfind_feldmanhashmap.cpp @@ -1,13 +1,13 @@ //$$CDS-header$$ #include "map2/map_insdelfind.h" -#include "map2/map_type_multilevel_hashmap.h" +#include "map2/map_type_feldman_hashmap.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Map_InsDelFind::X() { run_test::X>(); } #include "map2/map_defs.h" namespace map2 { - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city } // namespace map2 diff --git a/tests/unit/map2/map_insfind_int.cpp b/tests/unit/map2/map_insfind_int.cpp index de3cf59e..31dee98d 100644 --- a/tests/unit/map2/map_insfind_int.cpp +++ b/tests/unit/map2/map_insfind_int.cpp @@ -16,8 +16,8 @@ namespace map2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold); - c_nMultiLevelMap_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelMap_HeadBits); - c_nMultiLevelMap_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelMap_ArrayBits); + c_nFeldmanMap_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanMap_HeadBits); + c_nFeldmanMap_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanMap_ArrayBits); if ( c_nThreadCount == 0 ) c_nThreadCount = std::thread::hardware_concurrency(); diff --git a/tests/unit/map2/map_insfind_int.h b/tests/unit/map2/map_insfind_int.h index d98961de..57e59c7f 100644 --- a/tests/unit/map2/map_insfind_int.h +++ b/tests/unit/map2/map_insfind_int.h @@ -22,8 +22,8 @@ namespace map2 { size_t c_nCuckooProbesetSize = 16; // CuckooMap probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooMap probeset threshold (o - use default) - size_t c_nMultiLevelMap_HeadBits = 10; - size_t c_nMultiLevelMap_ArrayBits = 4; + size_t c_nFeldmanMap_HeadBits = 10; + size_t c_nFeldmanMap_ArrayBits = 4; size_t c_nLoadFactor = 2; // current load factor @@ -197,8 +197,8 @@ namespace map2 { CDSUNIT_DECLARE_SkipListMap_nogc CDSUNIT_DECLARE_EllenBinTreeMap CDSUNIT_DECLARE_BronsonAVLTreeMap - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city CDSUNIT_DECLARE_StripedMap CDSUNIT_DECLARE_RefinableMap CDSUNIT_DECLARE_CuckooMap @@ -214,8 +214,8 @@ namespace map2 { CDSUNIT_TEST_SkipListMap_nogc CDSUNIT_TEST_EllenBinTreeMap CDSUNIT_TEST_BronsonAVLTreeMap - CDSUNIT_TEST_MultiLevelHashMap_fixed - CDSUNIT_TEST_MultiLevelHashMap_city + CDSUNIT_TEST_FeldmanHashMap_fixed + CDSUNIT_TEST_FeldmanHashMap_city CDSUNIT_TEST_CuckooMap CDSUNIT_TEST_StripedMap CDSUNIT_TEST_RefinableMap diff --git a/tests/unit/map2/map_insfind_int_multilevelhashmap.cpp b/tests/unit/map2/map_insfind_int_feldmanhashmap.cpp similarity index 65% rename from tests/unit/map2/map_insfind_int_multilevelhashmap.cpp rename to tests/unit/map2/map_insfind_int_feldmanhashmap.cpp index 260b1e72..bf058fb9 100644 --- a/tests/unit/map2/map_insfind_int_multilevelhashmap.cpp +++ b/tests/unit/map2/map_insfind_int_feldmanhashmap.cpp @@ -1,13 +1,13 @@ //$$CDS-header$$ #include "map2/map_insfind_int.h" -#include "map2/map_type_multilevel_hashmap.h" +#include "map2/map_type_feldman_hashmap.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Map_InsFind_int::X() { run_test::X>(); } #include "map2/map_defs.h" namespace map2 { - CDSUNIT_DECLARE_MultiLevelHashMap_fixed - CDSUNIT_DECLARE_MultiLevelHashMap_city + CDSUNIT_DECLARE_FeldmanHashMap_fixed + CDSUNIT_DECLARE_FeldmanHashMap_city } // namespace map2 diff --git a/tests/unit/map2/map_type_feldman_hashmap.h b/tests/unit/map2/map_type_feldman_hashmap.h new file mode 100644 index 00000000..ec1bbc28 --- /dev/null +++ b/tests/unit/map2/map_type_feldman_hashmap.h @@ -0,0 +1,227 @@ +//$$CDS-header$$ + +#ifndef CDSUNIT_MAP_TYPE_FELDMAN_HASHMAP_H +#define CDSUNIT_MAP_TYPE_FELDMAN_HASHMAP_H + +#include "map2/map_type.h" + +#include +#include +#include + +#include "print_feldman_hashset_stat.h" +#include "hashing/hash_func.h" + +namespace map2 { + + template + class FeldmanHashMap : public cc::FeldmanHashMap< GC, Key, T, Traits > + { + typedef cc::FeldmanHashMap< GC, Key, T, Traits > base_class; + public: + template + FeldmanHashMap( Config const& cfg) + : base_class( cfg.c_nFeldmanMap_HeadBits, cfg.c_nFeldmanMap_ArrayBits ) + {} + + // for testing + static CDS_CONSTEXPR bool const c_bExtractSupported = true; + static CDS_CONSTEXPR bool const c_bLoadFactorDepended = false; + static CDS_CONSTEXPR bool const c_bEraseExactKey = true; + }; + + struct tag_FeldmanHashMap; + + template + struct map_type< tag_FeldmanHashMap, Key, Value >: public map_type_base< Key, Value > + { + typedef map_type_base< Key, Value > base_class; + typedef typename base_class::compare compare; + typedef typename base_class::less less; + + struct traits_FeldmanHashMap_stdhash : public cc::feldman_hashmap::traits + { + typedef std::hash< Key > hash; + }; + + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_stdhash > FeldmanHashMap_hp_stdhash; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_stdhash > FeldmanHashMap_dhp_stdhash; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_stdhash > FeldmanHashMap_rcu_gpi_stdhash; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_stdhash > FeldmanHashMap_rcu_gpb_stdhash; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_stdhash > FeldmanHashMap_rcu_gpt_stdhash; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_stdhash > FeldmanHashMap_rcu_shb_stdhash; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_stdhash > FeldmanHashMap_rcu_sht_stdhash; +#endif + + struct traits_FeldmanHashMap_stdhash_stat: traits_FeldmanHashMap_stdhash + { + typedef cc::feldman_hashmap::stat<> stat; + }; + + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_stdhash_stat > FeldmanHashMap_hp_stdhash_stat; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_stdhash_stat > FeldmanHashMap_dhp_stdhash_stat; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_stdhash_stat > FeldmanHashMap_rcu_gpi_stdhash_stat; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_stdhash_stat > FeldmanHashMap_rcu_gpb_stdhash_stat; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_stdhash_stat > FeldmanHashMap_rcu_gpt_stdhash_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_stdhash_stat > FeldmanHashMap_rcu_shb_stdhash_stat; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_stdhash_stat > FeldmanHashMap_rcu_sht_stdhash_stat; +#endif + + // SHA256 + struct traits_FeldmanHashMap_sha256 : public cc::feldman_hashmap::traits + { + typedef ::hashing::sha256 hash; + }; + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_sha256 > FeldmanHashMap_hp_sha256; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_sha256 > FeldmanHashMap_dhp_sha256; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_sha256 > FeldmanHashMap_rcu_gpi_sha256; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_sha256 > FeldmanHashMap_rcu_gpb_sha256; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_sha256 > FeldmanHashMap_rcu_gpt_sha256; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_sha256 > FeldmanHashMap_rcu_shb_sha256; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_sha256 > FeldmanHashMap_rcu_sht_sha256; +#endif + + struct traits_FeldmanHashMap_sha256_stat : public traits_FeldmanHashMap_sha256 + { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_sha256_stat > FeldmanHashMap_hp_sha256_stat; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_sha256_stat > FeldmanHashMap_dhp_sha256_stat; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_sha256_stat > FeldmanHashMap_rcu_gpi_sha256_stat; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_sha256_stat > FeldmanHashMap_rcu_gpb_sha256_stat; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_sha256_stat > FeldmanHashMap_rcu_gpt_sha256_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_sha256_stat > FeldmanHashMap_rcu_shb_sha256_stat; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_sha256_stat > FeldmanHashMap_rcu_sht_sha256_stat; +#endif + + //MD5 + struct traits_FeldmanHashMap_md5 : public cc::feldman_hashmap::traits + { + typedef ::hashing::md5 hash; + }; + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_md5 > FeldmanHashMap_hp_md5; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_md5 > FeldmanHashMap_dhp_md5; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_md5 > FeldmanHashMap_rcu_gpi_md5; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_md5 > FeldmanHashMap_rcu_gpb_md5; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_md5 > FeldmanHashMap_rcu_gpt_md5; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_md5 > FeldmanHashMap_rcu_shb_md5; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_md5 > FeldmanHashMap_rcu_sht_md5; +#endif + + struct traits_FeldmanHashMap_md5_stat : public traits_FeldmanHashMap_md5 + { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_md5_stat > FeldmanHashMap_hp_md5_stat; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_md5_stat > FeldmanHashMap_dhp_md5_stat; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_md5_stat > FeldmanHashMap_rcu_gpi_md5_stat; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_md5_stat > FeldmanHashMap_rcu_gpb_md5_stat; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_md5_stat > FeldmanHashMap_rcu_gpt_md5_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_md5_stat > FeldmanHashMap_rcu_shb_md5_stat; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_md5_stat > FeldmanHashMap_rcu_sht_md5_stat; +#endif + + // CityHash +#if CDS_BUILD_BITS == 64 + struct traits_FeldmanHashMap_city64 : public cc::feldman_hashmap::traits + { + typedef ::hashing::city64 hash; + typedef ::hashing::city64::less less; + }; + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_city64 > FeldmanHashMap_hp_city64; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_city64 > FeldmanHashMap_dhp_city64; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_city64 > FeldmanHashMap_rcu_gpi_city64; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_city64 > FeldmanHashMap_rcu_gpb_city64; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_city64 > FeldmanHashMap_rcu_gpt_city64; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_city64 > FeldmanHashMap_rcu_shb_city64; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_city64 > FeldmanHashMap_rcu_sht_city64; +#endif + + struct traits_FeldmanHashMap_city64_stat : public traits_FeldmanHashMap_city64 + { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_city64_stat > FeldmanHashMap_hp_city64_stat; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_city64_stat > FeldmanHashMap_dhp_city64_stat; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_city64_stat > FeldmanHashMap_rcu_gpi_city64_stat; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_city64_stat > FeldmanHashMap_rcu_gpb_city64_stat; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_city64_stat > FeldmanHashMap_rcu_gpt_city64_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_city64_stat > FeldmanHashMap_rcu_shb_city64_stat; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_city64_stat > FeldmanHashMap_rcu_sht_city64_stat; +#endif + + struct traits_FeldmanHashMap_city128 : public cc::feldman_hashmap::traits + { + typedef ::hashing::city128 hash; + typedef ::hashing::city128::less less; + }; + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_city128 > FeldmanHashMap_hp_city128; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_city128 > FeldmanHashMap_dhp_city128; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_city128 > FeldmanHashMap_rcu_gpi_city128; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_city128 > FeldmanHashMap_rcu_gpb_city128; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_city128 > FeldmanHashMap_rcu_gpt_city128; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_city128 > FeldmanHashMap_rcu_shb_city128; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_city128 > FeldmanHashMap_rcu_sht_city128; +#endif + + struct traits_FeldmanHashMap_city128_stat : public traits_FeldmanHashMap_city128 + { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_city128_stat > FeldmanHashMap_hp_city128_stat; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_city128_stat > FeldmanHashMap_dhp_city128_stat; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_city128_stat > FeldmanHashMap_rcu_gpi_city128_stat; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_city128_stat > FeldmanHashMap_rcu_gpb_city128_stat; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_city128_stat > FeldmanHashMap_rcu_gpt_city128_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_city128_stat > FeldmanHashMap_rcu_shb_city128_stat; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_city128_stat > FeldmanHashMap_rcu_sht_city128_stat; +#endif +#endif // CDS_BUILD_BITS == 64 + + + // for fixed-sized keys - no hash functor required + typedef FeldmanHashMap< cds::gc::HP, Key, Value > FeldmanHashMap_hp_fixed; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value > FeldmanHashMap_dhp_fixed; + typedef FeldmanHashMap< rcu_gpi, Key, Value > FeldmanHashMap_rcu_gpi_fixed; + typedef FeldmanHashMap< rcu_gpb, Key, Value > FeldmanHashMap_rcu_gpb_fixed; + typedef FeldmanHashMap< rcu_gpt, Key, Value > FeldmanHashMap_rcu_gpt_fixed; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value > FeldmanHashMap_rcu_shb_fixed; + typedef FeldmanHashMap< rcu_sht, Key, Value > FeldmanHashMap_rcu_sht_fixed; +#endif + + struct traits_FeldmanHashMap_stat : public cc::feldman_hashmap::traits + { + typedef cc::feldman_hashmap::stat<> stat; + }; + typedef FeldmanHashMap< cds::gc::HP, Key, Value, traits_FeldmanHashMap_stat > FeldmanHashMap_hp_fixed_stat; + typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_stat > FeldmanHashMap_dhp_fixed_stat; + typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_stat > FeldmanHashMap_rcu_gpi_fixed_stat; + typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_stat > FeldmanHashMap_rcu_gpb_fixed_stat; + typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_stat > FeldmanHashMap_rcu_gpt_fixed_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_stat > FeldmanHashMap_rcu_shb_fixed_stat; + typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_stat > FeldmanHashMap_rcu_sht_fixed_stat; +#endif + + }; + + template + static inline void print_stat( FeldmanHashMap< GC, K, T, Traits > const& m ) + { + CPPUNIT_MSG( m.statistics() ); + } + +} // namespace map2 + +#endif // #ifndef CDSUNIT_MAP_TYPE_FELDMAN_HASHMAP_H diff --git a/tests/unit/map2/map_type_multilevel_hashmap.h b/tests/unit/map2/map_type_multilevel_hashmap.h deleted file mode 100644 index 1ac5a842..00000000 --- a/tests/unit/map2/map_type_multilevel_hashmap.h +++ /dev/null @@ -1,227 +0,0 @@ -//$$CDS-header$$ - -#ifndef CDSUNIT_MAP_TYPE_MULTILEVEL_HASHMAP_H -#define CDSUNIT_MAP_TYPE_MULTILEVEL_HASHMAP_H - -#include "map2/map_type.h" - -#include -#include -#include - -#include "print_multilevel_hashset_stat.h" -#include "hashing/hash_func.h" - -namespace map2 { - - template - class MultiLevelHashMap : public cc::MultiLevelHashMap< GC, Key, T, Traits > - { - typedef cc::MultiLevelHashMap< GC, Key, T, Traits > base_class; - public: - template - MultiLevelHashMap( Config const& cfg) - : base_class( cfg.c_nMultiLevelMap_HeadBits, cfg.c_nMultiLevelMap_ArrayBits ) - {} - - // for testing - static CDS_CONSTEXPR bool const c_bExtractSupported = true; - static CDS_CONSTEXPR bool const c_bLoadFactorDepended = false; - static CDS_CONSTEXPR bool const c_bEraseExactKey = true; - }; - - struct tag_MultiLevelHashMap; - - template - struct map_type< tag_MultiLevelHashMap, Key, Value >: public map_type_base< Key, Value > - { - typedef map_type_base< Key, Value > base_class; - typedef typename base_class::compare compare; - typedef typename base_class::less less; - - struct traits_MultiLevelHashMap_stdhash : public cc::multilevel_hashmap::traits - { - typedef std::hash< Key > hash; - }; - - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_stdhash > MultiLevelHashMap_hp_stdhash; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_stdhash > MultiLevelHashMap_dhp_stdhash; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_stdhash > MultiLevelHashMap_rcu_gpi_stdhash; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_stdhash > MultiLevelHashMap_rcu_gpb_stdhash; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_stdhash > MultiLevelHashMap_rcu_gpt_stdhash; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_stdhash > MultiLevelHashMap_rcu_shb_stdhash; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_stdhash > MultiLevelHashMap_rcu_sht_stdhash; -#endif - - struct traits_MultiLevelHashMap_stdhash_stat: traits_MultiLevelHashMap_stdhash - { - typedef cc::multilevel_hashmap::stat<> stat; - }; - - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_stdhash_stat > MultiLevelHashMap_hp_stdhash_stat; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_stdhash_stat > MultiLevelHashMap_dhp_stdhash_stat; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_stdhash_stat > MultiLevelHashMap_rcu_gpi_stdhash_stat; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_stdhash_stat > MultiLevelHashMap_rcu_gpb_stdhash_stat; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_stdhash_stat > MultiLevelHashMap_rcu_gpt_stdhash_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_stdhash_stat > MultiLevelHashMap_rcu_shb_stdhash_stat; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_stdhash_stat > MultiLevelHashMap_rcu_sht_stdhash_stat; -#endif - - // SHA256 - struct traits_MultiLevelHashMap_sha256 : public cc::multilevel_hashmap::traits - { - typedef ::hashing::sha256 hash; - }; - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_sha256 > MultiLevelHashMap_hp_sha256; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_sha256 > MultiLevelHashMap_dhp_sha256; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_sha256 > MultiLevelHashMap_rcu_gpi_sha256; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_sha256 > MultiLevelHashMap_rcu_gpb_sha256; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_sha256 > MultiLevelHashMap_rcu_gpt_sha256; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_sha256 > MultiLevelHashMap_rcu_shb_sha256; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_sha256 > MultiLevelHashMap_rcu_sht_sha256; -#endif - - struct traits_MultiLevelHashMap_sha256_stat : public traits_MultiLevelHashMap_sha256 - { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_sha256_stat > MultiLevelHashMap_hp_sha256_stat; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_sha256_stat > MultiLevelHashMap_dhp_sha256_stat; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_sha256_stat > MultiLevelHashMap_rcu_gpi_sha256_stat; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_sha256_stat > MultiLevelHashMap_rcu_gpb_sha256_stat; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_sha256_stat > MultiLevelHashMap_rcu_gpt_sha256_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_sha256_stat > MultiLevelHashMap_rcu_shb_sha256_stat; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_sha256_stat > MultiLevelHashMap_rcu_sht_sha256_stat; -#endif - - //MD5 - struct traits_MultiLevelHashMap_md5 : public cc::multilevel_hashmap::traits - { - typedef ::hashing::md5 hash; - }; - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_md5 > MultiLevelHashMap_hp_md5; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_md5 > MultiLevelHashMap_dhp_md5; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_md5 > MultiLevelHashMap_rcu_gpi_md5; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_md5 > MultiLevelHashMap_rcu_gpb_md5; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_md5 > MultiLevelHashMap_rcu_gpt_md5; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_md5 > MultiLevelHashMap_rcu_shb_md5; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_md5 > MultiLevelHashMap_rcu_sht_md5; -#endif - - struct traits_MultiLevelHashMap_md5_stat : public traits_MultiLevelHashMap_md5 - { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_md5_stat > MultiLevelHashMap_hp_md5_stat; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_md5_stat > MultiLevelHashMap_dhp_md5_stat; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_md5_stat > MultiLevelHashMap_rcu_gpi_md5_stat; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_md5_stat > MultiLevelHashMap_rcu_gpb_md5_stat; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_md5_stat > MultiLevelHashMap_rcu_gpt_md5_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_md5_stat > MultiLevelHashMap_rcu_shb_md5_stat; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_md5_stat > MultiLevelHashMap_rcu_sht_md5_stat; -#endif - - // CityHash -#if CDS_BUILD_BITS == 64 - struct traits_MultiLevelHashMap_city64 : public cc::multilevel_hashmap::traits - { - typedef ::hashing::city64 hash; - typedef ::hashing::city64::less less; - }; - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_city64 > MultiLevelHashMap_hp_city64; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_city64 > MultiLevelHashMap_dhp_city64; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_city64 > MultiLevelHashMap_rcu_gpi_city64; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_city64 > MultiLevelHashMap_rcu_gpb_city64; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_city64 > MultiLevelHashMap_rcu_gpt_city64; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_city64 > MultiLevelHashMap_rcu_shb_city64; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_city64 > MultiLevelHashMap_rcu_sht_city64; -#endif - - struct traits_MultiLevelHashMap_city64_stat : public traits_MultiLevelHashMap_city64 - { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_city64_stat > MultiLevelHashMap_hp_city64_stat; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_city64_stat > MultiLevelHashMap_dhp_city64_stat; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_city64_stat > MultiLevelHashMap_rcu_gpi_city64_stat; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_city64_stat > MultiLevelHashMap_rcu_gpb_city64_stat; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_city64_stat > MultiLevelHashMap_rcu_gpt_city64_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_city64_stat > MultiLevelHashMap_rcu_shb_city64_stat; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_city64_stat > MultiLevelHashMap_rcu_sht_city64_stat; -#endif - - struct traits_MultiLevelHashMap_city128 : public cc::multilevel_hashmap::traits - { - typedef ::hashing::city128 hash; - typedef ::hashing::city128::less less; - }; - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_city128 > MultiLevelHashMap_hp_city128; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_city128 > MultiLevelHashMap_dhp_city128; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_city128 > MultiLevelHashMap_rcu_gpi_city128; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_city128 > MultiLevelHashMap_rcu_gpb_city128; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_city128 > MultiLevelHashMap_rcu_gpt_city128; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_city128 > MultiLevelHashMap_rcu_shb_city128; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_city128 > MultiLevelHashMap_rcu_sht_city128; -#endif - - struct traits_MultiLevelHashMap_city128_stat : public traits_MultiLevelHashMap_city128 - { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_city128_stat > MultiLevelHashMap_hp_city128_stat; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_city128_stat > MultiLevelHashMap_dhp_city128_stat; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_city128_stat > MultiLevelHashMap_rcu_gpi_city128_stat; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_city128_stat > MultiLevelHashMap_rcu_gpb_city128_stat; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_city128_stat > MultiLevelHashMap_rcu_gpt_city128_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_city128_stat > MultiLevelHashMap_rcu_shb_city128_stat; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_city128_stat > MultiLevelHashMap_rcu_sht_city128_stat; -#endif -#endif // CDS_BUILD_BITS == 64 - - - // for fixed-sized keys - no hash functor required - typedef MultiLevelHashMap< cds::gc::HP, Key, Value > MultiLevelHashMap_hp_fixed; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value > MultiLevelHashMap_dhp_fixed; - typedef MultiLevelHashMap< rcu_gpi, Key, Value > MultiLevelHashMap_rcu_gpi_fixed; - typedef MultiLevelHashMap< rcu_gpb, Key, Value > MultiLevelHashMap_rcu_gpb_fixed; - typedef MultiLevelHashMap< rcu_gpt, Key, Value > MultiLevelHashMap_rcu_gpt_fixed; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value > MultiLevelHashMap_rcu_shb_fixed; - typedef MultiLevelHashMap< rcu_sht, Key, Value > MultiLevelHashMap_rcu_sht_fixed; -#endif - - struct traits_MultiLevelHashMap_stat : public cc::multilevel_hashmap::traits - { - typedef cc::multilevel_hashmap::stat<> stat; - }; - typedef MultiLevelHashMap< cds::gc::HP, Key, Value, traits_MultiLevelHashMap_stat > MultiLevelHashMap_hp_fixed_stat; - typedef MultiLevelHashMap< cds::gc::DHP, Key, Value, traits_MultiLevelHashMap_stat > MultiLevelHashMap_dhp_fixed_stat; - typedef MultiLevelHashMap< rcu_gpi, Key, Value, traits_MultiLevelHashMap_stat > MultiLevelHashMap_rcu_gpi_fixed_stat; - typedef MultiLevelHashMap< rcu_gpb, Key, Value, traits_MultiLevelHashMap_stat > MultiLevelHashMap_rcu_gpb_fixed_stat; - typedef MultiLevelHashMap< rcu_gpt, Key, Value, traits_MultiLevelHashMap_stat > MultiLevelHashMap_rcu_gpt_fixed_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashMap< rcu_shb, Key, Value, traits_MultiLevelHashMap_stat > MultiLevelHashMap_rcu_shb_fixed_stat; - typedef MultiLevelHashMap< rcu_sht, Key, Value, traits_MultiLevelHashMap_stat > MultiLevelHashMap_rcu_sht_fixed_stat; -#endif - - }; - - template - static inline void print_stat( MultiLevelHashMap< GC, K, T, Traits > const& m ) - { - CPPUNIT_MSG( m.statistics() ); - } - -} // namespace map2 - -#endif // #ifndef CDSUNIT_MAP_TYPE_MULTILEVEL_HASHMAP_H diff --git a/tests/unit/print_multilevel_hashset_stat.h b/tests/unit/print_feldman_hashset_stat.h similarity index 84% rename from tests/unit/print_multilevel_hashset_stat.h rename to tests/unit/print_feldman_hashset_stat.h index 5fe06af3..73560dec 100644 --- a/tests/unit/print_multilevel_hashset_stat.h +++ b/tests/unit/print_feldman_hashset_stat.h @@ -1,17 +1,17 @@ //$$CDS-header$$ -#ifndef CDSUNIT_PRINT_MULTILEVEL_HASHSET_STAT_H -#define CDSUNIT_PRINT_MULTILEVEL_HASHSET_STAT_H +#ifndef CDSUNIT_PRINT_FELDMAN_HASHSET_STAT_H +#define CDSUNIT_PRINT_FELDMAN_HASHSET_STAT_H -#include +#include #include namespace std { - static inline ostream& operator <<( ostream& o, cds::intrusive::multilevel_hashset::stat<> const& s ) + static inline ostream& operator <<( ostream& o, cds::intrusive::feldman_hashset::stat<> const& s ) { return - o << "Stat [cds::intrusive::multilevel_hashset::stat]\n" + o << "Stat [cds::intrusive::feldman_hashset::stat]\n" << "\t\t m_nInsertSuccess: " << s.m_nInsertSuccess.get() << "\n" << "\t\t m_nInsertFailed: " << s.m_nInsertFailed.get() << "\n" << "\t\t m_nInsertRetry: " << s.m_nInsertRetry.get() << "\n" @@ -32,11 +32,11 @@ namespace std { << "\t\t m_nHeight: " << s.m_nHeight.get() << "\n"; } - static inline ostream& operator <<( ostream& o, cds::intrusive::multilevel_hashset::empty_stat const& /*s*/ ) + static inline ostream& operator <<( ostream& o, cds::intrusive::feldman_hashset::empty_stat const& /*s*/ ) { return o; } } // namespace std -#endif // #ifndef CDSUNIT_PRINT_MULTILEVEL_HASHSET_STAT_H +#endif // #ifndef CDSUNIT_PRINT_FELDMAN_HASHSET_STAT_H diff --git a/tests/unit/set2/CMakeLists.txt b/tests/unit/set2/CMakeLists.txt index e7b7ea06..89e71cf1 100644 --- a/tests/unit/set2/CMakeLists.txt +++ b/tests/unit/set2/CMakeLists.txt @@ -5,7 +5,7 @@ set(CDSUNIT_SET_SOURCES set_insdel_func_cuckoo.cpp set_insdel_func_ellentree.cpp set_insdel_func_michael.cpp - set_insdel_func_multilevelhashset.cpp + set_insdel_func_feldmanhashset.cpp set_insdel_func_skip.cpp set_insdel_func_split.cpp set_insdel_func_striped.cpp @@ -13,7 +13,7 @@ set(CDSUNIT_SET_SOURCES set_insdel_string_cuckoo.cpp set_insdel_string_ellentree.cpp set_insdel_string_michael.cpp - set_insdel_string_multilevelhashset.cpp + set_insdel_string_feldmanhashset.cpp set_insdel_string_skip.cpp set_insdel_string_split.cpp set_insdel_string_striped.cpp @@ -22,7 +22,7 @@ set(CDSUNIT_SET_SOURCES set_insdelfind_cuckoo.cpp set_insdelfind_ellentree.cpp set_insdelfind_michael.cpp - set_insdelfind_multilevelhashset.cpp + set_insdelfind_feldmanhashset.cpp set_insdelfind_skip.cpp set_insdelfind_split.cpp set_insdelfind_striped.cpp @@ -31,7 +31,7 @@ set(CDSUNIT_SET_SOURCES set_delodd_cuckoo.cpp set_delodd_ellentree.cpp set_delodd_michael.cpp - set_delodd_multilevelhashset.cpp + set_delodd_feldmanhashset.cpp set_delodd_skip.cpp set_delodd_split.cpp ) diff --git a/tests/unit/set2/set_defs.h b/tests/unit/set2/set_defs.h index 478ce052..ce1f9c1e 100644 --- a/tests/unit/set2/set_defs.h +++ b/tests/unit/set2/set_defs.h @@ -616,311 +616,311 @@ //*********************************************** -// MultiLevelHashSet +// FeldmanHashSet // For fixed-sized key - no hash function is needed -#undef CDSUNIT_DECLARE_MultiLevelHashSet_fixed -#undef CDSUNIT_DECLARE_MultiLevelHashSet_fixed_RCU_signal -#undef CDSUNIT_TEST_MultiLevelHashSet_fixed -#undef CDSUNIT_TEST_MultiLevelHashSet_fixed_RCU_signal +#undef CDSUNIT_DECLARE_FeldmanHashSet_fixed +#undef CDSUNIT_DECLARE_FeldmanHashSet_fixed_RCU_signal +#undef CDSUNIT_TEST_FeldmanHashSet_fixed +#undef CDSUNIT_TEST_FeldmanHashSet_fixed_RCU_signal #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashSet_fixed_RCU_signal \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_fixed) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_fixed) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_fixed_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashSet_fixed_RCU_signal \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_fixed) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_fixed) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_fixed_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashSet_fixed_RCU_signal \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_fixed) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_fixed_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_fixed) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_fixed_stat) \ + +# define CDSUNIT_TEST_FeldmanHashSet_fixed_RCU_signal \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_fixed) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_fixed_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_fixed) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_fixed_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashSet_fixed_RCU_signal -# define CDSUNIT_TEST_MultiLevelHashSet_fixed_RCU_signal +# define CDSUNIT_DECLARE_FeldmanHashSet_fixed_RCU_signal +# define CDSUNIT_TEST_FeldmanHashSet_fixed_RCU_signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashSet_fixed \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_fixed) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_fixed) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_fixed) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_fixed) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_fixed_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_fixed) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_fixed_stat) \ - CDSUNIT_DECLARE_MultiLevelHashSet_fixed_RCU_signal - -#define CDSUNIT_TEST_MultiLevelHashSet_fixed \ - CPPUNIT_TEST(MultiLevelHashSet_hp_fixed) \ - CPPUNIT_TEST(MultiLevelHashSet_hp_fixed_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_fixed) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_fixed_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_fixed) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_fixed_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_fixed) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_fixed_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_fixed) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_fixed_stat) \ - CDSUNIT_TEST_MultiLevelHashSet_fixed_RCU_signal +#define CDSUNIT_DECLARE_FeldmanHashSet_fixed \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_fixed) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_fixed_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_fixed) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_fixed_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_fixed) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_fixed_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_fixed) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_fixed_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_fixed) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_fixed_stat) \ + CDSUNIT_DECLARE_FeldmanHashSet_fixed_RCU_signal + +#define CDSUNIT_TEST_FeldmanHashSet_fixed \ + CPPUNIT_TEST(FeldmanHashSet_hp_fixed) \ + CPPUNIT_TEST(FeldmanHashSet_hp_fixed_stat) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_fixed) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_fixed_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_fixed) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_fixed_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_fixed) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_fixed_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_fixed) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_fixed_stat) \ + CDSUNIT_TEST_FeldmanHashSet_fixed_RCU_signal // std::hash -#undef CDSUNIT_DECLARE_MultiLevelHashSet_stdhash -#undef CDSUNIT_DECLARE_MultiLevelHashSet_stdhash_RCU_signal -#undef CDSUNIT_TEST_MultiLevelHashSet_stdhash -#undef CDSUNIT_TEST_MultiLevelHashSet_stdhash_RCU_signal +#undef CDSUNIT_DECLARE_FeldmanHashSet_stdhash +#undef CDSUNIT_DECLARE_FeldmanHashSet_stdhash_RCU_signal +#undef CDSUNIT_TEST_FeldmanHashSet_stdhash +#undef CDSUNIT_TEST_FeldmanHashSet_stdhash_RCU_signal #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashSet_stdhash_RCU_signal \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_stdhash) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_stdhash) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_stdhash_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashSet_stdhash_RCU_signal \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_stdhash) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_stdhash) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_stdhash_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashSet_stdhash_RCU_signal \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_stdhash) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_stdhash) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_stdhash_stat) \ + +# define CDSUNIT_TEST_FeldmanHashSet_stdhash_RCU_signal \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_stdhash) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_stdhash) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_stdhash_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashSet_stdhash_RCU_signal -# define CDSUNIT_TEST_MultiLevelHashSet_stdhash_RCU_signal +# define CDSUNIT_DECLARE_FeldmanHashSet_stdhash_RCU_signal +# define CDSUNIT_TEST_FeldmanHashSet_stdhash_RCU_signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashSet_stdhash \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_stdhash) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_stdhash) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_stdhash) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_stdhash) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_stdhash_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_stdhash) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_stdhash_stat) \ - CDSUNIT_DECLARE_MultiLevelHashSet_stdhash_RCU_signal - -#define CDSUNIT_TEST_MultiLevelHashSet_stdhash \ - CPPUNIT_TEST(MultiLevelHashSet_hp_stdhash) \ - CPPUNIT_TEST(MultiLevelHashSet_hp_stdhash_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_stdhash) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_stdhash_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_stdhash) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_stdhash_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_stdhash) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_stdhash_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_stdhash) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_stdhash_stat) \ - CDSUNIT_TEST_MultiLevelHashSet_stdhash_RCU_signal +#define CDSUNIT_DECLARE_FeldmanHashSet_stdhash \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_stdhash) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_stdhash) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_stdhash) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_stdhash) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_stdhash_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_stdhash) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_stdhash_stat) \ + CDSUNIT_DECLARE_FeldmanHashSet_stdhash_RCU_signal + +#define CDSUNIT_TEST_FeldmanHashSet_stdhash \ + CPPUNIT_TEST(FeldmanHashSet_hp_stdhash) \ + CPPUNIT_TEST(FeldmanHashSet_hp_stdhash_stat) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_stdhash) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_stdhash_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_stdhash) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_stdhash_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_stdhash) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_stdhash_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_stdhash) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_stdhash_stat) \ + CDSUNIT_TEST_FeldmanHashSet_stdhash_RCU_signal // MD5 -#undef CDSUNIT_DECLARE_MultiLevelHashSet_md5 -#undef CDSUNIT_DECLARE_MultiLevelHashSet_md5_RCU_signal -#undef CDSUNIT_TEST_MultiLevelHashSet_md5 -#undef CDSUNIT_TEST_MultiLevelHashSet_md5_RCU_signal +#undef CDSUNIT_DECLARE_FeldmanHashSet_md5 +#undef CDSUNIT_DECLARE_FeldmanHashSet_md5_RCU_signal +#undef CDSUNIT_TEST_FeldmanHashSet_md5 +#undef CDSUNIT_TEST_FeldmanHashSet_md5_RCU_signal #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashSet_md5_RCU_signal \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_md5) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_md5_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_md5) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_md5_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashSet_md5_RCU_signal \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_md5) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_md5_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_md5) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_md5_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashSet_md5_RCU_signal \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_md5) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_md5_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_md5) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_md5_stat) \ + +# define CDSUNIT_TEST_FeldmanHashSet_md5_RCU_signal \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_md5) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_md5_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_md5) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_md5_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashSet_md5_RCU_signal -# define CDSUNIT_TEST_MultiLevelHashSet_md5_RCU_signal +# define CDSUNIT_DECLARE_FeldmanHashSet_md5_RCU_signal +# define CDSUNIT_TEST_FeldmanHashSet_md5_RCU_signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashSet_md5 \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_md5) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_md5_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_md5) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_md5_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_md5) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_md5_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_md5) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_md5_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_md5) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_md5_stat) \ - CDSUNIT_DECLARE_MultiLevelHashSet_md5_RCU_signal - -#define CDSUNIT_TEST_MultiLevelHashSet_md5 \ - CPPUNIT_TEST(MultiLevelHashSet_hp_md5) \ - CPPUNIT_TEST(MultiLevelHashSet_hp_md5_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_md5) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_md5_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_md5) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_md5_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_md5) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_md5_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_md5) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_md5_stat) \ - CDSUNIT_TEST_MultiLevelHashSet_md5_RCU_signal +#define CDSUNIT_DECLARE_FeldmanHashSet_md5 \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_md5) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_md5_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_md5) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_md5_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_md5) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_md5_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_md5) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_md5_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_md5) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_md5_stat) \ + CDSUNIT_DECLARE_FeldmanHashSet_md5_RCU_signal + +#define CDSUNIT_TEST_FeldmanHashSet_md5 \ + CPPUNIT_TEST(FeldmanHashSet_hp_md5) \ + CPPUNIT_TEST(FeldmanHashSet_hp_md5_stat) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_md5) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_md5_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_md5) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_md5_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_md5) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_md5_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_md5) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_md5_stat) \ + CDSUNIT_TEST_FeldmanHashSet_md5_RCU_signal // SHA256 -#undef CDSUNIT_DECLARE_MultiLevelHashSet_sha256 -#undef CDSUNIT_DECLARE_MultiLevelHashSet_sha256_RCU_signal -#undef CDSUNIT_TEST_MultiLevelHashSet_sha256 -#undef CDSUNIT_TEST_MultiLevelHashSet_sha256_RCU_signal +#undef CDSUNIT_DECLARE_FeldmanHashSet_sha256 +#undef CDSUNIT_DECLARE_FeldmanHashSet_sha256_RCU_signal +#undef CDSUNIT_TEST_FeldmanHashSet_sha256 +#undef CDSUNIT_TEST_FeldmanHashSet_sha256_RCU_signal #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashSet_sha256_RCU_signal \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_sha256) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_sha256) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_sha256_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashSet_sha256_RCU_signal \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_sha256) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_sha256) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_sha256_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashSet_sha256_RCU_signal \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_sha256) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_sha256_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_sha256) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_sha256_stat) \ + +# define CDSUNIT_TEST_FeldmanHashSet_sha256_RCU_signal \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_sha256) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_sha256_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_sha256) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_sha256_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashSet_sha256_RCU_signal -# define CDSUNIT_TEST_MultiLevelHashSet_sha256_RCU_signal +# define CDSUNIT_DECLARE_FeldmanHashSet_sha256_RCU_signal +# define CDSUNIT_TEST_FeldmanHashSet_sha256_RCU_signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashSet_sha256 \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_sha256) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_sha256) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_sha256) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_sha256) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_sha256_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_sha256) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_sha256_stat) \ - CDSUNIT_DECLARE_MultiLevelHashSet_sha256_RCU_signal - -#define CDSUNIT_TEST_MultiLevelHashSet_sha256 \ - CPPUNIT_TEST(MultiLevelHashSet_hp_sha256) \ - CPPUNIT_TEST(MultiLevelHashSet_hp_sha256_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_sha256) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_sha256_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_sha256) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_sha256_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_sha256) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_sha256_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_sha256) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_sha256_stat) \ - CDSUNIT_TEST_MultiLevelHashSet_sha256_RCU_signal +#define CDSUNIT_DECLARE_FeldmanHashSet_sha256 \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_sha256) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_sha256_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_sha256) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_sha256_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_sha256) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_sha256_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_sha256) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_sha256_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_sha256) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_sha256_stat) \ + CDSUNIT_DECLARE_FeldmanHashSet_sha256_RCU_signal + +#define CDSUNIT_TEST_FeldmanHashSet_sha256 \ + CPPUNIT_TEST(FeldmanHashSet_hp_sha256) \ + CPPUNIT_TEST(FeldmanHashSet_hp_sha256_stat) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_sha256) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_sha256_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_sha256) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_sha256_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_sha256) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_sha256_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_sha256) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_sha256_stat) \ + CDSUNIT_TEST_FeldmanHashSet_sha256_RCU_signal // CityHash -only for 64bit -#undef CDSUNIT_DECLARE_MultiLevelHashSet_city -#undef CDSUNIT_DECLARE_MultiLevelHashSet_city_RCU_signal -#undef CDSUNIT_TEST_MultiLevelHashSet_city -#undef CDSUNIT_TEST_MultiLevelHashSet_city_RCU_signal +#undef CDSUNIT_DECLARE_FeldmanHashSet_city +#undef CDSUNIT_DECLARE_FeldmanHashSet_city_RCU_signal +#undef CDSUNIT_TEST_FeldmanHashSet_city +#undef CDSUNIT_TEST_FeldmanHashSet_city_RCU_signal #if CDS_BUILD_BITS == 64 #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED -# define CDSUNIT_DECLARE_MultiLevelHashSet_city_RCU_signal \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_city64) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_city64_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_city64) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_city64_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_city128) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_city128_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_city128) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_city128_stat) \ - -# define CDSUNIT_TEST_MultiLevelHashSet_city_RCU_signal \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_city64) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_city64_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_city64) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_city64_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_city128) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_shb_city128_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_city128) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_sht_city128_stat) \ +# define CDSUNIT_DECLARE_FeldmanHashSet_city_RCU_signal \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_city64) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_city64_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_city64) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_city64_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_city128) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_city128_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_city128) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_city128_stat) \ + +# define CDSUNIT_TEST_FeldmanHashSet_city_RCU_signal \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_city64) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_city64_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_city64) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_city64_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_city128) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_shb_city128_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_city128) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_sht_city128_stat) \ #else -# define CDSUNIT_DECLARE_MultiLevelHashSet_city_RCU_signal -# define CDSUNIT_TEST_MultiLevelHashSet_city_RCU_signal +# define CDSUNIT_DECLARE_FeldmanHashSet_city_RCU_signal +# define CDSUNIT_TEST_FeldmanHashSet_city_RCU_signal #endif -#define CDSUNIT_DECLARE_MultiLevelHashSet_city \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_city64) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_city64_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_city64) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_city64_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_city64) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_city64_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_city64) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_city64_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_city64) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_city64_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_city128) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_hp_city128_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_city128) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_dhp_city128_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_city128) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpi_city128_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_city128) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpb_city128_stat) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_city128) \ - TEST_CASE(tag_MultiLevelHashSet, MultiLevelHashSet_rcu_gpt_city128_stat) \ - CDSUNIT_DECLARE_MultiLevelHashSet_city_RCU_signal - -#define CDSUNIT_TEST_MultiLevelHashSet_city \ - CPPUNIT_TEST(MultiLevelHashSet_hp_city64) \ - CPPUNIT_TEST(MultiLevelHashSet_hp_city64_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_city64) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_city64_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_city64) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_city64_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_city64) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_city64_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_city64) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_city64_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_hp_city128) \ - CPPUNIT_TEST(MultiLevelHashSet_hp_city128_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_city128) \ - CPPUNIT_TEST(MultiLevelHashSet_dhp_city128_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_city128) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpi_city128_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_city128) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpb_city128_stat) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_city128) \ - CPPUNIT_TEST(MultiLevelHashSet_rcu_gpt_city128_stat) \ - CDSUNIT_TEST_MultiLevelHashSet_city_RCU_signal +#define CDSUNIT_DECLARE_FeldmanHashSet_city \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_city64) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_city64_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_city64) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_city64_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_city64) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_city64_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_city64) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_city64_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_city64) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_city64_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_city128) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_hp_city128_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_city128) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_dhp_city128_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_city128) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpi_city128_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_city128) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpb_city128_stat) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_city128) \ + TEST_CASE(tag_FeldmanHashSet, FeldmanHashSet_rcu_gpt_city128_stat) \ + CDSUNIT_DECLARE_FeldmanHashSet_city_RCU_signal + +#define CDSUNIT_TEST_FeldmanHashSet_city \ + CPPUNIT_TEST(FeldmanHashSet_hp_city64) \ + CPPUNIT_TEST(FeldmanHashSet_hp_city64_stat) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_city64) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_city64_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_city64) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_city64_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_city64) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_city64_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_city64) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_city64_stat) \ + CPPUNIT_TEST(FeldmanHashSet_hp_city128) \ + CPPUNIT_TEST(FeldmanHashSet_hp_city128_stat) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_city128) \ + CPPUNIT_TEST(FeldmanHashSet_dhp_city128_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_city128) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpi_city128_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_city128) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpb_city128_stat) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_city128) \ + CPPUNIT_TEST(FeldmanHashSet_rcu_gpt_city128_stat) \ + CDSUNIT_TEST_FeldmanHashSet_city_RCU_signal #else -# define CDSUNIT_DECLARE_MultiLevelHashSet_city -# define CDSUNIT_DECLARE_MultiLevelHashSet_city_RCU_signal -# define CDSUNIT_TEST_MultiLevelHashSet_city -# define CDSUNIT_TEST_MultiLevelHashSet_city_RCU_signal +# define CDSUNIT_DECLARE_FeldmanHashSet_city +# define CDSUNIT_DECLARE_FeldmanHashSet_city_RCU_signal +# define CDSUNIT_TEST_FeldmanHashSet_city +# define CDSUNIT_TEST_FeldmanHashSet_city_RCU_signal #endif // CDS_BUILD_BITS == 64 // All -#define CDSUNIT_DECLARE_MultiLevelHashSet \ - CDSUNIT_DECLARE_MultiLevelHashSet_fixed \ - CDSUNIT_DECLARE_MultiLevelHashSet_stdhash \ - CDSUNIT_DECLARE_MultiLevelHashSet_md5 \ - CDSUNIT_DECLARE_MultiLevelHashSet_sha256 \ - CDSUNIT_DECLARE_MultiLevelHashSet_city - -#define CDSUNIT_TEST_MultiLevelHashSet \ - CDSUNIT_TEST_MultiLevelHashSet_fixed \ - CDSUNIT_TEST_MultiLevelHashSet_stdhash \ - CDSUNIT_TEST_MultiLevelHashSet_md5 \ - CDSUNIT_TEST_MultiLevelHashSet_sha256 \ - CDSUNIT_TEST_MultiLevelHashSet_city +#define CDSUNIT_DECLARE_FeldmanHashSet \ + CDSUNIT_DECLARE_FeldmanHashSet_fixed \ + CDSUNIT_DECLARE_FeldmanHashSet_stdhash \ + CDSUNIT_DECLARE_FeldmanHashSet_md5 \ + CDSUNIT_DECLARE_FeldmanHashSet_sha256 \ + CDSUNIT_DECLARE_FeldmanHashSet_city + +#define CDSUNIT_TEST_FeldmanHashSet \ + CDSUNIT_TEST_FeldmanHashSet_fixed \ + CDSUNIT_TEST_FeldmanHashSet_stdhash \ + CDSUNIT_TEST_FeldmanHashSet_md5 \ + CDSUNIT_TEST_FeldmanHashSet_sha256 \ + CDSUNIT_TEST_FeldmanHashSet_city diff --git a/tests/unit/set2/set_delodd.cpp b/tests/unit/set2/set_delodd.cpp index db240612..f2b89d86 100644 --- a/tests/unit/set2/set_delodd.cpp +++ b/tests/unit/set2/set_delodd.cpp @@ -18,8 +18,8 @@ namespace set2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize ); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold ); - c_nMultiLevelSet_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelSet_HeadBits); - c_nMultiLevelSet_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelSet_ArrayBits); + c_nFeldmanSet_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanSet_HeadBits); + c_nFeldmanSet_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanSet_ArrayBits); if ( c_nInsThreadCount == 0 ) c_nInsThreadCount = std::thread::hardware_concurrency(); diff --git a/tests/unit/set2/set_delodd.h b/tests/unit/set2/set_delodd.h index 2edf537a..b9d7a87a 100644 --- a/tests/unit/set2/set_delodd.h +++ b/tests/unit/set2/set_delodd.h @@ -128,8 +128,8 @@ namespace set2 { size_t c_nCuckooProbesetSize = 16; // CuckooSet probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooSet probeset threshold (0 - use default) - size_t c_nMultiLevelSet_HeadBits = 10; - size_t c_nMultiLevelSet_ArrayBits = 4; + size_t c_nFeldmanSet_HeadBits = 10; + size_t c_nFeldmanSet_ArrayBits = 4; size_t c_nLoadFactor = 2; std::vector m_arrData; @@ -795,16 +795,16 @@ namespace set2 { CDSUNIT_DECLARE_SkipListSet CDSUNIT_DECLARE_EllenBinTreeSet CDSUNIT_DECLARE_CuckooSet - CDSUNIT_DECLARE_MultiLevelHashSet_fixed - CDSUNIT_DECLARE_MultiLevelHashSet_city + CDSUNIT_DECLARE_FeldmanHashSet_fixed + CDSUNIT_DECLARE_FeldmanHashSet_city CPPUNIT_TEST_SUITE_(Set_DelOdd, "Map_DelOdd") CDSUNIT_TEST_MichaelSet CDSUNIT_TEST_SplitList CDSUNIT_TEST_SkipListSet CDSUNIT_TEST_EllenBinTreeSet - CDSUNIT_TEST_MultiLevelHashSet_fixed - CDSUNIT_TEST_MultiLevelHashSet_city + CDSUNIT_TEST_FeldmanHashSet_fixed + CDSUNIT_TEST_FeldmanHashSet_city CDSUNIT_TEST_CuckooSet CPPUNIT_TEST_SUITE_END(); }; diff --git a/tests/unit/set2/set_delodd_multilevelhashset.cpp b/tests/unit/set2/set_delodd_feldmanhashset.cpp similarity index 65% rename from tests/unit/set2/set_delodd_multilevelhashset.cpp rename to tests/unit/set2/set_delodd_feldmanhashset.cpp index bef43b67..36e21bd4 100644 --- a/tests/unit/set2/set_delodd_multilevelhashset.cpp +++ b/tests/unit/set2/set_delodd_feldmanhashset.cpp @@ -1,13 +1,13 @@ //$$CDS-header$$ #include "set2/set_delodd.h" -#include "set2/set_type_multilevel_hashset.h" +#include "set2/set_type_feldman_hashset.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Set_DelOdd::X() { run_test_extract::X>(); } #include "set2/set_defs.h" namespace set2 { - CDSUNIT_DECLARE_MultiLevelHashSet_fixed - CDSUNIT_DECLARE_MultiLevelHashSet_city + CDSUNIT_DECLARE_FeldmanHashSet_fixed + CDSUNIT_DECLARE_FeldmanHashSet_city } // namespace set2 diff --git a/tests/unit/set2/set_insdel_func.cpp b/tests/unit/set2/set_insdel_func.cpp index 02773f1e..ee25b908 100644 --- a/tests/unit/set2/set_insdel_func.cpp +++ b/tests/unit/set2/set_insdel_func.cpp @@ -19,8 +19,8 @@ namespace set2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize ); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold ); - c_nMultiLevelSet_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelSet_HeadBits); - c_nMultiLevelSet_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelSet_ArrayBits); + c_nFeldmanSet_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanSet_HeadBits); + c_nFeldmanSet_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanSet_ArrayBits); if ( c_nInsertThreadCount == 0 ) c_nInsertThreadCount = std::thread::hardware_concurrency(); diff --git a/tests/unit/set2/set_insdel_func.h b/tests/unit/set2/set_insdel_func.h index 7aba9bbe..e0479788 100644 --- a/tests/unit/set2/set_insdel_func.h +++ b/tests/unit/set2/set_insdel_func.h @@ -27,8 +27,8 @@ namespace set2 { size_t c_nCuckooProbesetSize = 16; // CuckooSet probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooSet probeset threshold (0 - use default) - size_t c_nMultiLevelSet_HeadBits = 10; - size_t c_nMultiLevelSet_ArrayBits = 4; + size_t c_nFeldmanSet_HeadBits = 10; + size_t c_nFeldmanSet_ArrayBits = 4; size_t c_nLoadFactor = 2; @@ -549,15 +549,15 @@ namespace set2 { CDSUNIT_DECLARE_RefinableSet CDSUNIT_DECLARE_CuckooSet CDSUNIT_DECLARE_EllenBinTreeSet - CDSUNIT_DECLARE_MultiLevelHashSet_fixed - CDSUNIT_DECLARE_MultiLevelHashSet_city + CDSUNIT_DECLARE_FeldmanHashSet_fixed + CDSUNIT_DECLARE_FeldmanHashSet_city CPPUNIT_TEST_SUITE_(Set_InsDel_func, "Map_InsDel_func") CDSUNIT_TEST_MichaelSet CDSUNIT_TEST_SplitList CDSUNIT_TEST_SkipListSet - CDSUNIT_TEST_MultiLevelHashSet_fixed - CDSUNIT_TEST_MultiLevelHashSet_city + CDSUNIT_TEST_FeldmanHashSet_fixed + CDSUNIT_TEST_FeldmanHashSet_city CDSUNIT_TEST_EllenBinTreeSet CDSUNIT_TEST_StripedSet CDSUNIT_TEST_RefinableSet diff --git a/tests/unit/set2/set_insdel_func_multilevelhashset.cpp b/tests/unit/set2/set_insdel_func_feldmanhashset.cpp similarity index 65% rename from tests/unit/set2/set_insdel_func_multilevelhashset.cpp rename to tests/unit/set2/set_insdel_func_feldmanhashset.cpp index f7e818b3..9610a4ce 100644 --- a/tests/unit/set2/set_insdel_func_multilevelhashset.cpp +++ b/tests/unit/set2/set_insdel_func_feldmanhashset.cpp @@ -1,13 +1,13 @@ //$$CDS-header$$ #include "set2/set_insdel_func.h" -#include "set2/set_type_multilevel_hashset.h" +#include "set2/set_type_feldman_hashset.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Set_InsDel_func::X() { run_test::X>(); } #include "set2/set_defs.h" namespace set2 { - CDSUNIT_DECLARE_MultiLevelHashSet_fixed - CDSUNIT_DECLARE_MultiLevelHashSet_city + CDSUNIT_DECLARE_FeldmanHashSet_fixed + CDSUNIT_DECLARE_FeldmanHashSet_city } // namespace set2 diff --git a/tests/unit/set2/set_insdel_string.cpp b/tests/unit/set2/set_insdel_string.cpp index f20d5205..ac11081b 100644 --- a/tests/unit/set2/set_insdel_string.cpp +++ b/tests/unit/set2/set_insdel_string.cpp @@ -18,8 +18,8 @@ namespace set2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize ); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold ); - c_nMultiLevelSet_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelSet_HeadBits); - c_nMultiLevelSet_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelSet_ArrayBits); + c_nFeldmanSet_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanSet_HeadBits); + c_nFeldmanSet_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanSet_ArrayBits); if ( c_nInsertThreadCount == 0 ) c_nInsertThreadCount = std::thread::hardware_concurrency(); diff --git a/tests/unit/set2/set_insdel_string.h b/tests/unit/set2/set_insdel_string.h index b76d698f..6ab2f420 100644 --- a/tests/unit/set2/set_insdel_string.h +++ b/tests/unit/set2/set_insdel_string.h @@ -23,8 +23,8 @@ namespace set2 { size_t c_nCuckooProbesetSize = 16; // CuckooSet probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooSet probeset threshold (0 - use default) - size_t c_nMultiLevelSet_HeadBits = 10; - size_t c_nMultiLevelSet_ArrayBits = 4; + size_t c_nFeldmanSet_HeadBits = 10; + size_t c_nFeldmanSet_ArrayBits = 4; size_t c_nLoadFactor = 2; @@ -517,20 +517,20 @@ namespace set2 { CDSUNIT_DECLARE_CuckooSet CDSUNIT_DECLARE_SkipListSet CDSUNIT_DECLARE_EllenBinTreeSet - CDSUNIT_DECLARE_MultiLevelHashSet_stdhash - CDSUNIT_DECLARE_MultiLevelHashSet_md5 - CDSUNIT_DECLARE_MultiLevelHashSet_sha256 - CDSUNIT_DECLARE_MultiLevelHashSet_city + CDSUNIT_DECLARE_FeldmanHashSet_stdhash + CDSUNIT_DECLARE_FeldmanHashSet_md5 + CDSUNIT_DECLARE_FeldmanHashSet_sha256 + CDSUNIT_DECLARE_FeldmanHashSet_city CDSUNIT_DECLARE_StdSet CPPUNIT_TEST_SUITE_(Set_InsDel_string, "Map_InsDel_func") CDSUNIT_TEST_MichaelSet CDSUNIT_TEST_SplitList CDSUNIT_TEST_SkipListSet - CDSUNIT_TEST_MultiLevelHashSet_stdhash - CDSUNIT_TEST_MultiLevelHashSet_md5 - CDSUNIT_TEST_MultiLevelHashSet_sha256 - CDSUNIT_TEST_MultiLevelHashSet_city + CDSUNIT_TEST_FeldmanHashSet_stdhash + CDSUNIT_TEST_FeldmanHashSet_md5 + CDSUNIT_TEST_FeldmanHashSet_sha256 + CDSUNIT_TEST_FeldmanHashSet_city CDSUNIT_TEST_EllenBinTreeSet CDSUNIT_TEST_StripedSet CDSUNIT_TEST_RefinableSet diff --git a/tests/unit/set2/set_insdel_string_multilevelhashset.cpp b/tests/unit/set2/set_insdel_string_feldmanhashset.cpp similarity index 54% rename from tests/unit/set2/set_insdel_string_multilevelhashset.cpp rename to tests/unit/set2/set_insdel_string_feldmanhashset.cpp index 5050b872..e9becc45 100644 --- a/tests/unit/set2/set_insdel_string_multilevelhashset.cpp +++ b/tests/unit/set2/set_insdel_string_feldmanhashset.cpp @@ -1,15 +1,15 @@ //$$CDS-header$$ #include "set2/set_insdel_string.h" -#include "set2/set_type_multilevel_hashset.h" +#include "set2/set_type_feldman_hashset.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Set_InsDel_string::X() { run_test_extract::X>(); } #include "set2/set_defs.h" namespace set2 { - CDSUNIT_DECLARE_MultiLevelHashSet_stdhash - CDSUNIT_DECLARE_MultiLevelHashSet_md5 - CDSUNIT_DECLARE_MultiLevelHashSet_sha256 - CDSUNIT_DECLARE_MultiLevelHashSet_city + CDSUNIT_DECLARE_FeldmanHashSet_stdhash + CDSUNIT_DECLARE_FeldmanHashSet_md5 + CDSUNIT_DECLARE_FeldmanHashSet_sha256 + CDSUNIT_DECLARE_FeldmanHashSet_city } // namespace set2 diff --git a/tests/unit/set2/set_insdelfind.cpp b/tests/unit/set2/set_insdelfind.cpp index df6a559a..ed71911b 100644 --- a/tests/unit/set2/set_insdelfind.cpp +++ b/tests/unit/set2/set_insdelfind.cpp @@ -19,8 +19,8 @@ namespace set2 { c_nCuckooProbesetSize = cfg.getSizeT("CuckooProbesetSize", c_nCuckooProbesetSize ); c_nCuckooProbesetThreshold = cfg.getSizeT("CuckooProbesetThreshold", c_nCuckooProbesetThreshold ); - c_nMultiLevelSet_HeadBits = cfg.getSizeT("MultiLevelMapHeadBits", c_nMultiLevelSet_HeadBits); - c_nMultiLevelSet_ArrayBits = cfg.getSizeT("MultiLevelMapArrayBits", c_nMultiLevelSet_ArrayBits); + c_nFeldmanSet_HeadBits = cfg.getSizeT("FeldmanMapHeadBits", c_nFeldmanSet_HeadBits); + c_nFeldmanSet_ArrayBits = cfg.getSizeT("FeldmanMapArrayBits", c_nFeldmanSet_ArrayBits); if ( c_nThreadCount == 0 ) c_nThreadCount = std::thread::hardware_concurrency(); diff --git a/tests/unit/set2/set_insdelfind.h b/tests/unit/set2/set_insdelfind.h index 89be492f..6f0b276b 100644 --- a/tests/unit/set2/set_insdelfind.h +++ b/tests/unit/set2/set_insdelfind.h @@ -22,8 +22,8 @@ namespace set2 { size_t c_nCuckooProbesetSize = 16; // CuckooSet probeset size (only for list-based probeset) size_t c_nCuckooProbesetThreshold = 0; // CUckooSet probeset threshold (0 - use default) - size_t c_nMultiLevelSet_HeadBits = 10; - size_t c_nMultiLevelSet_ArrayBits = 4; + size_t c_nFeldmanSet_HeadBits = 10; + size_t c_nFeldmanSet_ArrayBits = 4; size_t c_nLoadFactor = 2; @@ -226,14 +226,14 @@ namespace set2 { CDSUNIT_DECLARE_CuckooSet CDSUNIT_DECLARE_SkipListSet CDSUNIT_DECLARE_EllenBinTreeSet - CDSUNIT_DECLARE_MultiLevelHashSet + CDSUNIT_DECLARE_FeldmanHashSet CDSUNIT_DECLARE_StdSet CPPUNIT_TEST_SUITE_(Set_InsDelFind, "Map_InsDelFind") CDSUNIT_TEST_MichaelSet CDSUNIT_TEST_SplitList CDSUNIT_TEST_SkipListSet - CDSUNIT_TEST_MultiLevelHashSet + CDSUNIT_TEST_FeldmanHashSet CDSUNIT_TEST_EllenBinTreeSet CDSUNIT_TEST_StripedSet CDSUNIT_TEST_RefinableSet diff --git a/tests/unit/set2/set_insdelfind_multilevelhashset.cpp b/tests/unit/set2/set_insdelfind_feldmanhashset.cpp similarity index 75% rename from tests/unit/set2/set_insdelfind_multilevelhashset.cpp rename to tests/unit/set2/set_insdelfind_feldmanhashset.cpp index 0a374821..b1befc0a 100644 --- a/tests/unit/set2/set_insdelfind_multilevelhashset.cpp +++ b/tests/unit/set2/set_insdelfind_feldmanhashset.cpp @@ -1,12 +1,12 @@ //$$CDS-header$$ #include "set2/set_insdelfind.h" -#include "set2/set_type_multilevel_hashset.h" +#include "set2/set_type_feldman_hashset.h" #undef TEST_CASE #define TEST_CASE(TAG, X) void Set_InsDelFind::X() { run_test::X>(); } #include "set2/set_defs.h" namespace set2 { - CDSUNIT_DECLARE_MultiLevelHashSet + CDSUNIT_DECLARE_FeldmanHashSet } // namespace set2 diff --git a/tests/unit/set2/set_type_feldman_hashset.h b/tests/unit/set2/set_type_feldman_hashset.h new file mode 100644 index 00000000..68066db0 --- /dev/null +++ b/tests/unit/set2/set_type_feldman_hashset.h @@ -0,0 +1,341 @@ +//$$CDS-header$$ + +#ifndef CDSUNIT_SET_TYPE_MICHAEL_H +#define CDSUNIT_SET_TYPE_MICHAEL_H + +#include "set2/set_type.h" + +#include +#include +#include + +#include "print_feldman_hashset_stat.h" +#include "hashing/hash_func.h" + +namespace set2 { + + template + class FeldmanHashSet : public cc::FeldmanHashSet< GC, T, Traits > + { + typedef cc::FeldmanHashSet< GC, T, Traits > base_class; + + template + struct get_extracted_ptr + { + typedef typename base_class::guarded_ptr extracted_ptr; + }; + + template + struct get_extracted_ptr> + { + typedef typename base_class::exempt_ptr extracted_ptr; + }; + + public: + typedef typename T::hasher hasher ; + typedef typename get_extracted_ptr::extracted_ptr extracted_ptr; + + template + FeldmanHashSet( Config const& cfg ) + : base_class( cfg.c_nFeldmanSet_HeadBits, cfg.c_nFeldmanSet_ArrayBits ) + {} + + template + bool erase( Q const& key ) + { + return base_class::erase( hasher()( key )); + } + + template + bool erase( Q const& key, Func f ) + { + return base_class::erase( hasher()( key ), f ); + } + + template + extracted_ptr extract(Q const& key) + { + return base_class::extract( hasher()(key) ); + } + + template + bool contains( Q const& key ) + { + return base_class::contains( hasher()(key) ); + } + + // for testing + static CDS_CONSTEXPR bool const c_bExtractSupported = true; + static CDS_CONSTEXPR bool const c_bLoadFactorDepended = false; + static CDS_CONSTEXPR bool const c_bEraseExactKey = true; + }; + + struct tag_FeldmanHashSet; + + template + struct set_type< tag_FeldmanHashSet, Key, Val >: public set_type_base< Key, Val > + { + typedef set_type_base< Key, Val > base_class; + typedef typename base_class::compare compare; + typedef typename base_class::less less; + typedef typename base_class::hash hash; + typedef typename base_class::key_type key_type; + typedef typename base_class::value_type value_type; + + template + struct hash_type + { + typedef Hasher hasher; + typedef typename hasher::hash_type type; + }; + + template + struct hash_type> + { + typedef std::hash hasher; + typedef size_t type; + }; + + template + struct key_val: base_class::key_val + { + typedef typename base_class::key_val base; + typedef Hasher hasher; + typedef typename hash_type::type hash_type; + + hash_type hash; + + /*explicit*/ key_val( key_type const& k ): base(k), hash( hasher()( k )) {} + key_val( key_type const& k, value_type const& v ): base(k, v), hash( hasher()( k )) {} + + template + /*explicit*/ key_val( K const& k ): base(k), hash( hasher()( k )) {} + + template + key_val( K const& k, T const& v ): base(k, v), hash( hasher()( k )) {} + }; + + struct default_traits : public cc::feldman_hashset::traits + { + struct hash_accessor { + template + typename key_val::hash_type const& operator()( key_val const& kv ) + { + return kv.hash; + } + }; + }; + + typedef FeldmanHashSet< cds::gc::HP, key_val>, default_traits > FeldmanHashSet_hp_stdhash; + typedef FeldmanHashSet< cds::gc::DHP, key_val>, default_traits > FeldmanHashSet_dhp_stdhash; + typedef FeldmanHashSet< rcu_gpi, key_val>, default_traits > FeldmanHashSet_rcu_gpi_stdhash; + typedef FeldmanHashSet< rcu_gpb, key_val>, default_traits > FeldmanHashSet_rcu_gpb_stdhash; + typedef FeldmanHashSet< rcu_gpt, key_val>, default_traits > FeldmanHashSet_rcu_gpt_stdhash; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, key_val>, default_traits > FeldmanHashSet_rcu_shb_stdhash; + typedef FeldmanHashSet< rcu_sht, key_val>, default_traits > FeldmanHashSet_rcu_sht_stdhash; +#endif + + struct traits_FeldmanHashSet_stat: public cc::feldman_hashset::make_traits< + co::type_traits< default_traits >, + co::stat< cc::feldman_hashset::stat<>> + >::type + {}; + + typedef FeldmanHashSet< cds::gc::HP, key_val>, traits_FeldmanHashSet_stat > FeldmanHashSet_hp_stdhash_stat; + typedef FeldmanHashSet< cds::gc::DHP, key_val>, traits_FeldmanHashSet_stat > FeldmanHashSet_dhp_stdhash_stat; + typedef FeldmanHashSet< rcu_gpi, key_val>, traits_FeldmanHashSet_stat > FeldmanHashSet_rcu_gpi_stdhash_stat; + typedef FeldmanHashSet< rcu_gpb, key_val>, traits_FeldmanHashSet_stat > FeldmanHashSet_rcu_gpb_stdhash_stat; + typedef FeldmanHashSet< rcu_gpt, key_val>, traits_FeldmanHashSet_stat > FeldmanHashSet_rcu_gpt_stdhash_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, key_val>, traits_FeldmanHashSet_stat > FeldmanHashSet_rcu_shb_stdhash_stat; + typedef FeldmanHashSet< rcu_sht, key_val>, traits_FeldmanHashSet_stat > FeldmanHashSet_rcu_sht_stdhash_stat; +#endif + + // SHA256 + typedef FeldmanHashSet< cds::gc::HP, key_val<::hashing::sha256>, default_traits > FeldmanHashSet_hp_sha256; + typedef FeldmanHashSet< cds::gc::DHP, key_val<::hashing::sha256>, default_traits > FeldmanHashSet_dhp_sha256; + typedef FeldmanHashSet< rcu_gpi, key_val<::hashing::sha256>, default_traits > FeldmanHashSet_rcu_gpi_sha256; + typedef FeldmanHashSet< rcu_gpb, key_val<::hashing::sha256>, default_traits > FeldmanHashSet_rcu_gpb_sha256; + typedef FeldmanHashSet< rcu_gpt, key_val<::hashing::sha256>, default_traits > FeldmanHashSet_rcu_gpt_sha256; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, key_val<::hashing::sha256>, default_traits > FeldmanHashSet_rcu_shb_sha256; + typedef FeldmanHashSet< rcu_sht, key_val<::hashing::sha256>, default_traits > FeldmanHashSet_rcu_sht_sha256; +#endif + + struct traits_FeldmanHashSet_sha256_stat : public default_traits + { + typedef cc::feldman_hashset::stat<> stat; + }; + typedef FeldmanHashSet< cds::gc::HP, key_val<::hashing::sha256>, traits_FeldmanHashSet_sha256_stat > FeldmanHashSet_hp_sha256_stat; + typedef FeldmanHashSet< cds::gc::DHP, key_val<::hashing::sha256>, traits_FeldmanHashSet_sha256_stat > FeldmanHashSet_dhp_sha256_stat; + typedef FeldmanHashSet< rcu_gpi, key_val<::hashing::sha256>, traits_FeldmanHashSet_sha256_stat > FeldmanHashSet_rcu_gpi_sha256_stat; + typedef FeldmanHashSet< rcu_gpb, key_val<::hashing::sha256>, traits_FeldmanHashSet_sha256_stat > FeldmanHashSet_rcu_gpb_sha256_stat; + typedef FeldmanHashSet< rcu_gpt, key_val<::hashing::sha256>, traits_FeldmanHashSet_sha256_stat > FeldmanHashSet_rcu_gpt_sha256_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, key_val<::hashing::sha256>, traits_FeldmanHashSet_sha256_stat > FeldmanHashSet_rcu_shb_sha256_stat; + typedef FeldmanHashSet< rcu_sht, key_val<::hashing::sha256>, traits_FeldmanHashSet_sha256_stat > FeldmanHashSet_rcu_sht_sha256_stat; +#endif + + //MD5 + typedef FeldmanHashSet< cds::gc::HP, key_val<::hashing::md5>, default_traits > FeldmanHashSet_hp_md5; + typedef FeldmanHashSet< cds::gc::DHP, key_val<::hashing::md5>, default_traits > FeldmanHashSet_dhp_md5; + typedef FeldmanHashSet< rcu_gpi, key_val<::hashing::md5>, default_traits > FeldmanHashSet_rcu_gpi_md5; + typedef FeldmanHashSet< rcu_gpb, key_val<::hashing::md5>, default_traits > FeldmanHashSet_rcu_gpb_md5; + typedef FeldmanHashSet< rcu_gpt, key_val<::hashing::md5>, default_traits > FeldmanHashSet_rcu_gpt_md5; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, key_val<::hashing::md5>, default_traits > FeldmanHashSet_rcu_shb_md5; + typedef FeldmanHashSet< rcu_sht, key_val<::hashing::md5>, default_traits > FeldmanHashSet_rcu_sht_md5; +#endif + + struct traits_FeldmanHashSet_md5_stat : public default_traits + { + typedef cc::feldman_hashset::stat<> stat; + }; + typedef FeldmanHashSet< cds::gc::HP, key_val<::hashing::md5>, traits_FeldmanHashSet_md5_stat > FeldmanHashSet_hp_md5_stat; + typedef FeldmanHashSet< cds::gc::DHP, key_val<::hashing::md5>, traits_FeldmanHashSet_md5_stat > FeldmanHashSet_dhp_md5_stat; + typedef FeldmanHashSet< rcu_gpi, key_val<::hashing::md5>, traits_FeldmanHashSet_md5_stat > FeldmanHashSet_rcu_gpi_md5_stat; + typedef FeldmanHashSet< rcu_gpb, key_val<::hashing::md5>, traits_FeldmanHashSet_md5_stat > FeldmanHashSet_rcu_gpb_md5_stat; + typedef FeldmanHashSet< rcu_gpt, key_val<::hashing::md5>, traits_FeldmanHashSet_md5_stat > FeldmanHashSet_rcu_gpt_md5_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, key_val<::hashing::md5>, traits_FeldmanHashSet_md5_stat > FeldmanHashSet_rcu_shb_md5_stat; + typedef FeldmanHashSet< rcu_sht, key_val<::hashing::md5>, traits_FeldmanHashSet_md5_stat > FeldmanHashSet_rcu_sht_md5_stat; +#endif + + // CityHash +#if CDS_BUILD_BITS == 64 + struct traits_FeldmanHashSet_city64 : public default_traits + { + typedef ::hashing::city64::less less; + }; + typedef FeldmanHashSet< cds::gc::HP, key_val<::hashing::city64>, traits_FeldmanHashSet_city64 > FeldmanHashSet_hp_city64; + typedef FeldmanHashSet< cds::gc::DHP, key_val<::hashing::city64>, traits_FeldmanHashSet_city64 > FeldmanHashSet_dhp_city64; + typedef FeldmanHashSet< rcu_gpi, key_val<::hashing::city64>, traits_FeldmanHashSet_city64 > FeldmanHashSet_rcu_gpi_city64; + typedef FeldmanHashSet< rcu_gpb, key_val<::hashing::city64>, traits_FeldmanHashSet_city64 > FeldmanHashSet_rcu_gpb_city64; + typedef FeldmanHashSet< rcu_gpt, key_val<::hashing::city64>, traits_FeldmanHashSet_city64 > FeldmanHashSet_rcu_gpt_city64; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, key_val<::hashing::city64>, traits_FeldmanHashSet_city64 > FeldmanHashSet_rcu_shb_city64; + typedef FeldmanHashSet< rcu_sht, key_val<::hashing::city64>, traits_FeldmanHashSet_city64 > FeldmanHashSet_rcu_sht_city64; +#endif + + struct traits_FeldmanHashSet_city64_stat : public traits_FeldmanHashSet_city64 + { + typedef cc::feldman_hashset::stat<> stat; + }; + typedef FeldmanHashSet< cds::gc::HP, key_val<::hashing::city64>, traits_FeldmanHashSet_city64_stat > FeldmanHashSet_hp_city64_stat; + typedef FeldmanHashSet< cds::gc::DHP, key_val<::hashing::city64>, traits_FeldmanHashSet_city64_stat > FeldmanHashSet_dhp_city64_stat; + typedef FeldmanHashSet< rcu_gpi, key_val<::hashing::city64>, traits_FeldmanHashSet_city64_stat > FeldmanHashSet_rcu_gpi_city64_stat; + typedef FeldmanHashSet< rcu_gpb, key_val<::hashing::city64>, traits_FeldmanHashSet_city64_stat > FeldmanHashSet_rcu_gpb_city64_stat; + typedef FeldmanHashSet< rcu_gpt, key_val<::hashing::city64>, traits_FeldmanHashSet_city64_stat > FeldmanHashSet_rcu_gpt_city64_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, key_val<::hashing::city64>, traits_FeldmanHashSet_city64_stat > FeldmanHashSet_rcu_shb_city64_stat; + typedef FeldmanHashSet< rcu_sht, key_val<::hashing::city64>, traits_FeldmanHashSet_city64_stat > FeldmanHashSet_rcu_sht_city64_stat; +#endif + + struct traits_FeldmanHashSet_city128 : public default_traits + { + typedef ::hashing::city128::less less; + }; + typedef FeldmanHashSet< cds::gc::HP, key_val<::hashing::city128>, traits_FeldmanHashSet_city128 > FeldmanHashSet_hp_city128; + typedef FeldmanHashSet< cds::gc::DHP, key_val<::hashing::city128>, traits_FeldmanHashSet_city128 > FeldmanHashSet_dhp_city128; + typedef FeldmanHashSet< rcu_gpi, key_val<::hashing::city128>, traits_FeldmanHashSet_city128 > FeldmanHashSet_rcu_gpi_city128; + typedef FeldmanHashSet< rcu_gpb, key_val<::hashing::city128>, traits_FeldmanHashSet_city128 > FeldmanHashSet_rcu_gpb_city128; + typedef FeldmanHashSet< rcu_gpt, key_val<::hashing::city128>, traits_FeldmanHashSet_city128 > FeldmanHashSet_rcu_gpt_city128; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, key_val<::hashing::city128>, traits_FeldmanHashSet_city128 > FeldmanHashSet_rcu_shb_city128; + typedef FeldmanHashSet< rcu_sht, key_val<::hashing::city128>, traits_FeldmanHashSet_city128 > FeldmanHashSet_rcu_sht_city128; +#endif + + struct traits_FeldmanHashSet_city128_stat : public traits_FeldmanHashSet_city128 + { + typedef cc::feldman_hashset::stat<> stat; + }; + typedef FeldmanHashSet< cds::gc::HP, key_val<::hashing::city128>, traits_FeldmanHashSet_city128_stat > FeldmanHashSet_hp_city128_stat; + typedef FeldmanHashSet< cds::gc::DHP, key_val<::hashing::city128>, traits_FeldmanHashSet_city128_stat > FeldmanHashSet_dhp_city128_stat; + typedef FeldmanHashSet< rcu_gpi, key_val<::hashing::city128>, traits_FeldmanHashSet_city128_stat > FeldmanHashSet_rcu_gpi_city128_stat; + typedef FeldmanHashSet< rcu_gpb, key_val<::hashing::city128>, traits_FeldmanHashSet_city128_stat > FeldmanHashSet_rcu_gpb_city128_stat; + typedef FeldmanHashSet< rcu_gpt, key_val<::hashing::city128>, traits_FeldmanHashSet_city128_stat > FeldmanHashSet_rcu_gpt_city128_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, key_val<::hashing::city128>, traits_FeldmanHashSet_city128_stat > FeldmanHashSet_rcu_shb_city128_stat; + typedef FeldmanHashSet< rcu_sht, key_val<::hashing::city128>, traits_FeldmanHashSet_city128_stat > FeldmanHashSet_rcu_sht_city128_stat; +#endif + +#endif // #if CDS_BUILD_BITS == 64 + + + // for fixed-sized key + // No hash function is necessary + + struct fixed_sized_key + { + typedef typename set_type_base< Key, Val >::key_type key_type; + struct key_val : public set_type_base< Key, Val >::key_val + { + typedef typename set_type_base< Key, Val >::key_val base_class; + + /*explicit*/ key_val(key_type const& k) : base_class(k) {} + key_val(key_type const& k, value_type const& v) : base_class(k, v) {} + + template + /*explicit*/ key_val(K const& k) : base_class(k) {} + + template + key_val(K const& k, T const& v) : base_class(k, v) {} + + // mock hasher + struct hasher { + template + key_type operator()( Q const& k ) const + { + return key_type( k ); + } + }; + }; + + struct traits : public cc::feldman_hashset::traits + { + struct hash_accessor { + key_type operator()(key_val const& kv) + { + return kv.key; + } + }; + }; + + struct traits_stat : public traits + { + typedef cc::feldman_hashset::stat<> stat; + }; + }; + + typedef FeldmanHashSet< cds::gc::HP, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > FeldmanHashSet_hp_fixed; + typedef FeldmanHashSet< cds::gc::DHP, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > FeldmanHashSet_dhp_fixed; + typedef FeldmanHashSet< rcu_gpi, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > FeldmanHashSet_rcu_gpi_fixed; + typedef FeldmanHashSet< rcu_gpb, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > FeldmanHashSet_rcu_gpb_fixed; + typedef FeldmanHashSet< rcu_gpt, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > FeldmanHashSet_rcu_gpt_fixed; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > FeldmanHashSet_rcu_shb_fixed; + typedef FeldmanHashSet< rcu_sht, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > FeldmanHashSet_rcu_sht_fixed; +#endif + + typedef FeldmanHashSet< cds::gc::HP, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > FeldmanHashSet_hp_fixed_stat; + typedef FeldmanHashSet< cds::gc::DHP, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > FeldmanHashSet_dhp_fixed_stat; + typedef FeldmanHashSet< rcu_gpi, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > FeldmanHashSet_rcu_gpi_fixed_stat; + typedef FeldmanHashSet< rcu_gpb, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > FeldmanHashSet_rcu_gpb_fixed_stat; + typedef FeldmanHashSet< rcu_gpt, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > FeldmanHashSet_rcu_gpt_fixed_stat; +#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED + typedef FeldmanHashSet< rcu_shb, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > FeldmanHashSet_rcu_shb_fixed_stat; + typedef FeldmanHashSet< rcu_sht, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > FeldmanHashSet_rcu_sht_fixed_stat; +#endif + + }; + + template + static inline void print_stat( FeldmanHashSet< GC, T, Traits > const& s ) + { + CPPUNIT_MSG( s.statistics() ); + } + +} // namespace set2 + +#endif // #ifndef CDSUNIT_SET_TYPE_MICHAEL_H diff --git a/tests/unit/set2/set_type_multilevel_hashset.h b/tests/unit/set2/set_type_multilevel_hashset.h deleted file mode 100644 index 26e38c1d..00000000 --- a/tests/unit/set2/set_type_multilevel_hashset.h +++ /dev/null @@ -1,341 +0,0 @@ -//$$CDS-header$$ - -#ifndef CDSUNIT_SET_TYPE_MICHAEL_H -#define CDSUNIT_SET_TYPE_MICHAEL_H - -#include "set2/set_type.h" - -#include -#include -#include - -#include "print_multilevel_hashset_stat.h" -#include "hashing/hash_func.h" - -namespace set2 { - - template - class MultiLevelHashSet : public cc::MultiLevelHashSet< GC, T, Traits > - { - typedef cc::MultiLevelHashSet< GC, T, Traits > base_class; - - template - struct get_extracted_ptr - { - typedef typename base_class::guarded_ptr extracted_ptr; - }; - - template - struct get_extracted_ptr> - { - typedef typename base_class::exempt_ptr extracted_ptr; - }; - - public: - typedef typename T::hasher hasher ; - typedef typename get_extracted_ptr::extracted_ptr extracted_ptr; - - template - MultiLevelHashSet( Config const& cfg ) - : base_class( cfg.c_nMultiLevelSet_HeadBits, cfg.c_nMultiLevelSet_ArrayBits ) - {} - - template - bool erase( Q const& key ) - { - return base_class::erase( hasher()( key )); - } - - template - bool erase( Q const& key, Func f ) - { - return base_class::erase( hasher()( key ), f ); - } - - template - extracted_ptr extract(Q const& key) - { - return base_class::extract( hasher()(key) ); - } - - template - bool contains( Q const& key ) - { - return base_class::contains( hasher()(key) ); - } - - // for testing - static CDS_CONSTEXPR bool const c_bExtractSupported = true; - static CDS_CONSTEXPR bool const c_bLoadFactorDepended = false; - static CDS_CONSTEXPR bool const c_bEraseExactKey = true; - }; - - struct tag_MultiLevelHashSet; - - template - struct set_type< tag_MultiLevelHashSet, Key, Val >: public set_type_base< Key, Val > - { - typedef set_type_base< Key, Val > base_class; - typedef typename base_class::compare compare; - typedef typename base_class::less less; - typedef typename base_class::hash hash; - typedef typename base_class::key_type key_type; - typedef typename base_class::value_type value_type; - - template - struct hash_type - { - typedef Hasher hasher; - typedef typename hasher::hash_type type; - }; - - template - struct hash_type> - { - typedef std::hash hasher; - typedef size_t type; - }; - - template - struct key_val: base_class::key_val - { - typedef typename base_class::key_val base; - typedef Hasher hasher; - typedef typename hash_type::type hash_type; - - hash_type hash; - - /*explicit*/ key_val( key_type const& k ): base(k), hash( hasher()( k )) {} - key_val( key_type const& k, value_type const& v ): base(k, v), hash( hasher()( k )) {} - - template - /*explicit*/ key_val( K const& k ): base(k), hash( hasher()( k )) {} - - template - key_val( K const& k, T const& v ): base(k, v), hash( hasher()( k )) {} - }; - - struct default_traits : public cc::multilevel_hashset::traits - { - struct hash_accessor { - template - typename key_val::hash_type const& operator()( key_val const& kv ) - { - return kv.hash; - } - }; - }; - - typedef MultiLevelHashSet< cds::gc::HP, key_val>, default_traits > MultiLevelHashSet_hp_stdhash; - typedef MultiLevelHashSet< cds::gc::DHP, key_val>, default_traits > MultiLevelHashSet_dhp_stdhash; - typedef MultiLevelHashSet< rcu_gpi, key_val>, default_traits > MultiLevelHashSet_rcu_gpi_stdhash; - typedef MultiLevelHashSet< rcu_gpb, key_val>, default_traits > MultiLevelHashSet_rcu_gpb_stdhash; - typedef MultiLevelHashSet< rcu_gpt, key_val>, default_traits > MultiLevelHashSet_rcu_gpt_stdhash; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, key_val>, default_traits > MultiLevelHashSet_rcu_shb_stdhash; - typedef MultiLevelHashSet< rcu_sht, key_val>, default_traits > MultiLevelHashSet_rcu_sht_stdhash; -#endif - - struct traits_MultiLevelHashSet_stat: public cc::multilevel_hashset::make_traits< - co::type_traits< default_traits >, - co::stat< cc::multilevel_hashset::stat<>> - >::type - {}; - - typedef MultiLevelHashSet< cds::gc::HP, key_val>, traits_MultiLevelHashSet_stat > MultiLevelHashSet_hp_stdhash_stat; - typedef MultiLevelHashSet< cds::gc::DHP, key_val>, traits_MultiLevelHashSet_stat > MultiLevelHashSet_dhp_stdhash_stat; - typedef MultiLevelHashSet< rcu_gpi, key_val>, traits_MultiLevelHashSet_stat > MultiLevelHashSet_rcu_gpi_stdhash_stat; - typedef MultiLevelHashSet< rcu_gpb, key_val>, traits_MultiLevelHashSet_stat > MultiLevelHashSet_rcu_gpb_stdhash_stat; - typedef MultiLevelHashSet< rcu_gpt, key_val>, traits_MultiLevelHashSet_stat > MultiLevelHashSet_rcu_gpt_stdhash_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, key_val>, traits_MultiLevelHashSet_stat > MultiLevelHashSet_rcu_shb_stdhash_stat; - typedef MultiLevelHashSet< rcu_sht, key_val>, traits_MultiLevelHashSet_stat > MultiLevelHashSet_rcu_sht_stdhash_stat; -#endif - - // SHA256 - typedef MultiLevelHashSet< cds::gc::HP, key_val<::hashing::sha256>, default_traits > MultiLevelHashSet_hp_sha256; - typedef MultiLevelHashSet< cds::gc::DHP, key_val<::hashing::sha256>, default_traits > MultiLevelHashSet_dhp_sha256; - typedef MultiLevelHashSet< rcu_gpi, key_val<::hashing::sha256>, default_traits > MultiLevelHashSet_rcu_gpi_sha256; - typedef MultiLevelHashSet< rcu_gpb, key_val<::hashing::sha256>, default_traits > MultiLevelHashSet_rcu_gpb_sha256; - typedef MultiLevelHashSet< rcu_gpt, key_val<::hashing::sha256>, default_traits > MultiLevelHashSet_rcu_gpt_sha256; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, key_val<::hashing::sha256>, default_traits > MultiLevelHashSet_rcu_shb_sha256; - typedef MultiLevelHashSet< rcu_sht, key_val<::hashing::sha256>, default_traits > MultiLevelHashSet_rcu_sht_sha256; -#endif - - struct traits_MultiLevelHashSet_sha256_stat : public default_traits - { - typedef cc::multilevel_hashset::stat<> stat; - }; - typedef MultiLevelHashSet< cds::gc::HP, key_val<::hashing::sha256>, traits_MultiLevelHashSet_sha256_stat > MultiLevelHashSet_hp_sha256_stat; - typedef MultiLevelHashSet< cds::gc::DHP, key_val<::hashing::sha256>, traits_MultiLevelHashSet_sha256_stat > MultiLevelHashSet_dhp_sha256_stat; - typedef MultiLevelHashSet< rcu_gpi, key_val<::hashing::sha256>, traits_MultiLevelHashSet_sha256_stat > MultiLevelHashSet_rcu_gpi_sha256_stat; - typedef MultiLevelHashSet< rcu_gpb, key_val<::hashing::sha256>, traits_MultiLevelHashSet_sha256_stat > MultiLevelHashSet_rcu_gpb_sha256_stat; - typedef MultiLevelHashSet< rcu_gpt, key_val<::hashing::sha256>, traits_MultiLevelHashSet_sha256_stat > MultiLevelHashSet_rcu_gpt_sha256_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, key_val<::hashing::sha256>, traits_MultiLevelHashSet_sha256_stat > MultiLevelHashSet_rcu_shb_sha256_stat; - typedef MultiLevelHashSet< rcu_sht, key_val<::hashing::sha256>, traits_MultiLevelHashSet_sha256_stat > MultiLevelHashSet_rcu_sht_sha256_stat; -#endif - - //MD5 - typedef MultiLevelHashSet< cds::gc::HP, key_val<::hashing::md5>, default_traits > MultiLevelHashSet_hp_md5; - typedef MultiLevelHashSet< cds::gc::DHP, key_val<::hashing::md5>, default_traits > MultiLevelHashSet_dhp_md5; - typedef MultiLevelHashSet< rcu_gpi, key_val<::hashing::md5>, default_traits > MultiLevelHashSet_rcu_gpi_md5; - typedef MultiLevelHashSet< rcu_gpb, key_val<::hashing::md5>, default_traits > MultiLevelHashSet_rcu_gpb_md5; - typedef MultiLevelHashSet< rcu_gpt, key_val<::hashing::md5>, default_traits > MultiLevelHashSet_rcu_gpt_md5; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, key_val<::hashing::md5>, default_traits > MultiLevelHashSet_rcu_shb_md5; - typedef MultiLevelHashSet< rcu_sht, key_val<::hashing::md5>, default_traits > MultiLevelHashSet_rcu_sht_md5; -#endif - - struct traits_MultiLevelHashSet_md5_stat : public default_traits - { - typedef cc::multilevel_hashset::stat<> stat; - }; - typedef MultiLevelHashSet< cds::gc::HP, key_val<::hashing::md5>, traits_MultiLevelHashSet_md5_stat > MultiLevelHashSet_hp_md5_stat; - typedef MultiLevelHashSet< cds::gc::DHP, key_val<::hashing::md5>, traits_MultiLevelHashSet_md5_stat > MultiLevelHashSet_dhp_md5_stat; - typedef MultiLevelHashSet< rcu_gpi, key_val<::hashing::md5>, traits_MultiLevelHashSet_md5_stat > MultiLevelHashSet_rcu_gpi_md5_stat; - typedef MultiLevelHashSet< rcu_gpb, key_val<::hashing::md5>, traits_MultiLevelHashSet_md5_stat > MultiLevelHashSet_rcu_gpb_md5_stat; - typedef MultiLevelHashSet< rcu_gpt, key_val<::hashing::md5>, traits_MultiLevelHashSet_md5_stat > MultiLevelHashSet_rcu_gpt_md5_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, key_val<::hashing::md5>, traits_MultiLevelHashSet_md5_stat > MultiLevelHashSet_rcu_shb_md5_stat; - typedef MultiLevelHashSet< rcu_sht, key_val<::hashing::md5>, traits_MultiLevelHashSet_md5_stat > MultiLevelHashSet_rcu_sht_md5_stat; -#endif - - // CityHash -#if CDS_BUILD_BITS == 64 - struct traits_MultiLevelHashSet_city64 : public default_traits - { - typedef ::hashing::city64::less less; - }; - typedef MultiLevelHashSet< cds::gc::HP, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64 > MultiLevelHashSet_hp_city64; - typedef MultiLevelHashSet< cds::gc::DHP, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64 > MultiLevelHashSet_dhp_city64; - typedef MultiLevelHashSet< rcu_gpi, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64 > MultiLevelHashSet_rcu_gpi_city64; - typedef MultiLevelHashSet< rcu_gpb, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64 > MultiLevelHashSet_rcu_gpb_city64; - typedef MultiLevelHashSet< rcu_gpt, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64 > MultiLevelHashSet_rcu_gpt_city64; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64 > MultiLevelHashSet_rcu_shb_city64; - typedef MultiLevelHashSet< rcu_sht, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64 > MultiLevelHashSet_rcu_sht_city64; -#endif - - struct traits_MultiLevelHashSet_city64_stat : public traits_MultiLevelHashSet_city64 - { - typedef cc::multilevel_hashset::stat<> stat; - }; - typedef MultiLevelHashSet< cds::gc::HP, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64_stat > MultiLevelHashSet_hp_city64_stat; - typedef MultiLevelHashSet< cds::gc::DHP, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64_stat > MultiLevelHashSet_dhp_city64_stat; - typedef MultiLevelHashSet< rcu_gpi, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64_stat > MultiLevelHashSet_rcu_gpi_city64_stat; - typedef MultiLevelHashSet< rcu_gpb, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64_stat > MultiLevelHashSet_rcu_gpb_city64_stat; - typedef MultiLevelHashSet< rcu_gpt, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64_stat > MultiLevelHashSet_rcu_gpt_city64_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64_stat > MultiLevelHashSet_rcu_shb_city64_stat; - typedef MultiLevelHashSet< rcu_sht, key_val<::hashing::city64>, traits_MultiLevelHashSet_city64_stat > MultiLevelHashSet_rcu_sht_city64_stat; -#endif - - struct traits_MultiLevelHashSet_city128 : public default_traits - { - typedef ::hashing::city128::less less; - }; - typedef MultiLevelHashSet< cds::gc::HP, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128 > MultiLevelHashSet_hp_city128; - typedef MultiLevelHashSet< cds::gc::DHP, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128 > MultiLevelHashSet_dhp_city128; - typedef MultiLevelHashSet< rcu_gpi, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128 > MultiLevelHashSet_rcu_gpi_city128; - typedef MultiLevelHashSet< rcu_gpb, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128 > MultiLevelHashSet_rcu_gpb_city128; - typedef MultiLevelHashSet< rcu_gpt, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128 > MultiLevelHashSet_rcu_gpt_city128; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128 > MultiLevelHashSet_rcu_shb_city128; - typedef MultiLevelHashSet< rcu_sht, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128 > MultiLevelHashSet_rcu_sht_city128; -#endif - - struct traits_MultiLevelHashSet_city128_stat : public traits_MultiLevelHashSet_city128 - { - typedef cc::multilevel_hashset::stat<> stat; - }; - typedef MultiLevelHashSet< cds::gc::HP, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128_stat > MultiLevelHashSet_hp_city128_stat; - typedef MultiLevelHashSet< cds::gc::DHP, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128_stat > MultiLevelHashSet_dhp_city128_stat; - typedef MultiLevelHashSet< rcu_gpi, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128_stat > MultiLevelHashSet_rcu_gpi_city128_stat; - typedef MultiLevelHashSet< rcu_gpb, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128_stat > MultiLevelHashSet_rcu_gpb_city128_stat; - typedef MultiLevelHashSet< rcu_gpt, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128_stat > MultiLevelHashSet_rcu_gpt_city128_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128_stat > MultiLevelHashSet_rcu_shb_city128_stat; - typedef MultiLevelHashSet< rcu_sht, key_val<::hashing::city128>, traits_MultiLevelHashSet_city128_stat > MultiLevelHashSet_rcu_sht_city128_stat; -#endif - -#endif // #if CDS_BUILD_BITS == 64 - - - // for fixed-sized key - // No hash function is necessary - - struct fixed_sized_key - { - typedef typename set_type_base< Key, Val >::key_type key_type; - struct key_val : public set_type_base< Key, Val >::key_val - { - typedef typename set_type_base< Key, Val >::key_val base_class; - - /*explicit*/ key_val(key_type const& k) : base_class(k) {} - key_val(key_type const& k, value_type const& v) : base_class(k, v) {} - - template - /*explicit*/ key_val(K const& k) : base_class(k) {} - - template - key_val(K const& k, T const& v) : base_class(k, v) {} - - // mock hasher - struct hasher { - template - key_type operator()( Q const& k ) const - { - return key_type( k ); - } - }; - }; - - struct traits : public cc::multilevel_hashset::traits - { - struct hash_accessor { - key_type operator()(key_val const& kv) - { - return kv.key; - } - }; - }; - - struct traits_stat : public traits - { - typedef cc::multilevel_hashset::stat<> stat; - }; - }; - - typedef MultiLevelHashSet< cds::gc::HP, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > MultiLevelHashSet_hp_fixed; - typedef MultiLevelHashSet< cds::gc::DHP, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > MultiLevelHashSet_dhp_fixed; - typedef MultiLevelHashSet< rcu_gpi, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > MultiLevelHashSet_rcu_gpi_fixed; - typedef MultiLevelHashSet< rcu_gpb, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > MultiLevelHashSet_rcu_gpb_fixed; - typedef MultiLevelHashSet< rcu_gpt, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > MultiLevelHashSet_rcu_gpt_fixed; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > MultiLevelHashSet_rcu_shb_fixed; - typedef MultiLevelHashSet< rcu_sht, typename fixed_sized_key::key_val, typename fixed_sized_key::traits > MultiLevelHashSet_rcu_sht_fixed; -#endif - - typedef MultiLevelHashSet< cds::gc::HP, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > MultiLevelHashSet_hp_fixed_stat; - typedef MultiLevelHashSet< cds::gc::DHP, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > MultiLevelHashSet_dhp_fixed_stat; - typedef MultiLevelHashSet< rcu_gpi, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > MultiLevelHashSet_rcu_gpi_fixed_stat; - typedef MultiLevelHashSet< rcu_gpb, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > MultiLevelHashSet_rcu_gpb_fixed_stat; - typedef MultiLevelHashSet< rcu_gpt, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > MultiLevelHashSet_rcu_gpt_fixed_stat; -#ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED - typedef MultiLevelHashSet< rcu_shb, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > MultiLevelHashSet_rcu_shb_fixed_stat; - typedef MultiLevelHashSet< rcu_sht, typename fixed_sized_key::key_val, typename fixed_sized_key::traits_stat > MultiLevelHashSet_rcu_sht_fixed_stat; -#endif - - }; - - template - static inline void print_stat( MultiLevelHashSet< GC, T, Traits > const& s ) - { - CPPUNIT_MSG( s.statistics() ); - } - -} // namespace set2 - -#endif // #ifndef CDSUNIT_SET_TYPE_MICHAEL_H -- 2.34.1