diff options
| author | Teresa Johnson <tejohnson@google.com> | 2016-03-15 00:04:37 +0000 |
|---|---|---|
| committer | Teresa Johnson <tejohnson@google.com> | 2016-03-15 00:04:37 +0000 |
| commit | 26ab5772b058fcddabfecb6736a3b78c67bc1751 (patch) | |
| tree | 89b82d60f6e4ef3d7970cf1dc620c4f3a78bad2e /llvm/lib/Transforms/Utils | |
| parent | da8b3f1914e0cc4eb25af376583a23e660718115 (diff) | |
| download | bcm5719-llvm-26ab5772b058fcddabfecb6736a3b78c67bc1751.tar.gz bcm5719-llvm-26ab5772b058fcddabfecb6736a3b78c67bc1751.zip | |
[ThinLTO] Renaming of function index to module summary index (NFC)
(Resubmitting after fixing missing file issue)
With the changes in r263275, there are now more than just functions in
the summary. Completed the renaming of data structures (started in
r263275) to reflect the wider scope. In particular, changed the
FunctionIndex* data structures to ModuleIndex*, and renamed related
variables and comments. Also renamed the files to reflect the changes.
A companion clang patch will immediately succeed this patch to reflect
this renaming.
llvm-svn: 263513
Diffstat (limited to 'llvm/lib/Transforms/Utils')
| -rw-r--r-- | llvm/lib/Transforms/Utils/FunctionImportUtils.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Transforms/Utils/FunctionImportUtils.cpp b/llvm/lib/Transforms/Utils/FunctionImportUtils.cpp index 73069b2c742..eceb0850941 100644 --- a/llvm/lib/Transforms/Utils/FunctionImportUtils.cpp +++ b/llvm/lib/Transforms/Utils/FunctionImportUtils.cpp @@ -68,7 +68,7 @@ bool FunctionImportGlobalProcessing::doPromoteLocalToGlobal( // For now we are conservative in determining which variables are not // address taken by checking the unnamed addr flag. To be more aggressive, // the address taken information must be checked earlier during parsing - // of the module and recorded in the function index for use when importing + // of the module and recorded in the summary index for use when importing // from that module. auto *GVar = dyn_cast<GlobalVariable>(SGV); if (GVar && GVar->isConstant() && GVar->hasUnnamedAddr()) @@ -76,7 +76,7 @@ bool FunctionImportGlobalProcessing::doPromoteLocalToGlobal( // Eventually we only need to promote functions in the exporting module that // are referenced by a potentially exported function (i.e. one that is in the - // function index). + // summary index). return true; } @@ -88,7 +88,7 @@ std::string FunctionImportGlobalProcessing::getName(const GlobalValue *SGV) { // avoid naming conflicts between locals imported from different modules. if (SGV->hasLocalLinkage() && (doPromoteLocalToGlobal(SGV) || isPerformingImport())) - return FunctionInfoIndex::getGlobalNameForLocal( + return ModuleSummaryIndex::getGlobalNameForLocal( SGV->getName(), ImportIndex.getModuleId(SGV->getParent()->getModuleIdentifier())); return SGV->getName(); @@ -231,7 +231,7 @@ bool FunctionImportGlobalProcessing::run() { return false; } -bool llvm::renameModuleForThinLTO(Module &M, const FunctionInfoIndex &Index) { +bool llvm::renameModuleForThinLTO(Module &M, const ModuleSummaryIndex &Index) { FunctionImportGlobalProcessing ThinLTOProcessing(M, Index); return ThinLTOProcessing.run(); } |

