[LLVMdev] Inline Symbolication with -gsplit-dwarf

David Blaikie dblaikie at gmail.com
Tue Nov 4 16:32:54 PST 2014


So, after many shenanigans, we finally have -gmlt-like inline summary debug
info in .debug_info when using -gsplit-dwarf (see r221306). Hooray \o/

Testing this with asan, it seems to be working:

Given a simple example of inlining failure:
$ cat asan.cpp
__attribute__((always_inline)) inline void func(int* i) { *i = 3; }

int main() {
  func(nullptr);
}

The failures before this change:

    #0 0x4a320e in func(int*) /tmp/dbginfo/asan.cpp:1:59
    #1 0x4a320e in main /tmp/dbginfo/asan.cpp:4

And then if we delete the .dwo (to simulate running on another machine,
etc, etc):

    #0 0x4a320e in main /tmp/dbginfo/asan.cpp:1:59

So we get the expected weird mixed stack frame.

Then, with the improvements, we see:

    #0 0x4a320e in func /tmp/dbginfo/asan.cpp:1:59
    #1 0x4a320e in main /tmp/dbginfo/asan.cpp:4

One minor quality issue: If we leave the .dwo file in, we still get this
last output (the symbolizer is favoring the data in the .o file, by the
looks of it, rather than the .dwo file) rather than the extra detail of the
function's parameter types, etc.

Just thought I'd mention it in case that's a thing you'd like to see
fixed/worry about.

- David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20141104/b7ef0b9f/attachment.html>


More information about the llvm-dev mailing list