From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25617 invoked by alias); 29 Dec 2010 06:25:40 -0000 Received: (qmail 25598 invoked by uid 22791); 29 Dec 2010 06:25:38 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 29 Dec 2010 06:25:32 +0000 From: "liguanglei at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/42679] RTLD_DEEPBIND dlopen option for shared library that uses libstdc++ std::ostream crashes X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libstdc++ X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: liguanglei at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: CC Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Date: Wed, 29 Dec 2010 06:25:00 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-12/txt/msg02835.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42679 Li Guanglei changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |liguanglei at gmail dot com --- Comment #18 from Li Guanglei 2010-12-29 06:25:28 UTC --- Hi, I met the same bug on redhat 6.0 of x86_64. I use dlopen with -RTLD_DEEPBIND flag in my program, but it will crash once I start my program. But the this program runs well on SLES. And if I compiled using '-g' or '-O0', then it won't crash. Could someone help to look at this? It stops our product running on RH6/x86_64 liguangl:/u/liguangl/debugging> uname -a Linux pexserv02.cn.ibm.com 2.6.32-71.el6.x86_64 #1 SMP Wed Sep 1 01:33:01 EDT 2010 x86_64 x86_64 x86_64 GNU/Linux liguangl:/u/liguangl/debugging> cat /etc/redhat-release Red Hat Enterprise Linux Server release 6.0 (Santiago) Here is the backtrace: (gdb) where #0 0x000000362b4329a5 in raise () from /lib64/libc.so.6 #1 0x000000362b434185 in abort () from /lib64/libc.so.6 #2 0x000000362b46fd5b in __libc_message () from /lib64/libc.so.6 #3 0x000000362b475676 in malloc_printerr () from /lib64/libc.so.6 #4 0x000000363049ded1 in std::basic_string, std::allocator >::_M_mutate(unsigned long, unsigned long, unsigned long) () from /usr/lib64/libstdc++.so.6 #5 0x000000363049df1c in std::basic_string, std::allocator >::_M_replace_safe(unsigned long, unsigned long, char const*, unsigned long) () from /usr/lib64/libstdc++.so.6 #6 0x00007f86d4aed228 in Log::init(char const*, char const*, int) () from /usr/lib64/libsci.so #7 0x00007f86d4affa99 in Initializer::init() () from /usr/lib64/libsci.so #8 0x00000000004188a7 in pm_contact (nprocs=, n_masters=, nodes=) at /project/sprelbar/build/currentbar/src/ppe/poe/src/pm/poe/pm_contact.c:1337 #9 0x00000000004200c1 in pm_mgr_init (nargs=, argv=, env=0x7fff857ee970) at /project/sprelbar/build/currentbar/src/ppe/poe/src/pm/poe/pm_manager.c:523 #10 0x0000000000406ed0 in main (argc=1, argv=0x7fff857ee958, env=0x7fff857ee970) at /project/sprelbar/build/currentbar/src/ppe/poe/src/pm/poe/pm_poe.c:779