public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* DW_AT_containing_type
@ 2003-06-12 17:56 David Carlton
  2003-06-12 18:07 ` DW_AT_containing_type Daniel Jacobowitz
  0 siblings, 1 reply; 3+ messages in thread
From: David Carlton @ 2003-06-12 17:56 UTC (permalink / raw)
  To: gdb; +Cc: Daniel Jacobowitz, Elena Zannoni, Jim Blandy

What's with GDB's and GCC's use of DW_AT_containing type?  As far as I
can tell, it's only supposed to be used within
DW_TAG_ptr_to_member_type, but GCC generates it and GDB uses it in
many other contexts.

I'll try to find time to figure out how we use it later, but I wanted
to raise the issue in case anybody knows the answer or in case other
people aren't aware that we seem to be misusing it.

David Carlton
carlton@kealia.com

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: DW_AT_containing_type
  2003-06-12 17:56 DW_AT_containing_type David Carlton
@ 2003-06-12 18:07 ` Daniel Jacobowitz
  2003-06-12 18:16   ` DW_AT_containing_type David Carlton
  0 siblings, 1 reply; 3+ messages in thread
From: Daniel Jacobowitz @ 2003-06-12 18:07 UTC (permalink / raw)
  To: David Carlton; +Cc: gdb, Elena Zannoni, Jim Blandy

On Thu, Jun 12, 2003 at 10:56:50AM -0700, David Carlton wrote:
> What's with GDB's and GCC's use of DW_AT_containing type?  As far as I
> can tell, it's only supposed to be used within
> DW_TAG_ptr_to_member_type, but GCC generates it and GDB uses it in
> many other contexts.
> 
> I'll try to find time to figure out how we use it later, but I wanted
> to raise the issue in case anybody knows the answer or in case other
> people aren't aware that we seem to be misusing it.

We are misusing it.  See the GCC source for a comment explaining this
GNU extension.  We use it to indicate which base type contains the
vtable pointer for the derived class; there are a number of other ways
to do it, and at one point we should switch to another way.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: DW_AT_containing_type
  2003-06-12 18:07 ` DW_AT_containing_type Daniel Jacobowitz
@ 2003-06-12 18:16   ` David Carlton
  0 siblings, 0 replies; 3+ messages in thread
From: David Carlton @ 2003-06-12 18:16 UTC (permalink / raw)
  To: Daniel Jacobowitz; +Cc: gdb, Elena Zannoni, Jim Blandy

On Thu, 12 Jun 2003 14:07:14 -0400, Daniel Jacobowitz <drow@mvista.com> said:
> On Thu, Jun 12, 2003 at 10:56:50AM -0700, David Carlton wrote:

>> What's with GDB's and GCC's use of DW_AT_containing type?  As far as I
>> can tell, it's only supposed to be used within
>> DW_TAG_ptr_to_member_type, but GCC generates it and GDB uses it in
>> many other contexts.

> We are misusing it.  See the GCC source for a comment explaining
> this GNU extension.  We use it to indicate which base type contains
> the vtable pointer for the derived class; there are a number of
> other ways to do it, and at one point we should switch to another
> way.

Ah, thanks for the explanation.

David Carlton
carlton@math.stanford.edu

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2003-06-12 18:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-06-12 17:56 DW_AT_containing_type David Carlton
2003-06-12 18:07 ` DW_AT_containing_type Daniel Jacobowitz
2003-06-12 18:16   ` DW_AT_containing_type David Carlton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).