Added stress-map-iter-erase test for erase_at()
[libcds.git] / test / stress / map / map_type_feldman_hashmap.h
1 /*
2     This file is a part of libcds - Concurrent Data Structures library
3
4     (C) Copyright Maxim Khizhinsky (libcds.dev@gmail.com) 2006-2017
5
6     Source code repo: http://github.com/khizmax/libcds/
7     Download: http://sourceforge.net/projects/libcds/files/
8
9     Redistribution and use in source and binary forms, with or without
10     modification, are permitted provided that the following conditions are met:
11
12     * Redistributions of source code must retain the above copyright notice, this
13       list of conditions and the following disclaimer.
14
15     * Redistributions in binary form must reproduce the above copyright notice,
16       this list of conditions and the following disclaimer in the documentation
17       and/or other materials provided with the distribution.
18
19     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
20     AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
21     IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22     DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
23     FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
24     DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
25     SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
26     CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
27     OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28     OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 */
30
31 #ifndef CDSUNIT_MAP_TYPE_FELDMAN_HASHMAP_H
32 #define CDSUNIT_MAP_TYPE_FELDMAN_HASHMAP_H
33
34 #include "map_type.h"
35
36 #include <cds/container/feldman_hashmap_hp.h>
37 #include <cds/container/feldman_hashmap_dhp.h>
38 #include <cds/container/feldman_hashmap_rcu.h>
39
40 #include <cds_test/stat_feldman_hashset_out.h>
41 #include <cds_test/hash_func.h>
42
43 namespace map {
44
45     template <class GC, typename Key, typename T, typename Traits = cc::feldman_hashmap::traits>
46     class FeldmanHashMap : public cc::FeldmanHashMap< GC, Key, T, Traits >
47     {
48         typedef cc::FeldmanHashMap< GC, Key, T, Traits > base_class;
49     public:
50
51         template <typename OtherTraits>
52         struct rebind_traits {
53             typedef FeldmanHashMap<GC, Key, T, OtherTraits > result;
54         };
55
56         template <typename Config>
57         FeldmanHashMap( Config const& cfg)
58             : base_class( cfg.s_nFeldmanMap_HeadBits, cfg.s_nFeldmanMap_ArrayBits )
59         {}
60
61         template <typename Iterator>
62         typename std::enable_if< std::is_same< Iterator, typename base_class::iterator>::value, Iterator>::type
63             get_begin()
64         {
65             return base_class::begin();
66         }
67
68         template <typename Iterator>
69         typename std::enable_if< std::is_same< Iterator, typename base_class::iterator>::value, Iterator>::type
70             get_end()
71         {
72             return base_class::end();
73         }
74
75         template <typename Iterator>
76         typename std::enable_if< std::is_same< Iterator, typename base_class::reverse_iterator>::value, Iterator>::type
77             get_begin()
78         {
79             return base_class::rbegin();
80         }
81
82         template <typename Iterator>
83         typename std::enable_if< std::is_same< Iterator, typename base_class::reverse_iterator>::value, Iterator>::type
84             get_end()
85         {
86             return base_class::rend();
87         }
88
89         // for testing
90         static CDS_CONSTEXPR bool const c_bExtractSupported = true;
91         static CDS_CONSTEXPR bool const c_bLoadFactorDepended = false;
92         static CDS_CONSTEXPR bool const c_bEraseExactKey = true;
93     };
94
95     struct tag_FeldmanHashMap;
96
97     template <typename Key, typename Value>
98     struct map_type< tag_FeldmanHashMap, Key, Value >: public map_type_base< Key, Value >
99     {
100         typedef map_type_base< Key, Value >      base_class;
101         typedef typename base_class::key_compare compare;
102         typedef typename base_class::key_less    less;
103
104         struct traits_FeldmanHashMap_stdhash : public cc::feldman_hashmap::traits
105         {
106             typedef std::hash< Key >    hash;
107             typedef std::less<size_t>   less;
108         };
109
110         typedef FeldmanHashMap< cds::gc::HP,  Key, Value, traits_FeldmanHashMap_stdhash >    FeldmanHashMap_hp_stdhash;
111         typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_stdhash >    FeldmanHashMap_dhp_stdhash;
112         typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_stdhash >    FeldmanHashMap_rcu_gpi_stdhash;
113         typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_stdhash >    FeldmanHashMap_rcu_gpb_stdhash;
114         typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_stdhash >    FeldmanHashMap_rcu_gpt_stdhash;
115 #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED
116         typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_stdhash >    FeldmanHashMap_rcu_shb_stdhash;
117         typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_stdhash >    FeldmanHashMap_rcu_sht_stdhash;
118 #endif
119
120         struct traits_FeldmanHashMap_stdhash_stat: traits_FeldmanHashMap_stdhash
121         {
122             typedef cc::feldman_hashmap::stat<> stat;
123             typedef std::less<size_t>   less;
124         };
125
126         typedef FeldmanHashMap< cds::gc::HP,  Key, Value, traits_FeldmanHashMap_stdhash_stat >    FeldmanHashMap_hp_stdhash_stat;
127         typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_stdhash_stat >    FeldmanHashMap_dhp_stdhash_stat;
128         typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_stdhash_stat >    FeldmanHashMap_rcu_gpi_stdhash_stat;
129         typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_stdhash_stat >    FeldmanHashMap_rcu_gpb_stdhash_stat;
130         typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_stdhash_stat >    FeldmanHashMap_rcu_gpt_stdhash_stat;
131 #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED
132         typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_stdhash_stat >    FeldmanHashMap_rcu_shb_stdhash_stat;
133         typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_stdhash_stat >    FeldmanHashMap_rcu_sht_stdhash_stat;
134 #endif
135
136         // CityHash
137 #if CDS_BUILD_BITS == 64
138         struct traits_FeldmanHashMap_city64 : public cc::feldman_hashmap::traits
139         {
140             typedef ::cds_test::city64 hash;
141             typedef ::cds_test::city64::less less;
142         };
143         typedef FeldmanHashMap< cds::gc::HP,  Key, Value, traits_FeldmanHashMap_city64 >    FeldmanHashMap_hp_city64;
144         typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_city64 >    FeldmanHashMap_dhp_city64;
145         typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_city64 >    FeldmanHashMap_rcu_gpi_city64;
146         typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_city64 >    FeldmanHashMap_rcu_gpb_city64;
147         typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_city64 >    FeldmanHashMap_rcu_gpt_city64;
148 #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED
149         typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_city64 >    FeldmanHashMap_rcu_shb_city64;
150         typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_city64 >    FeldmanHashMap_rcu_sht_city64;
151 #endif
152
153         struct traits_FeldmanHashMap_city64_stat : public traits_FeldmanHashMap_city64
154         {
155             typedef cc::feldman_hashmap::stat<> stat;
156         };
157         typedef FeldmanHashMap< cds::gc::HP,  Key, Value, traits_FeldmanHashMap_city64_stat >    FeldmanHashMap_hp_city64_stat;
158         typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_city64_stat >    FeldmanHashMap_dhp_city64_stat;
159         typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_city64_stat >    FeldmanHashMap_rcu_gpi_city64_stat;
160         typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_city64_stat >    FeldmanHashMap_rcu_gpb_city64_stat;
161         typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_city64_stat >    FeldmanHashMap_rcu_gpt_city64_stat;
162 #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED
163         typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_city64_stat >    FeldmanHashMap_rcu_shb_city64_stat;
164         typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_city64_stat >    FeldmanHashMap_rcu_sht_city64_stat;
165 #endif
166
167         struct traits_FeldmanHashMap_city128 : public cc::feldman_hashmap::traits
168         {
169             typedef ::cds_test::city128 hash;
170             typedef ::cds_test::city128::less less;
171         };
172         typedef FeldmanHashMap< cds::gc::HP,  Key, Value, traits_FeldmanHashMap_city128 >    FeldmanHashMap_hp_city128;
173         typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_city128 >    FeldmanHashMap_dhp_city128;
174         typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_city128 >    FeldmanHashMap_rcu_gpi_city128;
175         typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_city128 >    FeldmanHashMap_rcu_gpb_city128;
176         typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_city128 >    FeldmanHashMap_rcu_gpt_city128;
177 #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED
178         typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_city128 >    FeldmanHashMap_rcu_shb_city128;
179         typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_city128 >    FeldmanHashMap_rcu_sht_city128;
180 #endif
181
182         struct traits_FeldmanHashMap_city128_stat : public traits_FeldmanHashMap_city128
183         {
184             typedef cc::feldman_hashmap::stat<> stat;
185         };
186         typedef FeldmanHashMap< cds::gc::HP,  Key, Value, traits_FeldmanHashMap_city128_stat >    FeldmanHashMap_hp_city128_stat;
187         typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_city128_stat >    FeldmanHashMap_dhp_city128_stat;
188         typedef FeldmanHashMap< rcu_gpi, Key, Value, traits_FeldmanHashMap_city128_stat >    FeldmanHashMap_rcu_gpi_city128_stat;
189         typedef FeldmanHashMap< rcu_gpb, Key, Value, traits_FeldmanHashMap_city128_stat >    FeldmanHashMap_rcu_gpb_city128_stat;
190         typedef FeldmanHashMap< rcu_gpt, Key, Value, traits_FeldmanHashMap_city128_stat >    FeldmanHashMap_rcu_gpt_city128_stat;
191 #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED
192         typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_city128_stat >    FeldmanHashMap_rcu_shb_city128_stat;
193         typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_city128_stat >    FeldmanHashMap_rcu_sht_city128_stat;
194 #endif
195 #endif // CDS_BUILD_BITS == 64
196
197
198         // for fixed-sized keys - no hash functor required
199         struct traits_FeldmanHashMap_fixed: public cc::feldman_hashmap::traits
200         {
201             typedef map::cmp<Key>    compare;
202         };
203
204         typedef FeldmanHashMap< cds::gc::HP, Key, Value,  traits_FeldmanHashMap_fixed >    FeldmanHashMap_hp_fixed;
205         typedef FeldmanHashMap< cds::gc::DHP, Key, Value, traits_FeldmanHashMap_fixed >   FeldmanHashMap_dhp_fixed;
206         typedef FeldmanHashMap< rcu_gpi, Key, Value,      traits_FeldmanHashMap_fixed >    FeldmanHashMap_rcu_gpi_fixed;
207         typedef FeldmanHashMap< rcu_gpb, Key, Value,      traits_FeldmanHashMap_fixed >    FeldmanHashMap_rcu_gpb_fixed;
208         typedef FeldmanHashMap< rcu_gpt, Key, Value,      traits_FeldmanHashMap_fixed >    FeldmanHashMap_rcu_gpt_fixed;
209 #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED
210         typedef FeldmanHashMap< rcu_shb, Key, Value,      traits_FeldmanHashMap_fixed >    FeldmanHashMap_rcu_shb_fixed;
211         typedef FeldmanHashMap< rcu_sht, Key, Value,      traits_FeldmanHashMap_fixed >    FeldmanHashMap_rcu_sht_fixed;
212 #endif
213
214         struct traits_FeldmanHashMap_fixed_stat : public traits_FeldmanHashMap_fixed
215         {
216             typedef cc::feldman_hashmap::stat<> stat;
217         };
218         typedef FeldmanHashMap< cds::gc::HP, Key, Value,    traits_FeldmanHashMap_fixed_stat >  FeldmanHashMap_hp_fixed_stat;
219         typedef FeldmanHashMap< cds::gc::DHP, Key, Value,   traits_FeldmanHashMap_fixed_stat >  FeldmanHashMap_dhp_fixed_stat;
220         typedef FeldmanHashMap< rcu_gpi, Key, Value,        traits_FeldmanHashMap_fixed_stat >  FeldmanHashMap_rcu_gpi_fixed_stat;
221         typedef FeldmanHashMap< rcu_gpb, Key, Value,        traits_FeldmanHashMap_fixed_stat >  FeldmanHashMap_rcu_gpb_fixed_stat;
222         typedef FeldmanHashMap< rcu_gpt, Key, Value,        traits_FeldmanHashMap_fixed_stat >  FeldmanHashMap_rcu_gpt_fixed_stat;
223 #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED
224         typedef FeldmanHashMap< rcu_shb, Key, Value, traits_FeldmanHashMap_fixed_stat > FeldmanHashMap_rcu_shb_fixed_stat;
225         typedef FeldmanHashMap< rcu_sht, Key, Value, traits_FeldmanHashMap_fixed_stat > FeldmanHashMap_rcu_sht_fixed_stat;
226 #endif
227
228     };
229
230     template <typename GC, typename K, typename T, typename Traits >
231     static inline void print_stat( cds_test::property_stream& o, FeldmanHashMap< GC, K, T, Traits > const& m )
232     {
233         std::vector< cds::intrusive::feldman_hashset::level_statistics > level_stat;
234         m.get_level_statistics( level_stat );
235
236         o << m.statistics()
237           << level_stat;
238     }
239
240 #define CDSSTRESS_FeldmanHashMap_case( fixture, test_case, feldman_map_type, key_type, value_type ) \
241     TEST_F( fixture, feldman_map_type ) \
242     { \
243         typedef map::map_type< tag_FeldmanHashMap, key_type, value_type >::feldman_map_type map_type; \
244         test_case<map_type>(); \
245     }
246
247
248 #ifdef CDS_URCU_SIGNAL_HANDLING_ENABLED
249 #   define CDSSTRESS_FeldmanHashMap_fixed_SHRCU( fixture, test_case, key_type, value_type ) \
250         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_shb_fixed, key_type, value_type ) \
251         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_sht_fixed, key_type, value_type ) \
252         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_shb_fixed_stat, key_type, value_type ) \
253         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_sht_fixed_stat, key_type, value_type ) \
254
255 #   define CDSSTRESS_FeldmanHashMap_stdhash_SHRCU( fixture, test_case, key_type, value_type ) \
256         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_shb_stdhash, key_type, value_type ) \
257         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_sht_stdhash, key_type, value_type ) \
258         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_shb_stdhash_stat, key_type, value_type ) \
259         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_sht_stdhash_stat, key_type, value_type ) \
260
261 #   if CDS_BUILD_BITS == 64
262 #       define CDSSTRESS_FeldmanHashMap_city64_SHRCU( fixture, test_case, key_type, value_type ) \
263             CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_shb_city64, key_type, value_type ) \
264             CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_sht_city64, key_type, value_type ) \
265             CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_shb_city64_stat, key_type, value_type ) \
266             CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_sht_city64_stat, key_type, value_type ) \
267
268 #       define CDSSTRESS_FeldmanHashMap_city128_SHRCU( fixture, test_case, key_type, value_type ) \
269             CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_shb_city64, key_type, value_type ) \
270             CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_sht_city64, key_type, value_type ) \
271             CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_shb_city64_stat, key_type, value_type ) \
272             CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_sht_city64_stat, key_type, value_type ) \
273
274 #   else
275 #       define CDSSTRESS_FeldmanHashMap_city64_SHRCU( fixture, test_case, key_type, value_type )
276 #       define CDSSTRESS_FeldmanHashMap_city128_SHRCU( fixture, test_case, key_type, value_type )
277 #   endif
278
279 #else
280 #   define CDSSTRESS_FeldmanHashMap_fixed_SHRCU( fixture, test_case, key_type, value_type )
281 #   define CDSSTRESS_FeldmanHashMap_stdhash_SHRCU( fixture, test_case, key_type, value_type )
282 #   define CDSSTRESS_FeldmanHashMap_city64_SHRCU( fixture, test_case, key_type, value_type )
283 #   define CDSSTRESS_FeldmanHashMap_city128_SHRCU( fixture, test_case, key_type, value_type )
284 #endif
285
286 #define CDSSTRESS_FeldmanHashMap_fixed_HP( fixture, test_case, key_type, value_type ) \
287     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_hp_fixed,         key_type, value_type ) \
288     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_dhp_fixed,        key_type, value_type ) \
289     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_hp_fixed_stat,    key_type, value_type ) \
290     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_dhp_fixed_stat,   key_type, value_type ) \
291
292 #define CDSSTRESS_FeldmanHashMap_fixed_RCU( fixture, test_case, key_type, value_type ) \
293     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpi_fixed,        key_type, value_type ) \
294     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpb_fixed,        key_type, value_type ) \
295     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpt_fixed,        key_type, value_type ) \
296     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpi_fixed_stat,   key_type, value_type ) \
297     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpb_fixed_stat,   key_type, value_type ) \
298     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpt_fixed_stat,   key_type, value_type ) \
299
300     //CDSSTRESS_FeldmanHashMap_fixed_SHRCU( fixture, test_case, key_type, value_type )
301
302 #define CDSSTRESS_FeldmanHashMap_fixed( fixture, test_case, key_type, value_type ) \
303     CDSSTRESS_FeldmanHashMap_fixed_HP( fixture, test_case, key_type, value_type ) \
304     CDSSTRESS_FeldmanHashMap_fixed_RCU( fixture, test_case, key_type, value_type ) \
305
306
307 #define CDSSTRESS_FeldmanHashMap_stdhash_HP( fixture, test_case, key_type, value_type ) \
308     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_hp_stdhash,       key_type, value_type ) \
309     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_dhp_stdhash,      key_type, value_type ) \
310     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_hp_stdhash_stat,  key_type, value_type ) \
311     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_dhp_stdhash_stat, key_type, value_type ) \
312
313 #define CDSSTRESS_FeldmanHashMap_stdhash_RCU( fixture, test_case, key_type, value_type ) \
314     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpi_stdhash,      key_type, value_type ) \
315     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpb_stdhash,      key_type, value_type ) \
316     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpt_stdhash,      key_type, value_type ) \
317     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpi_stdhash_stat, key_type, value_type ) \
318     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpb_stdhash_stat, key_type, value_type ) \
319     CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpt_stdhash_stat, key_type, value_type ) \
320
321     //CDSSTRESS_FeldmanHashMap_stdhash_SHRCU( fixture, test_case, key_type, value_type )
322
323 #define CDSSTRESS_FeldmanHashMap_stdhash( fixture, test_case, key_type, value_type ) \
324     CDSSTRESS_FeldmanHashMap_stdhash_HP( fixture, test_case, key_type, value_type ) \
325     CDSSTRESS_FeldmanHashMap_stdhash_RCU( fixture, test_case, key_type, value_type ) \
326
327
328 #if CDS_BUILD_BITS == 64
329 #   define CDSSTRESS_FeldmanHashMap_city64_HP( fixture, test_case, key_type, value_type ) \
330         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_hp_city64, key_type, value_type ) \
331         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_dhp_city64, key_type, value_type ) \
332         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_hp_city64_stat, key_type, value_type ) \
333         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_dhp_city64_stat, key_type, value_type ) \
334
335 #   define CDSSTRESS_FeldmanHashMap_city64_RCU( fixture, test_case, key_type, value_type ) \
336         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpi_city64, key_type, value_type ) \
337         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpb_city64, key_type, value_type ) \
338         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpt_city64, key_type, value_type ) \
339         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpi_city64_stat, key_type, value_type ) \
340         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpb_city64_stat, key_type, value_type ) \
341         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpt_city64_stat, key_type, value_type ) \
342
343         //CDSSTRESS_FeldmanHashMap_city64_SHRCU( fixture, test_case, key_type, value_type )
344
345 #   define CDSSTRESS_FeldmanHashMap_city64( fixture, test_case, key_type, value_type ) \
346         CDSSTRESS_FeldmanHashMap_city64_HP( fixture, test_case, key_type, value_type ) \
347         CDSSTRESS_FeldmanHashMap_city64_RCU( fixture, test_case, key_type, value_type ) \
348
349
350 #   define CDSSTRESS_FeldmanHashMap_city128_HP( fixture, test_case, key_type, value_type ) \
351         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_hp_city128, key_type, value_type ) \
352         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_dhp_city128, key_type, value_type ) \
353         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_hp_city128_stat, key_type, value_type ) \
354         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_dhp_city128_stat, key_type, value_type ) \
355
356 #   define CDSSTRESS_FeldmanHashMap_city128_RCU( fixture, test_case, key_type, value_type ) \
357         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpi_city128, key_type, value_type ) \
358         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpb_city128, key_type, value_type ) \
359         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpt_city128, key_type, value_type ) \
360         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpi_city128_stat, key_type, value_type ) \
361         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpb_city128_stat, key_type, value_type ) \
362         CDSSTRESS_FeldmanHashMap_case( fixture, test_case, FeldmanHashMap_rcu_gpt_city128_stat, key_type, value_type ) \
363
364         //CDSSTRESS_FeldmanHashMap_city128_SHRCU( fixture, test_case, key_type, value_type )
365
366 #   define CDSSTRESS_FeldmanHashMap_city128( fixture, test_case, key_type, value_type ) \
367         CDSSTRESS_FeldmanHashMap_city128_HP( fixture, test_case, key_type, value_type ) \
368         CDSSTRESS_FeldmanHashMap_city128_RCU( fixture, test_case, key_type, value_type ) \
369
370 #   define CDSSTRESS_FeldmanHashMap_city_HP( fixture, test_case, key_type, value_type ) \
371         CDSSTRESS_FeldmanHashMap_city64_HP( fixture, test_case, key_type, value_type ) \
372         CDSSTRESS_FeldmanHashMap_city128_HP( fixture, test_case, key_type, value_type )
373
374 #   define CDSSTRESS_FeldmanHashMap_city_RCU( fixture, test_case, key_type, value_type ) \
375         CDSSTRESS_FeldmanHashMap_city64_RCU( fixture, test_case, key_type, value_type ) \
376         CDSSTRESS_FeldmanHashMap_city128_RCU( fixture, test_case, key_type, value_type )
377
378 #   define CDSSTRESS_FeldmanHashMap_city( fixture, test_case, key_type, value_type ) \
379         CDSSTRESS_FeldmanHashMap_city_HP( fixture, test_case, key_type, value_type ) \
380         CDSSTRESS_FeldmanHashMap_city_RCU( fixture, test_case, key_type, value_type )
381
382 #else
383 #   define CDSSTRESS_FeldmanHashMap_city64_HP( fixture, test_case, key_type, value_type )
384 #   define CDSSTRESS_FeldmanHashMap_city64_RCU( fixture, test_case, key_type, value_type )
385 #   define CDSSTRESS_FeldmanHashMap_city64( fixture, test_case, key_type, value_type )
386 #   define CDSSTRESS_FeldmanHashMap_city128_HP( fixture, test_case, key_type, value_type )
387 #   define CDSSTRESS_FeldmanHashMap_city128_RCU( fixture, test_case, key_type, value_type )
388 #   define CDSSTRESS_FeldmanHashMap_city128( fixture, test_case, key_type, value_type )
389 #   define CDSSTRESS_FeldmanHashMap_city_HP( fixture, test_case, key_type, value_type )
390 #   define CDSSTRESS_FeldmanHashMap_city_RCU( fixture, test_case, key_type, value_type )
391 #   define CDSSTRESS_FeldmanHashMap_city( fixture, test_case, key_type, value_type )
392 #endif
393
394
395 }   // namespace map
396
397 #endif // #ifndef CDSUNIT_MAP_TYPE_FELDMAN_HASHMAP_H