From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15316 invoked by alias); 29 Jul 2008 12:46:16 -0000 Received: (qmail 15304 invoked by uid 22791); 29 Jul 2008 12:46:16 -0000 X-Spam-Check-By: sourceware.org Received: from igw3.br.ibm.com (HELO igw3.br.ibm.com) (32.104.18.26) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 29 Jul 2008 12:45:55 +0000 Received: from mailhub1.br.ibm.com (unknown [9.18.232.109]) by igw3.br.ibm.com (Postfix) with ESMTP id 31BDE390104 for ; Tue, 29 Jul 2008 09:27:00 -0300 (BRST) Received: from d24av02.br.ibm.com (d24av02.br.ibm.com [9.18.232.47]) by mailhub1.br.ibm.com (8.13.8/8.13.8/NCO v9.0) with ESMTP id m6TCjrag1978632 for ; Tue, 29 Jul 2008 09:45:54 -0300 Received: from d24av02.br.ibm.com (loopback [127.0.0.1]) by d24av02.br.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id m6TCjlX4007748 for ; Tue, 29 Jul 2008 09:45:48 -0300 Received: from [9.8.11.76] ([9.8.11.76]) by d24av02.br.ibm.com (8.12.11.20060308/8.12.11) with ESMTP id m6TCjk6o006970 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 29 Jul 2008 09:45:47 -0300 Subject: Re: [PATCH] Handle absence of DT_DEBUG while debugging ld.so From: Luis Machado Reply-To: luisgpm@linux.vnet.ibm.com To: Daniel Jacobowitz Cc: gdb-patches@sourceware.org, Pedro Alves In-Reply-To: <20080729121244.GA2175@caradoc.them.org> References: <1217289278.16935.23.camel@gargoyle> <20080729022723.GA6298@caradoc.them.org> <1217300235.16935.35.camel@gargoyle> <20080729121244.GA2175@caradoc.them.org> Content-Type: text/plain Date: Tue, 29 Jul 2008 12:46:00 -0000 Message-Id: <1217335536.16935.57.camel@gargoyle> Mime-Version: 1.0 X-Mailer: Evolution 2.12.1 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2008-07/txt/msg00537.txt.bz2 On Tue, 2008-07-29 at 08:12 -0400, Daniel Jacobowitz wrote: > On Mon, Jul 28, 2008 at 11:57:15PM -0300, Luis Machado wrote: > > Yes, this specific address seems broken somehow. This is the first > > _r_debug entry GDB gets: > > Looks like the section offsets are not set yet. > > > And this is the next _r_debug minimal symbol entry GDB gets: > > What do you mean by "next"? What commands did you use to get this > output? "Next" as in the entry GDB locates in the next time it calls elf_locate_base(...), this time solib_create_inferior_hook(...) is in the code path after post_create_inferior(...): #0 elf_locate_base () at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib-svr4.c:494 #1 0x00000000100af30c in locate_base () at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib-svr4.c:570 #2 0x00000000100af9a4 in svr4_current_sos () at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib-svr4.c:760 #3 0x00000000100ad208 in update_solib_list (from_tty=0, target=0x108fd990) at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib.c:494 #4 0x00000000100ad630 in solib_add (pattern=0x0, from_tty=0, target=0x108fd990, readsyms=1) at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib.c:677 #5 0x00000000100b0058 in enable_break () at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib-svr4.c:989 #6 0x00000000100b0a94 in svr4_solib_create_inferior_hook () at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib-svr4.c:1408 #7 0x00000000100adc60 in solib_create_inferior_hook () at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib.c:884 #8 0x00000000101973e8 in post_create_inferior (target=0x108fd990, from_tty=0) at /home/luis/src/gdb/gdb-head/HEAD3/gdb/infcmd.c:441 ... whereas the first time it was called: #0 elf_locate_base () at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib-svr4.c:494 #1 0x00000000100af30c in locate_base () at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib-svr4.c:570 #2 0x00000000100af9a4 in svr4_current_sos () at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib-svr4.c:760 #3 0x00000000100ad208 in update_solib_list (from_tty=0, target=0x108fd990) at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib.c:494 #4 0x00000000100ad630 in solib_add (pattern=0x0, from_tty=0, target=0x108fd990, readsyms=1) at /home/luis/src/gdb/gdb-head/HEAD3/gdb/solib.c:677 #5 0x00000000101973e0 in post_create_inferior (target=0x108fd990, from_tty=0) at /home/luis/src/gdb/gdb-head/HEAD3/gdb/infcmd.c:433 > Also, with GDB 6.8 I can "continue" after this error. With HEAD: > > Continuing. > Cannot execute this command while the selected thread is running. > > Hey, Pedro? Cleanup trouble? Yes, i discussed this with Pedro yesterday and he's aware of the problem. Luis