X-Git-Url: http://plrg.eecs.uci.edu/git/?p=libcds.git;a=blobdiff_plain;f=tests%2Funit%2Fmap2%2Fmap_type_feldman_hashmap.h;h=b858846c71c4e659162eeb1c42de94e4230fa1c9;hp=ec1bbc284e190cf5b4f3a44893ed79de5cfb603f;hb=c9091bac79a393e0d777790b4ed5d6694a1d0309;hpb=479a1342e549c78cf66a669c3ff115e7b6394fb5 diff --git a/tests/unit/map2/map_type_feldman_hashmap.h b/tests/unit/map2/map_type_feldman_hashmap.h index ec1bbc28..b858846c 100644 --- a/tests/unit/map2/map_type_feldman_hashmap.h +++ b/tests/unit/map2/map_type_feldman_hashmap.h @@ -220,6 +220,21 @@ namespace map2 { static inline void print_stat( FeldmanHashMap< GC, K, T, Traits > const& m ) { CPPUNIT_MSG( m.statistics() ); + + std::vector< cds::intrusive::feldman_hashset::level_statistics > level_stat; + m.get_level_statistics( level_stat ); + CPPUNIT_MSG( "Level statistics, height=" << level_stat.size()); + size_t i = 0; + CPPUNIT_MSG( " i node_count capacity data_cell array_cell empty_cell" ); + for (auto it = level_stat.begin(); it != level_stat.end(); ++it, ++i) { + CPPUNIT_MSG( std::setw(3) << i << std::setw(0) << " " + << std::setw(12) << it->array_node_count << std::setw(0) << " " + << std::setw(8) << it->node_capacity << std::setw(0) << " " + << std::setw(12) << it->data_cell_count << std::setw(0) << " " + << std::setw(12) << it->array_cell_count << std::setw(0) << " " + << std::setw(12) << it->empty_cell_count << std::setw(0) + ); + } } } // namespace map2