rename michael_kvlist_pth.h to michael_kvlist_dhp.h
[libcds.git] / tests / test-hdr / set / hdr_intrusive_michael_set_hrc.cpp
1 //$$CDS-header$$
2
3 #include "set/hdr_intrusive_set.h"
4 #include <cds/intrusive/michael_list_hrc.h>
5 #include <cds/intrusive/michael_set.h>
6
7 namespace set {
8
9     void IntrusiveHashSetHdrTest::HRC_base_cmp()
10     {
11         typedef base_int_item< ci::michael_list::node<cds::gc::HRC> > item;
12         typedef ci::MichaelList< cds::gc::HRC
13             ,item
14             ,ci::michael_list::make_traits<
15                 ci::opt::hook< ci::michael_list::base_hook< co::gc<cds::gc::HRC> > >
16                 ,co::compare< cmp<item> >
17                 ,ci::opt::disposer< faked_disposer >
18             >::type
19         >    bucket_type;
20
21         typedef ci::MichaelHashSet< cds::gc::HRC, bucket_type,
22             ci::michael_set::make_traits<
23                 co::hash< hash_int >
24             >::type
25         > set;
26
27         test_int<set>();
28     }
29
30     void IntrusiveHashSetHdrTest::HRC_base_less()
31     {
32         typedef base_int_item< ci::michael_list::node<cds::gc::HRC> > item;
33         typedef ci::MichaelList< cds::gc::HRC
34             ,item
35             ,ci::michael_list::make_traits<
36                 ci::opt::hook< ci::michael_list::base_hook< co::gc<cds::gc::HRC> > >
37                 ,co::less< less<item> >
38                 ,ci::opt::disposer< faked_disposer >
39             >::type
40         >    bucket_type;
41
42         typedef ci::MichaelHashSet< cds::gc::HRC, bucket_type,
43             ci::michael_set::make_traits<
44                 co::hash< hash_int >
45             >::type
46         > set;
47
48         test_int<set>();
49     }
50
51     void IntrusiveHashSetHdrTest::HRC_base_cmpmix()
52     {
53         typedef base_int_item< ci::michael_list::node<cds::gc::HRC> > item;
54         typedef ci::MichaelList< cds::gc::HRC
55             ,item
56             ,ci::michael_list::make_traits<
57                 ci::opt::hook< ci::michael_list::base_hook< co::gc<cds::gc::HRC> > >
58                 ,co::less< less<item> >
59                 ,co::compare< cmp<item> >
60                 ,ci::opt::disposer< faked_disposer >
61             >::type
62         >    bucket_type;
63
64         typedef ci::MichaelHashSet< cds::gc::HRC, bucket_type,
65             ci::michael_set::make_traits<
66                 co::hash< hash_int >
67                 ,co::item_counter< simple_item_counter >
68             >::type
69         > set;
70
71         test_int<set>();
72     }
73
74 } // namespace set