summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTeresa Johnson <tejohnson@google.com>2016-03-25 18:59:13 +0000
committerTeresa Johnson <tejohnson@google.com>2016-03-25 18:59:13 +0000
commitaae261004265189ef9b3f48172d3381e18b9488f (patch)
tree6e7a64d1b411f45cd9d0145292a9438d31ee0560
parent1c4005264685fce12cf2044bb74f09ff774866f1 (diff)
downloadbcm5719-llvm-aae261004265189ef9b3f48172d3381e18b9488f.tar.gz
bcm5719-llvm-aae261004265189ef9b3f48172d3381e18b9488f.zip
[ThinLTO] Rename edges() to calls() for clarity (NFC)
Helps distinguish from refs() which iterates over non-call references. llvm-svn: 264445
-rw-r--r--llvm/include/llvm/IR/ModuleSummaryIndex.h4
-rw-r--r--llvm/lib/Bitcode/Writer/BitcodeWriter.cpp6
2 files changed, 5 insertions, 5 deletions
diff --git a/llvm/include/llvm/IR/ModuleSummaryIndex.h b/llvm/include/llvm/IR/ModuleSummaryIndex.h
index d84eb240152..1dd1e1450eb 100644
--- a/llvm/include/llvm/IR/ModuleSummaryIndex.h
+++ b/llvm/include/llvm/IR/ModuleSummaryIndex.h
@@ -162,8 +162,8 @@ public:
}
/// Return the list of <CalleeGUID, ProfileCount> pairs.
- std::vector<EdgeTy> &edges() { return CallGraphEdgeList; }
- const std::vector<EdgeTy> &edges() const { return CallGraphEdgeList; }
+ std::vector<EdgeTy> &calls() { return CallGraphEdgeList; }
+ const std::vector<EdgeTy> &calls() const { return CallGraphEdgeList; }
};
/// \brief Global variable summary information to aid decisions and
diff --git a/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp b/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
index 5d051649699..1d6054da79e 100644
--- a/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
+++ b/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
@@ -2863,7 +2863,7 @@ static void WritePerModuleFunctionSummaryRecord(
NameVals.push_back(RI);
bool HasProfileData = F.getEntryCount().hasValue();
- for (auto &ECI : FS->edges()) {
+ for (auto &ECI : FS->calls()) {
NameVals.push_back(ECI.first);
assert(ECI.second.CallsiteCount > 0 && "Expected at least one callsite");
NameVals.push_back(ECI.second.CallsiteCount);
@@ -3089,13 +3089,13 @@ static void WriteCombinedGlobalValueSummary(
}
bool HasProfileData = false;
- for (auto &EI : FS->edges()) {
+ for (auto &EI : FS->calls()) {
HasProfileData |= EI.second.ProfileCount != 0;
if (HasProfileData)
break;
}
- for (auto &EI : FS->edges()) {
+ for (auto &EI : FS->calls()) {
const auto &VMI = GUIDToValueIdMap.find(EI.first);
// If this GUID doesn't have an entry, it doesn't have a function
// summary and we don't need to record any calls to it.
OpenPOWER on IntegriCloud