From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19359 invoked by alias); 20 Jun 2002 16:06:02 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 19340 invoked by uid 71); 20 Jun 2002 16:06:01 -0000 Date: Thu, 20 Jun 2002 09:46:00 -0000 Message-ID: <20020620160601.19339.qmail@sources.redhat.com> To: nobody@gcc.gnu.org Cc: gcc-prs@gcc.gnu.org, From: Daniel Jacobowitz Subject: Re: c++/7081: DWARF enhancements for C++ Reply-To: Daniel Jacobowitz X-SW-Source: 2002-06/txt/msg00461.txt.bz2 List-Id: The following reply was made to PR c++/7081; it has been noted by GNATS. From: Daniel Jacobowitz To: jcownie@etnus.com Cc: gcc-gnats@gcc.gnu.org Subject: Re: c++/7081: DWARF enhancements for C++ Date: Thu, 20 Jun 2002 12:04:59 -0400 On Thu, Jun 20, 2002 at 10:13:22AM +0100, jcownie@etnus.com wrote: > > >Number: 7081 > >Category: c++ > >Synopsis: DWARF enhancements for C++ > >Confidential: no > >Severity: non-critical > >Priority: medium > >Responsible: unassigned > >State: open > >Class: change-request > >Submitter-Id: net > >Arrival-Date: Thu Jun 20 02:16:04 PDT 2002 > >Closed-Date: > >Last-Modified: > >Originator: James Cownie > >Release: 3.1 > >Organization: > Etnus LLC > >Environment: > System: Linux pc4 2.4.18 #1 Tue Apr 2 10:17:01 BST 2002 i686 unknown > Architecture: i686 > > > host: i686-pc-linux-gnu > build: i686-pc-linux-gnu > target: i686-pc-linux-gnu > configured with: /home1/GNU/gcc-3.1/configure > >Description: > 1) g++ emits classes in DWARF with the DW_TAG_structure_type rather > than the DW_TAG_class_type which is suggested in the DWARF V3 > specification. This makes it hard for a debugger to show the type > name correctly since it can't tell whether the class was _really_ > introduced by the class or struct keywords. This one's true, but... > 2) g++ does not emit any debug information for the vtable pointer in > classes with virtual functions. It would be much nicer if this > information were emitted (tagged with AT_artificial), since it's > often very useful to be able to see the vtable pointer while > debugging, as that's how one can work out which class an object > _actually_ is when one is looking at a base class pointer. This one isn't really necessary. The ABI specifies where the vtable pointer will be, and GDB is quite capable of using that knowledge to identify the runtime type. I believe even 'whatis' will do this for you. Whichever debugger you're using must have an understanding of the binary's ABI to debug C++ anyway... -- Daniel Jacobowitz Carnegie Mellon University MontaVista Software Debian GNU/Linux Developer