From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30211 invoked by alias); 5 Dec 2003 17:40:20 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 30204 invoked from network); 5 Dec 2003 17:40:19 -0000 Received: from unknown (HELO nevyn.them.org) (66.93.172.17) by sources.redhat.com with SMTP; 5 Dec 2003 17:40:19 -0000 Received: from drow by nevyn.them.org with local (Exim 4.24 #1 (Debian)) id 1ASJwB-0007RM-7q for ; Fri, 05 Dec 2003 12:40:19 -0500 Date: Fri, 05 Dec 2003 17:40:00 -0000 From: Daniel Jacobowitz To: gdb-patches@sources.redhat.com Subject: Re: [rfa/c++] cp_lookup_rtti_type, take 2 Message-ID: <20031205174018.GA28584@nevyn.them.org> Mail-Followup-To: gdb-patches@sources.redhat.com References: <20031205042237.56AFD4B35C@berman.michael-chastain.com> <20031205171658.GB27834@nevyn.them.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.1i X-SW-Source: 2003-12/txt/msg00216.txt.bz2 On Fri, Dec 05, 2003 at 09:38:52AM -0800, David Carlton wrote: > On Fri, 5 Dec 2003 12:16:58 -0500, Daniel Jacobowitz said: > > > How do you suggest we do it? Some new addition to the debug info? I > > don't believe we have anything at the moment that fills this need. > > Hmm. I thought I'd seen something appropriate in the debug info, but > now I realize that I was looking for the slot for the vtable in the > class, which is a quite different matter. > > Well, here's what I see when looking for a vtable symbol in a sample > file: > > .uleb128 0x1d # (DIE (0x20d) DW_TAG_variable) > .long .LC9 # DW_AT_name: "_ZTI1C" > .long 0x21e # DW_AT_type > .byte 0x1 # DW_AT_external > .byte 0x1 # DW_AT_artificial > .byte 0x5 # DW_AT_location > .byte 0x3 # DW_OP_addr > .long _ZTI1C > > So DW_TAG_variable + DW_AT_artificial is a start - looking for that > (plus perhaps guiltily peeking at the demanged name just to make sure > it starts with 'typeinfo') lets us find the vtable symbols. But that > doesn't help - the DW_AT_type doesn't actually lead us to the type > that it's the vtable for, and certainly none of the other attributes > are going to help. > > Sigh. If you think this _should_ be in the debug info, you may want to draft a proposed extension. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer