From 4333daab1c69b6e2e789df68375007a69f3bb9da Mon Sep 17 00:00:00 2001 From: Adrian McCarthy Date: Wed, 2 Nov 2016 21:30:35 +0000 Subject: Emit S_COMPILE3 record once per TU rather than once per function This has some ripple effects in several tests. llvm-svn: 285862 --- llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp') diff --git a/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp b/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp index fc691456a48..aa7a301687f 100644 --- a/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/CodeViewDebug.cpp @@ -391,6 +391,11 @@ void CodeViewDebug::endModule() { // Use the generic .debug$S section, and make a subsection for all the inlined // subprograms. switchToDebugSectionForSymbol(nullptr); + + MCSymbol *CompilerInfo = beginCVSubsection(ModuleSubstreamKind::Symbols); + emitCompilerInformation(); + endCVSubsection(CompilerInfo); + emitInlineeLinesSubsection(); // Emit per-function debug information. @@ -2131,8 +2136,6 @@ MCSymbol *CodeViewDebug::beginCVSubsection(ModuleSubstreamKind Kind) { OS.AddComment("Subsection size"); OS.emitAbsoluteSymbolDiff(EndLabel, BeginLabel, 4); OS.EmitLabel(BeginLabel); - if (Kind == ModuleSubstreamKind::Symbols) - emitCompilerInformation(); return EndLabel; } -- cgit v1.2.3