DebugInfo: Don't include the name of the CU file in the line table file list when...
authorDavid Blaikie <dblaikie@gmail.com>
Fri, 14 Feb 2014 01:57:59 +0000 (01:57 +0000)
committerDavid Blaikie <dblaikie@gmail.com>
Fri, 14 Feb 2014 01:57:59 +0000 (01:57 +0000)
commit35d2f6151024a63b4bf84730aaa88e34413a8220
tree5d4087ce00f692a05cdacf316a5f4804ee63cb73
parent5483012b4d4aef505272f1a310e5620a706a7b84
DebugInfo: Don't include the name of the CU file in the line table file list when it's unneeded

Recommitting r201351 and r201355 (reverted in r201351 and r201355)

We weren't emitting the an empty (header only) line table when the line
table was empty - this made the DWARF invalid (the compile unit would
point to the zero-size debug_lines section where there should've been an
empty line table but there was nothing at all). Fix that, and as a
consequence this works around/addresses PR18809.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@201380 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/AsmPrinter/DwarfDebug.cpp
lib/MC/MCObjectStreamer.cpp
test/DebugInfo/X86/generate-odr-hash.ll
test/DebugInfo/empty.ll [new file with mode: 0644]