[Bug libstdc++/51845] [4.7 regression] 23_containers/unordered_multimap/erase/24061-multimap.cc segfault

krebbel at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Sun Jan 15 17:22:00 GMT 2012


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51845

--- Comment #12 from Andreas Krebbel <krebbel at gcc dot gnu.org> 2012-01-15 17:00:42 UTC ---
(In reply to comment #8)
> But ElectricFence should work even on s390 31-bit.  Can you please try that?

I've linked libstdc++ against electric fence. The segfault appears to get
triggered somewhere else then.

gdb ./24061-multimap.exe 
GNU gdb (GDB) Fedora (7.2.50.20110206-18.fc13)
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "s390-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from
/build/gcc-headnew-build/s390-ibm-linux-gnu/libstdc++-v3/testsuite/24061-multimap.exe...done.
(gdb) r
Starting program:
/build/gcc-headnew-build/s390-ibm-linux-gnu/libstdc++-v3/testsuite/24061-multimap.exe 
[Thread debugging using libthread_db enabled]

  Electric Fence 2.1 Copyright (C) 1987-1998 Bruce Perens.

Program received signal SIGSEGV, Segmentation fault.
_M_get_previous_node (__n=0x77b95ff0, __bkt=10, this=<optimized out>)
    at
/build/gcc-headnew-build/s390-ibm-linux-gnu/libstdc++-v3/include/bits/hashtable.h:1175
1175              while (__prev_n->_M_next != __n)
(gdb) bt
#0  _M_get_previous_node (__n=0x77b95ff0, __bkt=10, this=<optimized out>)
    at
/build/gcc-headnew-build/s390-ibm-linux-gnu/libstdc++-v3/include/bits/hashtable.h:1175
#1  std::_Hashtable<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, std::pair<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > const, int>,
std::allocator<std::pair<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > const, int> >,
std::_Select1st<std::pair<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > const, int> >, std::equal_to<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::hash<std::basic_string<char, std::char_traits<char>, std::allocator<char>
> >, std::__detail::_Mod_range_hashing, std::__detail::_Default_ranged_hash,
std::__detail::_Prime_rehash_policy, true, false, false>::erase
(this=0x7fffec14, __it=...)
    at
/build/gcc-headnew-build/s390-ibm-linux-gnu/libstdc++-v3/include/bits/hashtable.h:1363
#2  0x0040244c in test01 ()
    at
/build/gcc-headnew/libstdc++-v3/testsuite/23_containers/unordered_multimap/erase/24061-multimap.cc:81
#3  0x00400a14 in main ()
    at
/build/gcc-headnew/libstdc++-v3/testsuite/23_containers/unordered_multimap/erase/24061-multimap.cc:106
(gdb)



More information about the Gcc-bugs mailing list