change this back too
authorChris Lattner <sabre@nondot.org>
Sun, 4 Apr 2010 05:09:10 +0000 (05:09 +0000)
committerChris Lattner <sabre@nondot.org>
Sun, 4 Apr 2010 05:09:10 +0000 (05:09 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100310 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/AsmPrinter/AsmPrinter.cpp

index 096bf9183765c6e6d1acd91c26fba277cabcca95..92946470e368ef5eb7f0f3f8287ba26fb4950d7e 100644 (file)
@@ -101,7 +101,7 @@ void AsmPrinter::getAnalysisUsage(AnalysisUsage &AU) const {
 }
 
 bool AsmPrinter::doInitialization(Module &M) {
-  MMI = &getAnalysis<MachineModuleInfo>();
+  MMI = getAnalysisIfAvailable<MachineModuleInfo>();
   MMI->AnalyzeModule(M);
 
   // Initialize TargetLoweringObjectFile.