<div dir="ltr">Fixed in r349395<br><br><div class="gmail_quote"><div dir="ltr">On Mon, Dec 17, 2018 at 1:11 PM David Blaikie <<a href="mailto:dblaikie@gmail.com">dblaikie@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Thanks Galina - looking into it!</div><br><div class="gmail_quote"><div dir="ltr">On Mon, Dec 17, 2018 at 12:43 PM Galina Kistanova <<a href="mailto:gkistanova@gmail.com" target="_blank">gkistanova@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div dir="ltr">Hello David,<br><br>It looks like this commit broke test to couple lto builders:<br>The builders were already broken on build step and did not reach test steps. And did not send notifications also on this.<br><br><a href="http://lab.llvm.org:8011/builders/clang-with-lto-ubuntu" target="_blank">http://lab.llvm.org:8011/builders/clang-with-lto-ubuntu</a><br><a href="http://lab.llvm.org:8011/builders/clang-with-thin-lto-ubuntu" target="_blank">http://lab.llvm.org:8011/builders/clang-with-thin-lto-ubuntu</a><br>. . .<br>Failing Tests (1):<br> LLVM :: tools/gold/X86/split-dwarf.ll<br><br>Please have a look?<br><br>Thanks</div></div><div dir="ltr"><div dir="ltr"><br><br>Galina<br></div></div><br><div class="gmail_quote"><div dir="ltr">On Fri, Dec 14, 2018 at 2:47 PM David Blaikie via llvm-commits <<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Author: dblaikie<br>
Date: Fri Dec 14 14:44:46 2018<br>
New Revision: 349207<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=349207&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=349207&view=rev</a><br>
Log:<br>
DebugInfo: Avoid using split DWARF when the split unit would be empty.<br>
<br>
In ThinLTO many split CUs may be effectively empty because of the lack<br>
of support for cross-unit references in split DWARF.<br>
<br>
Using a split unit in those cases is just a waste/overhead - and turned<br>
out to be one contributor to a significant symbolizer performance issue<br>
when global variable debug info was being imported (see r348416 for the<br>
primary fix) due to symbolizers seeing CUs with no ranges, assuming<br>
there might still be addresses covered and walking into the split CU to<br>
see if there are any ranges (when that split CU was in a DWP file, that<br>
meant loading the DWP and its index, the index was extra large because<br>
of all these fractured/empty CUs... and so was very expensive to load).<br>
<br>
(the 3rd fix which will follow, is to assume that a CU with no ranges is<br>
empty rather than merely missing its CU level range data - and to not<br>
walk into its DIEs (split or otherwise) in search of address information<br>
that is generally not present)<br>
<br>
Modified:<br>
llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp<br>
llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.h<br>
llvm/trunk/lib/CodeGen/AsmPrinter/DwarfFile.cpp<br>
llvm/trunk/test/DebugInfo/X86/fission-cu.ll<br>
llvm/trunk/test/DebugInfo/X86/fission-ranges.ll<br>
llvm/trunk/test/DebugInfo/X86/string-offsets-table-order.ll<br>
llvm/trunk/test/DebugInfo/X86/string-offsets-table.ll<br>
<br>
Modified: llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp?rev=349207&r1=349206&r2=349207&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp?rev=349207&r1=349206&r2=349207&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp (original)<br>
+++ llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp Fri Dec 14 14:44:46 2018<br>
@@ -568,25 +568,10 @@ void DwarfDebug::addGnuPubAttributes(Dwa<br>
U.addFlag(D, dwarf::DW_AT_GNU_pubnames);<br>
}<br>
<br>
-// Create new DwarfCompileUnit for the given metadata node with tag<br>
-// DW_TAG_compile_unit.<br>
-DwarfCompileUnit &<br>
-DwarfDebug::getOrCreateDwarfCompileUnit(const DICompileUnit *DIUnit) {<br>
- if (auto *CU = CUMap.lookup(DIUnit))<br>
- return *CU;<br>
- StringRef FN = DIUnit->getFilename();<br>
- CompilationDir = DIUnit->getDirectory();<br>
-<br>
- auto OwnedUnit = llvm::make_unique<DwarfCompileUnit>(<br>
- InfoHolder.getUnits().size(), DIUnit, Asm, this, &InfoHolder);<br>
- DwarfCompileUnit &NewCU = *OwnedUnit;<br>
+void DwarfDebug::finishUnitAttributes(const DICompileUnit *DIUnit,<br>
+ DwarfCompileUnit &NewCU) {<br>
DIE &Die = NewCU.getUnitDie();<br>
- InfoHolder.addUnit(std::move(OwnedUnit));<br>
- if (useSplitDwarf()) {<br>
- NewCU.setSkeleton(constructSkeletonCU(NewCU));<br>
- NewCU.addString(Die, dwarf::DW_AT_GNU_dwo_name,<br>
- Asm->TM.Options.MCOptions.SplitDwarfFile);<br>
- }<br>
+ StringRef FN = DIUnit->getFilename();<br>
<br>
for (auto *IE : DIUnit->getImportedEntities())<br>
NewCU.addImportedEntity(IE);<br>
@@ -640,11 +625,6 @@ DwarfDebug::getOrCreateDwarfCompileUnit(<br>
dwarf::DW_FORM_data1, RVer);<br>
}<br>
<br>
- if (useSplitDwarf())<br>
- NewCU.setSection(Asm->getObjFileLowering().getDwarfInfoDWOSection());<br>
- else<br>
- NewCU.setSection(Asm->getObjFileLowering().getDwarfInfoSection());<br>
-<br>
if (DIUnit->getDWOId()) {<br>
// This CU is either a clang module DWO or a skeleton CU.<br>
NewCU.addUInt(Die, dwarf::DW_AT_GNU_dwo_id, dwarf::DW_FORM_data8,<br>
@@ -654,9 +634,31 @@ DwarfDebug::getOrCreateDwarfCompileUnit(<br>
NewCU.addString(Die, dwarf::DW_AT_GNU_dwo_name,<br>
DIUnit->getSplitDebugFilename());<br>
}<br>
+}<br>
+// Create new DwarfCompileUnit for the given metadata node with tag<br>
+// DW_TAG_compile_unit.<br>
+DwarfCompileUnit &<br>
+DwarfDebug::getOrCreateDwarfCompileUnit(const DICompileUnit *DIUnit) {<br>
+ if (auto *CU = CUMap.lookup(DIUnit))<br>
+ return *CU;<br>
+<br>
+ CompilationDir = DIUnit->getDirectory();<br>
+<br>
+ auto OwnedUnit = llvm::make_unique<DwarfCompileUnit>(<br>
+ InfoHolder.getUnits().size(), DIUnit, Asm, this, &InfoHolder);<br>
+ DwarfCompileUnit &NewCU = *OwnedUnit;<br>
+ InfoHolder.addUnit(std::move(OwnedUnit));<br>
+<br>
+ if (useSplitDwarf()) {<br>
+ NewCU.setSkeleton(constructSkeletonCU(NewCU));<br>
+ NewCU.setSection(Asm->getObjFileLowering().getDwarfInfoDWOSection());<br>
+ } else {<br>
+ finishUnitAttributes(DIUnit, NewCU);<br>
+ NewCU.setSection(Asm->getObjFileLowering().getDwarfInfoSection());<br>
+ }<br>
<br>
CUMap.insert({DIUnit, &NewCU});<br>
- CUDieMap.insert({&Die, &NewCU});<br>
+ CUDieMap.insert({&NewCU.getUnitDie(), &NewCU});<br>
return NewCU;<br>
}<br>
<br>
@@ -851,7 +853,12 @@ void DwarfDebug::finalizeModuleInfo() {<br>
// If we're splitting the dwarf out now that we've got the entire<br>
// CU then add the dwo id to it.<br>
auto *SkCU = TheCU.getSkeleton();<br>
- if (useSplitDwarf()) {<br>
+ if (useSplitDwarf() && !empty(TheCU.getUnitDie().children())) {<br>
+ finishUnitAttributes(TheCU.getCUNode(), TheCU);<br>
+ TheCU.addString(TheCU.getUnitDie(), dwarf::DW_AT_GNU_dwo_name,<br>
+ Asm->TM.Options.MCOptions.SplitDwarfFile);<br>
+ SkCU->addString(SkCU->getUnitDie(), dwarf::DW_AT_GNU_dwo_name,<br>
+ Asm->TM.Options.MCOptions.SplitDwarfFile);<br>
// Emit a unique identifier for this CU.<br>
uint64_t ID =<br>
DIEHash(Asm).computeCUSignature(DWOName, TheCU.getUnitDie());<br>
@@ -870,6 +877,8 @@ void DwarfDebug::finalizeModuleInfo() {<br>
SkCU->addSectionLabel(SkCU->getUnitDie(), dwarf::DW_AT_GNU_ranges_base,<br>
Sym, Sym);<br>
}<br>
+ } else if (SkCU) {<br>
+ finishUnitAttributes(SkCU->getCUNode(), *SkCU);<br>
}<br>
<br>
// If we have code split among multiple sections or non-contiguous<br>
@@ -882,7 +891,9 @@ void DwarfDebug::finalizeModuleInfo() {<br>
<br>
// We don't keep track of which addresses are used in which CU so this<br>
// is a bit pessimistic under LTO.<br>
- if (!AddrPool.isEmpty())<br>
+ if (!AddrPool.isEmpty() &&<br>
+ (getDwarfVersion() >= 5 ||<br>
+ (SkCU && !empty(TheCU.getUnitDie().children()))))<br>
U.addAddrTableBase();<br>
<br>
if (unsigned NumRanges = TheCU.getRanges().size()) {<br>
@@ -2483,8 +2494,6 @@ void DwarfDebug::emitDebugMacinfo() {<br>
<br>
void DwarfDebug::initSkeletonUnit(const DwarfUnit &U, DIE &Die,<br>
std::unique_ptr<DwarfCompileUnit> NewU) {<br>
- NewU->addString(Die, dwarf::DW_AT_GNU_dwo_name,<br>
- Asm->TM.Options.MCOptions.SplitDwarfFile);<br>
<br>
if (!CompilationDir.empty())<br>
NewU->addString(Die, dwarf::DW_AT_comp_dir, CompilationDir);<br>
<br>
Modified: llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.h<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.h?rev=349207&r1=349206&r2=349207&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.h?rev=349207&r1=349206&r2=349207&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.h (original)<br>
+++ llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.h Fri Dec 14 14:44:46 2018<br>
@@ -540,6 +540,8 @@ class DwarfDebug : public DebugHandlerBa<br>
/// Create new DwarfCompileUnit for the given metadata node with tag<br>
/// DW_TAG_compile_unit.<br>
DwarfCompileUnit &getOrCreateDwarfCompileUnit(const DICompileUnit *DIUnit);<br>
+ void finishUnitAttributes(const DICompileUnit *DIUnit,<br>
+ DwarfCompileUnit &NewCU);<br>
<br>
/// Construct imported_module or imported_declaration DIE.<br>
void constructAndAddImportedEntityDIE(DwarfCompileUnit &TheCU,<br>
<br>
Modified: llvm/trunk/lib/CodeGen/AsmPrinter/DwarfFile.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfFile.cpp?rev=349207&r1=349206&r2=349207&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfFile.cpp?rev=349207&r1=349206&r2=349207&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/CodeGen/AsmPrinter/DwarfFile.cpp (original)<br>
+++ llvm/trunk/lib/CodeGen/AsmPrinter/DwarfFile.cpp Fri Dec 14 14:44:46 2018<br>
@@ -39,13 +39,14 @@ void DwarfFile::emitUnit(DwarfUnit *TheU<br>
if (TheU->getCUNode()->isDebugDirectivesOnly())<br>
return;<br>
<br>
- DIE &Die = TheU->getUnitDie();<br>
- MCSection *USection = TheU->getSection();<br>
- Asm->OutStreamer->SwitchSection(USection);<br>
+ MCSection *S = TheU->getSection();<br>
<br>
- TheU->emitHeader(UseOffsets);<br>
+ if (!S)<br>
+ return;<br>
<br>
- Asm->emitDwarfDIE(Die);<br>
+ Asm->OutStreamer->SwitchSection(S);<br>
+ TheU->emitHeader(UseOffsets);<br>
+ Asm->emitDwarfDIE(TheU->getUnitDie());<br>
}<br>
<br>
// Compute the size and offset for each DIE.<br>
<br>
Modified: llvm/trunk/test/DebugInfo/X86/fission-cu.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/DebugInfo/X86/fission-cu.ll?rev=349207&r1=349206&r2=349207&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/DebugInfo/X86/fission-cu.ll?rev=349207&r1=349206&r2=349207&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/DebugInfo/X86/fission-cu.ll (original)<br>
+++ llvm/trunk/test/DebugInfo/X86/fission-cu.ll Fri Dec 14 14:44:46 2018<br>
@@ -25,18 +25,18 @@ source_filename = "test/DebugInfo/X86/fi<br>
; CHECK: Abbrev table for offset: 0x00000000<br>
; CHECK: [1] DW_TAG_compile_unit DW_CHILDREN_no<br>
; CHECK: DW_AT_stmt_list DW_FORM_sec_offset<br>
-; CHECK: DW_AT_GNU_dwo_name DW_FORM_strp<br>
; CHECK: DW_AT_comp_dir DW_FORM_strp<br>
+; CHECK: DW_AT_GNU_dwo_name DW_FORM_strp<br>
; CHECK: DW_AT_GNU_dwo_id DW_FORM_data8<br>
<br>
; Check that we're using the right forms.<br>
; CHECK: .debug_abbrev.dwo contents:<br>
; CHECK: Abbrev table for offset: 0x00000000<br>
; CHECK: [1] DW_TAG_compile_unit DW_CHILDREN_yes<br>
-; CHECK: DW_AT_GNU_dwo_name DW_FORM_GNU_str_index<br>
; CHECK: DW_AT_producer DW_FORM_GNU_str_index<br>
; CHECK: DW_AT_language DW_FORM_data2<br>
; CHECK: DW_AT_name DW_FORM_GNU_str_index<br>
+; CHECK: DW_AT_GNU_dwo_name DW_FORM_GNU_str_index<br>
; CHECK-NOT: DW_AT_low_pc<br>
; CHECK-NOT: DW_AT_stmt_list<br>
; CHECK-NOT: DW_AT_comp_dir<br>
@@ -58,48 +58,48 @@ source_filename = "test/DebugInfo/X86/fi<br>
; CHECK: .debug_info contents:<br>
; CHECK: DW_TAG_compile_unit<br>
; CHECK-NEXT: DW_AT_stmt_list [DW_FORM_sec_offset] (0x00000000)<br>
-; CHECK-NEXT: DW_AT_GNU_dwo_name [DW_FORM_strp] ( .debug_str[0x00000000] = "baz.dwo")<br>
-; CHECK-NEXT: DW_AT_comp_dir [DW_FORM_strp] ( .debug_str[0x00000008] = "/usr/local/google/home/echristo/tmp")<br>
+; CHECK-NEXT: DW_AT_comp_dir [DW_FORM_strp] ( .debug_str[0x00000000] = "/usr/local/google/home/echristo/tmp")<br>
+; CHECK-NEXT: DW_AT_GNU_dwo_name [DW_FORM_strp] ( .debug_str[0x00000024] = "baz.dwo")<br>
; CHECK-NEXT: DW_AT_GNU_dwo_id [DW_FORM_data8] (0x1f1f859683d49324)<br>
<br>
; Check that the rest of the compile units have information.<br>
; CHECK: .debug_info.dwo contents:<br>
; CHECK: DW_TAG_compile_unit<br>
-; CHECK: DW_AT_GNU_dwo_name [DW_FORM_GNU_str_index] ( indexed (00000000) string = "baz.dwo")<br>
-; CHECK: DW_AT_producer [DW_FORM_GNU_str_index] ( indexed (00000001) string = "clang version 3.3 (trunk 169021) (llvm/trunk 169020)")<br>
+; CHECK: DW_AT_producer [DW_FORM_GNU_str_index] ( indexed (00000002) string = "clang version 3.3 (trunk 169021) (llvm/trunk 169020)")<br>
; CHECK: DW_AT_language [DW_FORM_data2] (DW_LANG_C99)<br>
-; CHECK: DW_AT_name [DW_FORM_GNU_str_index] ( indexed (00000002) string = "baz.c")<br>
+; CHECK: DW_AT_name [DW_FORM_GNU_str_index] ( indexed (00000003) string = "baz.c")<br>
+; CHECK: DW_AT_GNU_dwo_name [DW_FORM_GNU_str_index] ( indexed (00000004) string = "baz.dwo")<br>
; CHECK-NOT: DW_AT_low_pc<br>
; CHECK-NOT: DW_AT_stmt_list<br>
; CHECK-NOT: DW_AT_comp_dir<br>
; CHECK: DW_AT_GNU_dwo_id [DW_FORM_data8] (0x1f1f859683d49324)<br>
; CHECK: DW_TAG_variable<br>
-; CHECK: DW_AT_name [DW_FORM_GNU_str_index] ( indexed (00000003) string = "a")<br>
+; CHECK: DW_AT_name [DW_FORM_GNU_str_index] ( indexed (00000000) string = "a")<br>
; CHECK: DW_AT_type [DW_FORM_ref4] (cu + 0x{{[0-9a-f]*}} => {[[TYPE:0x[0-9a-f]*]]}<br>
; CHECK: DW_AT_external [DW_FORM_flag_present] (true)<br>
; CHECK: DW_AT_decl_file [DW_FORM_data1] (0x01)<br>
; CHECK: DW_AT_decl_line [DW_FORM_data1] (1)<br>
; CHECK: DW_AT_location [DW_FORM_exprloc] (DW_OP_GNU_addr_index 0x0)<br>
; CHECK: [[TYPE]]: DW_TAG_base_type<br>
-; CHECK: DW_AT_name [DW_FORM_GNU_str_index] ( indexed (00000004) string = "int")<br>
+; CHECK: DW_AT_name [DW_FORM_GNU_str_index] ( indexed (00000001) string = "int")<br>
<br>
; CHECK: .debug_str contents:<br>
-; CHECK: 0x00000000: "baz.dwo"<br>
-; CHECK: 0x00000008: "/usr/local/google/home/echristo/tmp"<br>
+; CHECK: 0x00000000: "/usr/local/google/home/echristo/tmp"<br>
+; CHECK: 0x00000024: "baz.dwo"<br>
<br>
; CHECK: .debug_str.dwo contents:<br>
-; CHECK: 0x00000000: "baz.dwo"<br>
-; CHECK: 0x00000008: "clang version 3.3 (trunk 169021) (llvm/trunk 169020)"<br>
-; CHECK: 0x0000003d: "baz.c"<br>
-; CHECK: 0x00000043: "a"<br>
-; CHECK: 0x00000045: "int"<br>
+; CHECK: 0x00000000: "a"<br>
+; CHECK: 0x00000002: "int"<br>
+; CHECK: 0x00000006: "clang version 3.3 (trunk 169021) (llvm/trunk 169020)"<br>
+; CHECK: 0x0000003b: "baz.c"<br>
+; CHECK: 0x00000041: "baz.dwo"<br>
<br>
; CHECK: .debug_str_offsets.dwo contents:<br>
; CHECK: 0x00000000: 00000000<br>
-; CHECK: 0x00000004: 00000008<br>
-; CHECK: 0x00000008: 0000003d<br>
-; CHECK: 0x0000000c: 00000043<br>
-; CHECK: 0x00000010: 00000045<br>
+; CHECK: 0x00000004: 00000002<br>
+; CHECK: 0x00000008: 00000006<br>
+; CHECK: 0x0000000c: 0000003b<br>
+; CHECK: 0x00000010: 00000041<br>
<br>
; Object file checks<br>
; For x86-64-linux we should have this set of relocations for the debug info section<br>
<br>
Modified: llvm/trunk/test/DebugInfo/X86/fission-ranges.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/DebugInfo/X86/fission-ranges.ll?rev=349207&r1=349206&r2=349207&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/DebugInfo/X86/fission-ranges.ll?rev=349207&r1=349206&r2=349207&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/DebugInfo/X86/fission-ranges.ll (original)<br>
+++ llvm/trunk/test/DebugInfo/X86/fission-ranges.ll Fri Dec 14 14:44:46 2018<br>
@@ -8,8 +8,8 @@<br>
; CHECK: .debug_info contents:<br>
; CHECK: DW_TAG_compile_unit<br>
; CHECK-NEXT: DW_AT_stmt_list<br>
-; CHECK-NEXT: DW_AT_GNU_dwo_name<br>
; CHECK-NEXT: DW_AT_comp_dir<br>
+; CHECK-NEXT: DW_AT_GNU_dwo_name<br>
; CHECK-NEXT: DW_AT_GNU_dwo_id<br>
; CHECK-NEXT: DW_AT_GNU_ranges_base<br>
; CHECK-NEXT: DW_AT_GNU_addr_base [DW_FORM_sec_offset] (0x00000000)<br>
<br>
Modified: llvm/trunk/test/DebugInfo/X86/string-offsets-table-order.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/DebugInfo/X86/string-offsets-table-order.ll?rev=349207&r1=349206&r2=349207&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/DebugInfo/X86/string-offsets-table-order.ll?rev=349207&r1=349206&r2=349207&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/DebugInfo/X86/string-offsets-table-order.ll (original)<br>
+++ llvm/trunk/test/DebugInfo/X86/string-offsets-table-order.ll Fri Dec 14 14:44:46 2018<br>
@@ -13,11 +13,11 @@<br>
<br>
; CHECK: .debug_info contents:<br>
; CHECK: DW_TAG_compile_unit<br>
-; CHECK: DW_AT_comp_dir [DW_FORM_strx1] ( indexed (00000001) string = "X3")<br>
+; CHECK: DW_AT_comp_dir [DW_FORM_strx1] ( indexed (00000000) string = "X3")<br>
; CHECK: DW_TAG_compile_unit<br>
-; CHECK: DW_AT_comp_dir [DW_FORM_strx1] ( indexed (00000002) string = "X2")<br>
+; CHECK: DW_AT_comp_dir [DW_FORM_strx1] ( indexed (00000001) string = "X2")<br>
; CHECK: DW_TAG_compile_unit<br>
-; CHECK: DW_AT_comp_dir [DW_FORM_strx1] ( indexed (00000003) string = "X1")<br>
+; CHECK: DW_AT_comp_dir [DW_FORM_strx1] ( indexed (00000002) string = "X1")<br>
; CHECK: .debug_info.dwo contents:<br>
<br>
; CHECK: .debug_str contents:<br>
@@ -27,10 +27,10 @@<br>
<br>
; CHECK: .debug_str_offsets contents:<br>
; CHECK: Format = DWARF32, Version = 5<br>
-; CHECK-NEXT: 00000000 "foo.dwo"<br>
; CHECK-NEXT: [[X3]] "X3"<br>
; CHECK-NEXT: [[X2]] "X2"<br>
; CHECK-NEXT: [[X1]] "X1"<br>
+; CHECK-NEXT: "foo.dwo"<br>
; CHECK-EMPTY:<br>
<br>
<br>
<br>
Modified: llvm/trunk/test/DebugInfo/X86/string-offsets-table.ll<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/test/DebugInfo/X86/string-offsets-table.ll?rev=349207&r1=349206&r2=349207&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/test/DebugInfo/X86/string-offsets-table.ll?rev=349207&r1=349206&r2=349207&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/test/DebugInfo/X86/string-offsets-table.ll (original)<br>
+++ llvm/trunk/test/DebugInfo/X86/string-offsets-table.ll Fri Dec 14 14:44:46 2018<br>
@@ -59,8 +59,8 @@<br>
; SPLIT: DW_TAG_compile_unit<br>
; SPLIT-NOT: {{DW_TAG|contents:}}<br>
; SPLIT: DW_AT_str_offsets_base [DW_FORM_sec_offset] (0x00000008)<br>
-; SPLIT: DW_AT_GNU_dwo_name [DW_FORM_strx1] ( indexed (00000000) string = "foo.dwo")<br>
-; SPLIT: DW_AT_comp_dir [DW_FORM_strx1] ( indexed (00000001) string = "/home/test")<br>
+; SPLIT: DW_AT_comp_dir [DW_FORM_strx1] ( indexed (00000000) string = "/home/test")<br>
+; SPLIT: DW_AT_GNU_dwo_name [DW_FORM_strx1] ( indexed (00000001) string = "foo.dwo")<br>
<br>
; Check for the split CU in .debug_info.dwo.<br>
; SPLIT: .debug_info.dwo contents:<br>
@@ -73,18 +73,18 @@<br>
; SPLIT-NOT: contents:<br>
; SPLIT: DW_TAG_enumerator<br>
; SPLIT-NOT: {{DW_TAG|NULL}}<br>
-; SPLIT: DW_AT_name [DW_FORM_strx1] ( indexed (00000004) string = "a")<br>
+; SPLIT: DW_AT_name [DW_FORM_strx1] ( indexed (00000001) string = "a")<br>
; SPLIT-NOT: contents:<br>
; SPLIT: DW_TAG_enumerator<br>
; SPLIT-NOT: {{DW_TAG|NULL}}<br>
-; SPLIT: DW_AT_name [DW_FORM_strx1] ( indexed (00000005) string = "b")<br>
+; SPLIT: DW_AT_name [DW_FORM_strx1] ( indexed (00000002) string = "b")<br>
;<br>
; Extract the string offsets referenced in the main file by the skeleton unit.<br>
; SPLIT: .debug_str contents:<br>
-; SPLIT-NEXT: 0x00000000: "foo.dwo"<br>
-; SPLIT-NEXT: 0x[[STRING2SPLIT:[0-9a-f]*]]: "/home/test"<br>
-; SPLIT-NEXT: 0x[[STRING3SPLIT:[0-9a-f]*]]: "E"<br>
-; SPLIT-NEXT: 0x[[STRING4SPLIT:[0-9a-f]*]]: "glob"<br>
+; SPLIT-NEXT: 0x[[STRHOMETESTSPLIT:[0-9a-f]*]]: "/home/test"<br>
+; SPLIT-NEXT: 0x[[STRESPLIT:[0-9a-f]*]]: "E"<br>
+; SPLIT-NEXT: 0x[[STRGLOBSPLIT:[0-9a-f]*]]: "glob"<br>
+; SPLIT-NEXT: 0x[[STRFOODWOSPLIT:[0-9a-f]*]]: "foo.dwo"<br>
;<br>
; Extract the string offsets referenced in the .dwo file by the split unit.<br>
; SPLIT: .debug_str.dwo contents:<br>
@@ -98,8 +98,8 @@<br>
; referenced by the debug info.<br>
; SPLIT: .debug_str_offsets contents:<br>
; SPLIT-NEXT: 0x00000000: Contribution size = 12, Format = DWARF32, Version = 5<br>
-; SPLIT-NEXT: 0x00000008: 00000000 "foo.dwo"<br>
-; SPLIT-NEXT: 0x0000000c: [[STRING2SPLIT]] "/home/test"<br>
+; SPLIT-NEXT: 0x00000008: [[STRHOMETESTSPLIT]] "/home/test"<br>
+; SPLIT-NEXT: 0x0000000c: [[STRFOODWOSPLIT]] "foo.dwo"<br>
; SPLIT-EMPTY:<br>
<br>
; SPLIT: .debug_str_offsets.dwo contents:<br>
<br>
<br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits</a><br>
</blockquote></div>
</blockquote></div>
</blockquote></div></div>