From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23658 invoked by alias); 16 Feb 2004 03:45:26 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 23646 invoked from network); 16 Feb 2004 03:45:26 -0000 Received: from unknown (HELO lakemtao04.cox.net) (68.1.17.241) by sources.redhat.com with SMTP; 16 Feb 2004 03:45:26 -0000 Received: from white ([68.9.64.121]) by lakemtao04.cox.net (InterMail vM.5.01.06.05 201-253-122-130-105-20030824) with ESMTP id <20040216034527.IJPF19895.lakemtao04.cox.net@white> for ; Sun, 15 Feb 2004 22:45:27 -0500 Received: from bob by white with local (Exim 3.35 #1 (Debian)) id 1AsZhF-0000uM-00 for ; Sun, 15 Feb 2004 22:45:25 -0500 Date: Mon, 16 Feb 2004 03:45:00 -0000 From: Bob Rossi To: gdb@sources.redhat.com Subject: Re: [MI] -file-list-exec-source-files Message-ID: <20040216034525.GA3437@white> Mail-Followup-To: gdb@sources.redhat.com References: <20040213012946.GB4476@white> <20040216033008.GB2685@nevyn.them.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040216033008.GB2685@nevyn.them.org> User-Agent: Mutt/1.3.28i X-SW-Source: 2004-02/txt/msg00154.txt.bz2 On Sun, Feb 15, 2004 at 10:30:08PM -0500, Daniel Jacobowitz wrote: > On Thu, Feb 12, 2004 at 08:29:46PM -0500, Bob Rossi wrote: > > So, I have 2 solutions, > > 1. Modify the psytmab to also have the 'dirname'. Which seems > > difficult. Although I do think this is the best solution. (Not knowing > > to much about psymtabs and symtabs) > > > > 2. Change -file-list-exec-source-file to receive an optional filename, > > which when doing this causes GDB to read in the symtab associated with > > the psymtab. Then the fullname can be retrieved. > > The question is whether this information is available without having to > read full symtabs. Is this the dirname referenced in debug > information, or the dirname in which GDB has actually found the file? > I'm guessing that it's the latter, since so few debug readers bother to > fill in the former. If so we would have to search the directory path > for every file when generating psymtabs, which isn't acceptable. It > would take a fearsomely long time. Thanks for the response. Actually, I'm pretty sure it's the former. It's symtab->dirname, which seems to get filled in from the debug info. It looks like symtab->dirname gets set around buildsym.c:975. Is it bad to count on this feature if so few debug readers support the feature? It seems that at least "stabs" supports this feature. Currently, as far as I know, it's the only way things like annotate 1,2 and 3 work. That's the only reliable way GDB gets the absolute path to the source file, is that correct? If there is another method GDB figures out the absolute path to the source file, I would be interested in hearing it. Bob Rossi