From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18824 invoked by alias); 6 Apr 2006 03:35:45 -0000 Received: (qmail 18815 invoked by uid 22791); 6 Apr 2006 03:35:45 -0000 X-Spam-Check-By: sourceware.org Received: from romy.inter.net.il (HELO romy.inter.net.il) (192.114.186.66) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 06 Apr 2006 03:35:43 +0000 Received: from HOME-C4E4A596F7 (IGLD-83-130-213-56.inter.net.il [83.130.213.56]) by romy.inter.net.il (MOS 3.7.3-GA) with ESMTP id DXE85504 (AUTH halo1); Thu, 6 Apr 2006 06:35:34 +0300 (IDT) Date: Thu, 06 Apr 2006 03:35:00 -0000 Message-Id: From: Eli Zaretskii To: gdb@sources.redhat.com In-reply-to: <20060406032702.GE11610@brasko.net> (message from Bob Rossi on Wed, 5 Apr 2006 23:27:02 -0400) Subject: Re: text file formats Reply-to: Eli Zaretskii References: <20060405223122.GB11610@brasko.net> <20060405233938.GA11013@nevyn.them.org> <20060406001455.GC11610@brasko.net> <20060406011732.GA12814@nevyn.them.org> <20060406032702.GE11610@brasko.net> X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2006-04/txt/msg00047.txt.bz2 > Date: Wed, 5 Apr 2006 23:27:02 -0400 > From: Bob Rossi > > > I have no idea what you mean. GDB gets line numbers from debug info, > > of course; where else would it get them? > > Does the debug info actually say, "at line 100 symbol foo() exists?" No, it says, for every source line, which PC addresses correspond to that source line. That is all GDB needs to know, because it manipulates PC addresses (i.e. addresses in the .text section). For symbols, the debug info says that symbol `foo' is stored in the .text or .data section (or .bss or something else) at address NNN. > OK, I'm sorry, as usual I'm describing this bad. Let's start out by > trying to agree with an assumption that I have. Since the file is in a > mixed format, is it true that the line number is determined ambiguously > by the program reading the file? Not necessarily, see my other message.