public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Linking issue with _GLIBCXX_DEBUG on 4.7/google
@ 2012-10-22 21:02 Oleg Smolsky
  2012-10-22 23:12 ` Jonathan Wakely
  0 siblings, 1 reply; 3+ messages in thread
From: Oleg Smolsky @ 2012-10-22 21:02 UTC (permalink / raw)
  To: gcc-help

Hey all, I've just hit an issue when using _GLIBCXX_DEBUG together with 
Google's gcc 4.7 built using --enable-symvers=gnu-versioned-namespace 
flag. The issue is specific to unordered_mulimap and can be reproduced 
using the following:

struct MyType
{
};

#if 1
using MyMap = std::multimap<std::string, MyType *>;    // works
#else
using MyMap = std::unordered_multimap<std::string, MyType *>;    // 
fails to link
#endif

MyMap m;
m.insert({"blah"}, new MyType});

The latter variant fails to link with the following message:

In function 
`__gnu_debug::_Safe_unordered_container_base::~_Safe_unordered_container_base()':
statmgr.cc:(.text._ZN11__gnu_debug30_Safe_unordered_container_baseD2Ev[_ZN11__gnu_debug30_Safe_unordered_container_baseD5Ev]+0x15): 
undefined reference to 
`__gnu_debug::_Safe_unordered_container_base::_M_detach_all()'

The compiler was configured as follows:
Configured with: ../gcc47-google/configure 
--prefix=/opt/gcc-google-4.7-v7 --enable-languages=c,c++,lto 
--with-mpfr=/opt/gcc-4.6-rbt --with-cloog=/opt/gcc-4.6-rbt 
--with-mpc=/opt/gcc-4.6-rbt --with-gmp=/opt/gcc-4.6-rbt 
--with-system-zlib --disable-multilib --enable-lto 
--with-build-config=bootstrap-lto --with-fpmath=sse --enable-gold=yes 
--enable-cloog-backend=isl --disable-cloog-version-check 
--program-suffix=-google-4.7 --enable-symvers=gnu-versioned-namespace 
CFLAGS=-O3 CXXFLAGS='-O3 -mtune=core2'

Could someone shed some light on this please?

Thanks!
Oleg.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Linking issue with _GLIBCXX_DEBUG on 4.7/google
  2012-10-22 21:02 Linking issue with _GLIBCXX_DEBUG on 4.7/google Oleg Smolsky
@ 2012-10-22 23:12 ` Jonathan Wakely
  2012-10-23  5:21   ` Oleg Smolsky
  0 siblings, 1 reply; 3+ messages in thread
From: Jonathan Wakely @ 2012-10-22 23:12 UTC (permalink / raw)
  To: Oleg Smolsky; +Cc: gcc-help

On 22 October 2012 17:54, Oleg Smolsky wrote:
> Could someone shed some light on this please?

It looks like a bug, if you can reproduce it with the non-google 4.7
branch please report it to bugzilla.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Linking issue with _GLIBCXX_DEBUG on 4.7/google
  2012-10-22 23:12 ` Jonathan Wakely
@ 2012-10-23  5:21   ` Oleg Smolsky
  0 siblings, 0 replies; 3+ messages in thread
From: Oleg Smolsky @ 2012-10-23  5:21 UTC (permalink / raw)
  To: Jonathan Wakely; +Cc: gcc-help

On 2012-10-22 11:14, Jonathan Wakely wrote:
> On 22 October 2012 17:54, Oleg Smolsky wrote:
>> Could someone shed some light on this please?
> It looks like a bug, if you can reproduce it with the non-google 4.7
> branch please report it to bugzilla.
Right, stock 4.7.2 behaves in the same way:
     http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55028

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-10-22 21:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-22 21:02 Linking issue with _GLIBCXX_DEBUG on 4.7/google Oleg Smolsky
2012-10-22 23:12 ` Jonathan Wakely
2012-10-23  5:21   ` Oleg Smolsky

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).