From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25438 invoked by alias); 9 May 2003 14:10:14 -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 25419 invoked from network); 9 May 2003 14:10:13 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sources.redhat.com with SMTP; 9 May 2003 14:10:13 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.11.6/8.11.6) with ESMTP id h49EADH22415 for ; Fri, 9 May 2003 10:10:13 -0400 Received: from pobox.corp.redhat.com (pobox.corp.redhat.com [172.16.52.156]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id h49EADI16906 for ; Fri, 9 May 2003 10:10:13 -0400 Received: from localhost.redhat.com (romulus-int.sfbay.redhat.com [172.16.27.46]) by pobox.corp.redhat.com (8.11.6/8.11.6) with ESMTP id h49E9x823870; Fri, 9 May 2003 10:10:05 -0400 Received: by localhost.redhat.com (Postfix, from userid 469) id 6EF592C439; Fri, 9 May 2003 10:15:05 -0400 (EDT) From: Elena Zannoni MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <16059.47081.289185.757260@localhost.redhat.com> Date: Fri, 09 May 2003 14:10:00 -0000 To: Daniel Jacobowitz Cc: Roland McGrath , Mark Kettenis , gdb@sources.redhat.com Subject: Re: gdb/dwarf-frame.c In-Reply-To: <20030509134135.GA20959@nevyn.them.org> References: <200305090945.h499jTH13137@magilla.sf.frob.com> <20030509134135.GA20959@nevyn.them.org> X-SW-Source: 2003-05/txt/msg00122.txt.bz2 Daniel Jacobowitz writes: > On Fri, May 09, 2003 at 02:45:29AM -0700, Roland McGrath wrote: > > (Hi Mark! It's been too long since we hacked together.) > > [Please note that I am not on the mailing list, so keep me CC'd directly.] > > > > I have been looking at the kettenis_i386newframe-20030419-branch gdb code. > > I've been told that the new dwarf-frame.c replaces the dwarf2cfi.c code > > that's on mainline. I don't know the guts of either or of DWARF2 itself > > well enough to compare them. > > > > What I have noticed is that dwarf-frame.c does not seem to handle the > > .eh_frame section, only the .debug_frame section. The dwarf2cfi.c code > > looks at both. As well as looking for the section, it needs to grok the > > "augmentation" values and different encodings used in .eh_frame, and I > > don't see any of that handled in the new code. Is this an intentional > > omission and if so what is the rationale? > > My understanding from Mark's earlier post is that it is an intentional > but probably temporary omission - since dwarf-frame is only a week or > two old at this point. > > > I think grokking .eh_frame sections in the absence of .debug_frame is a > > nice thing in general--it might give you at least some more helpful > > backtraces than otherwise when dealing with binaries without debugging > > info. But the particular reason it is of concern to me is that it's needed > > for unwinding PC values within the special kernel entrypoint page now being > > used in Linux on x86. glibc now uses this entrypoint code for every system > > call, and so any thread blocked in a system call (which most threads one > > looks at are when one starts looking) will have its PC inside this code and > > need to be able to unwind that frame-pointer-less leaf frame to produce a > > useful backtrace. This is magic kernel code for which there is never going > > to be debugging information, but for which we do have .eh_frame information > > we can get at. I am setting about attacking how we get at it in all the > > relevant cases, but I had been working from the assumption that upon > > locating some information in .eh_frame form (including "zR" augmentation > > and pcrel pointer encoding) it would plug easily into the DWARF2 unwinding > > machinery. If that's not so, it throws a monkey wrench into my plans. > > Should any work even be necessary? My understanding was that the > kernel code would show up in the shared library list. Oh, I guess it > is - we usually locate .eh_frame via BFD, which means section headers > and an on-disk file. I see. > Which reminds me that we should probably have the NPTL thread support patches integrated in gdb as well, since we are at this (and I have your attention). Can somebody (Daniel, Mark?) take a look at the patches? I can guarentee that they work, since they were shipped with RHL9's gdb. elena > -- > Daniel Jacobowitz > MontaVista Software Debian GNU/Linux Developer