[LLVMdev] Issue with incomplete type debug info in recent release_35

David Blaikie dblaikie at gmail.com
Wed Oct 1 08:27:32 PDT 2014


On Wed, Oct 1, 2014 at 3:45 AM, martin krastev <blu.dark at gmail.com> wrote:

> Hello,
>
> disclaimer/ Apologies if this is the wrong llvm/clang mailing list;
> please, direct me to the right one if needed. /disclaimer
>
> I've been experiencing issues with incomplete type info when debugging
> code generated by clang 3.5.0 from the recent release_35 branch.
>
> Generally, the problem manifests itself as the inability to examine any
> std::string parameter to a function, in either gdb or lldb:
>
> (lldb) p arg_string
> (std::string) $4 = error: summary string parsing error
>
> (gdb) p arg_string
> $2 = (const std::string &) @0x7fffffffd948: <incomplete type>
>
> This is observed on two separate amd64 machines under Ubuntu 12.04, with
> both the nightly build packages from the llvm-toolchain-precise-3.5 repo (
> http://llvm.org/apt/) and when built locally from svn branch release_35.
> It bears noting that on the same machines an older, locally-built version
> of pre-3.5.0 (trunk circa rev 198K) does not exhibit the problem.
>
> Is that a known regression, or shall I try to file a ticket for it?
>

Do you have the -dbg package of your standard library installed? Try
installing that and see if it resolves the issue.

There are some improvements to debug info size that rely on the whole
project (and library dependencies) being built with debug info enabled (GCC
does similar optimizations, FWIW - though not the one that's firing on
std::string specifically). Or if you'd just rather turn off the
optimization, pass -fstandalone-debug.

If neither of those things work - please file a bug with a reduced test
case, etc.

(for the record, the specific commit that likely caused the change in
behavior you're observing is
http://llvm.org/viewvc/llvm-project?rev=202769&view=rev (though we
implemented the optimization GCC already implemented a few months before
that - which applies to types with vtables, like standard iostreams))
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20141001/42a21b8e/attachment.html>


More information about the llvm-dev mailing list