Author: dgregor
Date: Fri Mar 22 16:26:48 2013
New Revision: 177766

URL: http://llvm.org/viewvc/llvm-project?rev=177766&view=rev
Log:
<rdar://problem/13479539> Only rebuild the global module cache when we're 
allowed to.

This eliminates excessive rebuilds of the global module cache.

Modified:
    cfe/trunk/lib/Frontend/CompilerInstance.cpp

Modified: cfe/trunk/lib/Frontend/CompilerInstance.cpp
URL: 
http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/CompilerInstance.cpp?rev=177766&r1=177765&r2=177766&view=diff
==============================================================================
--- cfe/trunk/lib/Frontend/CompilerInstance.cpp (original)
+++ cfe/trunk/lib/Frontend/CompilerInstance.cpp Fri Mar 22 16:26:48 2013
@@ -62,7 +62,8 @@ void CompilerInstance::setInvocation(Com
 
 bool CompilerInstance::shouldBuildGlobalModuleIndex() const {
   return (BuildGlobalModuleIndex ||
-          (ModuleManager && ModuleManager->isGlobalIndexUnavailable())) &&
+          (ModuleManager && ModuleManager->isGlobalIndexUnavailable() &&
+           getFrontendOpts().GenerateGlobalModuleIndex)) &&
          !ModuleBuildFailed;
 }
 


_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to