This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: When to emit C++ debug info?
Daniel Jacobowitz <drow@mvista.com> writes:
...
> I'm not sure if it's a bug or deliberate. But even if it's fixed,
> debug info for the structure type won't fall out - we'll get a
> declaration only. That's what used to happen.
>
> I agree with you that it's wrong. I wanted some feedback before I
> tried to fix it, because:
> (A) I hate this bit of code; I get lost for weeks at a time in it
> (B) It may make our generated DWARF-2 a _lot_ bigger (but more useful)
I think we'll want to be able to do it these ways:
- One way where the minimal debugging information is emitted so that
when put together, the whole program has complete debugging
information; and
- Another way where complete information is emitted for a single file.
I'm not sure why you'd want something between these two extremes. I
don't think it's unreasonable to ask distributors to provide debugging
information for libraries; chances are, someone debugging a program is
going to want some debugging information for libraries anyway.
You can't just emit everything in every .o, unfortunately, because
that makes the .o files collectively too large.
--
- Geoffrey Keating <geoffk@geoffk.org>