This is the mail archive of the
gcc-prs@gcc.gnu.org
mailing list for the GCC project.
debug/8094: bad dwarf for inlined constructors
- From: tom dot horsley at ccur dot com
- To: gcc-gnats at gcc dot gnu dot org
- Date: 30 Sep 2002 12:34:03 -0000
- Subject: debug/8094: bad dwarf for inlined constructors
- Reply-to: tom dot horsley at ccur dot com
>Number: 8094
>Category: debug
>Synopsis: bad dwarf for inlined constructors
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Mon Sep 30 05:36:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator: tom.horsley@ccur.com
>Release: gcc-3.2
>Organization:
>Environment:
redhat linux null beta release
>Description:
Apparently for some kind of multiple inheritance "optimization" g++ generates two separate copies of a constructor even when there is only one in the source and no inline was specified.
It creates debug info for both these constructors as though they were inlined, with two concrete instances and one abstract instance.
The concrete DIEs are all supposed to have DW_AT_abstract_origin attributes, pointing to the corresponding DIE in the abstract instance.
The dwarf generated by gcc 3.2 is missing the abstract
origin information for some DIEs in the concrete instance.
Specifically DW_TAG_lexical_block DIEs never seem to have
any abstract origin specified.
>How-To-Repeat:
I'm not sure when g++ decides to duplicate constructors like this, but if you can get it to do that, simply make the constructor big an complex enough to have inner lexical blocks, and you will see they never have abstract origin info.
P.S. Why it duplicates the entire constructor (which can be arbitrarily gigantic) instead of simply providing some little wrappers to do the vtable work is probably a subject for a different bug report :-).
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted: