diff options
author | Lang Hames <lhames@gmail.com> | 2012-12-10 22:49:11 +0000 |
---|---|---|
committer | Lang Hames <lhames@gmail.com> | 2012-12-10 22:49:11 +0000 |
commit | 07f6a4fde0a1b081fbefd986345c9b2f4f85e88a (patch) | |
tree | e55ccef79ff78d44d9c3e1595d718842a15e869e /lib/CodeGen/AsmPrinter/AsmPrinter.cpp | |
parent | 079e0819bc4a0dde6ce427757130db85216167de (diff) |
Defer call to InitSections until after MCContext has been initialized. If
InitSections is called before the MCContext is initialized it could cause
duplicate temporary symbols to be emitted later (after context initialization
resets the temporary label counter).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169785 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/AsmPrinter/AsmPrinter.cpp')
-rw-r--r-- | lib/CodeGen/AsmPrinter/AsmPrinter.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/CodeGen/AsmPrinter/AsmPrinter.cpp b/lib/CodeGen/AsmPrinter/AsmPrinter.cpp index 39a5a9d42d..68ed280c55 100644 --- a/lib/CodeGen/AsmPrinter/AsmPrinter.cpp +++ b/lib/CodeGen/AsmPrinter/AsmPrinter.cpp @@ -149,6 +149,8 @@ void AsmPrinter::getAnalysisUsage(AnalysisUsage &AU) const { } bool AsmPrinter::doInitialization(Module &M) { + OutStreamer.InitStreamer(); + MMI = getAnalysisIfAvailable<MachineModuleInfo>(); MMI->AnalyzeModule(M); |