[PATCH] Do not split variables definitions into 2 DIEs.

Frederic Riss friss at apple.com
Tue Sep 23 01:05:30 PDT 2014


Hi dblaikie, echristo, aprantl,

This is currently done for variables that aren't a file or function scope, but
the reason is unclear and might be historical. Static class member where
handled specifically and always generated a DW_TAG_member declarartion and
a DW_TAG_variable instance. This patch removes all these and only ever emits
one definition DIE, be it a DW_TAG_variable or a DW_TAG_member.

It would be good to get a gdb testsuite run with the patch applied before it
goes in to prevent any fallback (and I guess this kind of patch has a huge
fallback potential). I'll try to run lldb tests on my side.

http://reviews.llvm.org/D5457

Files:
  lib/CodeGen/AsmPrinter/DwarfDebug.cpp
  lib/CodeGen/AsmPrinter/DwarfUnit.cpp
  test/DebugInfo/X86/debug-info-static-member.ll
  test/DebugInfo/X86/gnu-public-names.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D5457.13974.patch
Type: text/x-patch
Size: 12068 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140923/b52e224d/attachment.bin>


More information about the llvm-commits mailing list