From 2a6afe5f87a08e1df0bed97edf8c4ab497dd9bff Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Mon, 14 May 2018 14:13:20 +0000 Subject: [CodeGen/AccelTable]: Handle -dwarf-linkage-names=Abstract correctly Summary: If we are not emitting a linkage name in the .debug_info sections, we should not add it into the index either. This makes sure our index is consistent with the actual debug info. I am also explicitly setting the --dwarf-linkage-names=All in the name-collsions test as that one would now fail on targets where this defaults to "Abstract" (in fact, it would have failed already if there wasn't a bug in the DWARF verifier, which I fix as well). Reviewers: probinson, aprantl, JDevlieghere Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D46748 llvm-svn: 332246 --- llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp') diff --git a/llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp b/llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp index ba7aef37eac..b3b8d7d9146 100644 --- a/llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp +++ b/llvm/lib/DebugInfo/DWARF/DWARFVerifier.cpp @@ -1122,6 +1122,7 @@ DWARFVerifier::verifyNameIndexEntries(const DWARFDebugNames::NameIndex &NI, "of DIE @ {2:x}: index - {3}; debug_info - {4}.\n", NI.getUnitOffset(), EntryID, DIEOffset, Str, make_range(EntryNames.begin(), EntryNames.end())); + ++NumErrors; } } handleAllErrors(EntryOr.takeError(), -- cgit v1.2.3