Hi. Likely due to the recent changes / extensions to the namespace association mechanisms to accomodate the parallel STL, the legacy hashed containers are not usable anymore in debug mode. Just compile with -D_GLIBCXX_DEBUG: #include <ext/hash_map> #include <ext/hash_set>
I'll take a look at this.
Here's my plan for the legacy hash containers: 1) port debug mode to tr1 associative containers 2) move ext/hash containers to deprecated Thoughts? Anyway. This issue is a macro name mix-up. Here's I'll check in the attached fix shortly. best, benjamin
Created attachment 14333 [details] EXT to EXT_D
(In reply to comment #2) > Here's my plan for the legacy hash containers: > > 1) port debug mode to tr1 associative containers > 2) move ext/hash containers to deprecated > > Thoughts? Certainly, I agree with the (mid term?) plan! > Anyway. > > This issue is a macro name mix-up. Here's I'll check in the attached fix > shortly. ... short term, however, seems a good idea manage to keep the ext facilities working (well, our own testsuite infrastructure still uses the hash_* containers and adding -D_GLIBCXX_DEBUG to the testing switches broke testing completely, that's how I actually noticed ;)
Subject: Bug 33633 Author: bkoz Date: Wed Oct 10 15:23:59 2007 New Revision: 129210 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=129210 Log: 2007-10-10 Benjamin Kosnik <bkoz@redhat.com> PR libstdc++/33633 * include/debug/hash_multimap.h: Change _GLIBCXX_EXT to _GLIBCXX_EXT_D. * include/debug/hash_set.h: Same. * include/debug/hash_multiset.h: Same. * include/debug/hash_map.h: Same. 2007-10-10 Benjamin Kosnik <bkoz@redhat.com> * include/parallel/losertree.h (loser_tree_traits_unguarded): To loser_tree_unguarded_traits. * include/parallel/multiway_merge.h (__gnu_parallel): Same. Modified: trunk/libstdc++-v3/ChangeLog trunk/libstdc++-v3/include/debug/hash_map.h trunk/libstdc++-v3/include/debug/hash_multimap.h trunk/libstdc++-v3/include/debug/hash_multiset.h trunk/libstdc++-v3/include/debug/hash_set.h trunk/libstdc++-v3/include/parallel/losertree.h trunk/libstdc++-v3/include/parallel/multiway_merge.h
Fixed. Current debug mode results (ie, with make CXXFLAGS="-D_GLIBCXX_DEBUG" check) FAIL: 20_util/pair/moveable.cc execution test FAIL: 23_containers/deque/moveable.cc execution test FAIL: 23_containers/headers/bitset/synopsis.cc (test for excess errors) FAIL: 23_containers/headers/deque/synopsis.cc (test for excess errors) FAIL: 23_containers/headers/list/synopsis.cc (test for excess errors) FAIL: 23_containers/headers/map/synopsis.cc (test for excess errors) FAIL: 23_containers/headers/set/synopsis.cc (test for excess errors) FAIL: 23_containers/headers/vector/synopsis.cc (test for excess errors) FAIL: 23_containers/list/moveable.cc execution test FAIL: 23_containers/map/moveable.cc execution test FAIL: 23_containers/map/operators/1_neg.cc (test for errors, line 210) FAIL: 23_containers/map/operators/1_neg.cc (test for errors, line 214) FAIL: 23_containers/multimap/moveable.cc execution test FAIL: 23_containers/multiset/moveable.cc execution test FAIL: 23_containers/set/moveable.cc execution test FAIL: 23_containers/set/operators/1_neg.cc (test for errors, line 285) FAIL: 23_containers/set/operators/1_neg.cc (test for errors, line 289) FAIL: 23_containers/vector/bool/capacity/29134.cc (test for excess errors) WARNING: 23_containers/vector/bool/capacity/29134.cc compilation failed to produce executable FAIL: 23_containers/vector/bool/modifiers/insert/31370.cc (test for excess errors) WARNING: 23_containers/vector/bool/modifiers/insert/31370.cc compilation failed to produce executable FAIL: 23_containers/vector/moveable.cc execution test WARNING: program timed out. FAIL: 25_algorithms/nth_element/2.cc execution test XPASS: 26_numerics/headers/cmath/c99_classification_macros_c.cc (test for excess errors) WARNING: program timed out. FAIL: ext/pb_ds/example/erase_if.cc execution test FAIL: ext/pb_ds/example/hash_illegal_resize.cc execution test FAIL: ext/pb_ds/example/hash_mod.cc execution test FAIL: ext/pb_ds/example/hash_shift_mask.cc execution test FAIL: ext/pb_ds/example/ranged_hash.cc execution test FAIL: ext/pb_ds/regression/hash_data_map_rand.cc execution test FAIL: ext/pb_ds/regression/hash_no_data_map_rand.cc execution test FAIL: ext/pb_ds/regression/priority_queue_rand.cc execution test FAIL: ext/pb_ds/regression/tree_data_map_rand.cc execution test FAIL: ext/pb_ds/regression/tree_no_data_map_rand.cc execution test FAIL: ext/pb_ds/regression/trie_data_map_rand.cc execution test FAIL: ext/pb_ds/regression/trie_no_data_map_rand.cc execution test === libstdc++ Summary === # of expected passes 5328 # of unexpected failures 33 # of unexpected successes 1 # of expected failures 57 # of unsupported tests 18 The pb_ds code fails are related to _GLIBCXX_DEBUG, but not debug-mode. The "synopsis.cc" fails are actually testing something illegal: user-defined forward declarations, so they can be ignored. These are decent results, but not spectacular. -benjamin
Yes, time to fix the moveable.cc tests in debug-mode. Thanks.
The moveable.cc fails are now fixed. Otherwise, a couple of fails are also trivial 23_containers/vector/bool/capacity/29134.cc 23_containers/vector/bool/modifiers/insert/31370.cc _S_word_size in the wrong namespace. And 25_algorithms/nth_element/2.cc it's just slow in debug-mode, succeeds after ~1 min for me.
Sweet, thanks. Any chance you could put in the 23_containers/vector/bool/capacity/29134.cc 23_containers/vector/bool/modifiers/insert/31370.cc fix too? My sources are in pre-deprecate mode right now... best, benjamin
I don't have a fix ;) Everything seems rather ugly and not worth the trouble...