diff options
author | Easwaran Raman <eraman@google.com> | 2018-01-25 19:27:17 +0000 |
---|---|---|
committer | Easwaran Raman <eraman@google.com> | 2018-01-25 19:27:17 +0000 |
commit | c73cec84c99e5a63dca961fef67998a677c53a3c (patch) | |
tree | 704fa86d10c8220cb72ecd5c867b540340ea70d8 /llvm/lib/Transforms | |
parent | 7e9453d5837f70284244dca2143fa5d8e491f955 (diff) | |
download | bcm5719-llvm-c73cec84c99e5a63dca961fef67998a677c53a3c.tar.gz bcm5719-llvm-c73cec84c99e5a63dca961fef67998a677c53a3c.zip |
Re-land "[ThinLTO] Add call edges' relative block frequency to per-module summary."
It was reverted after buildbot regressions.
Original commit message:
This allows relative block frequency of call edges to be passed
to the thinlink stage where it will be used to compute synthetic
entry counts of functions.
llvm-svn: 323460
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r-- | llvm/lib/Transforms/IPO/FunctionImport.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/IPO/FunctionImport.cpp b/llvm/lib/Transforms/IPO/FunctionImport.cpp index b1eefb96454..ed85c20051e 100644 --- a/llvm/lib/Transforms/IPO/FunctionImport.cpp +++ b/llvm/lib/Transforms/IPO/FunctionImport.cpp @@ -269,7 +269,7 @@ static void computeImportForFunction( }; const auto NewThreshold = - Threshold * GetBonusMultiplier(Edge.second.Hotness); + Threshold * GetBonusMultiplier(Edge.second.getHotness()); auto *CalleeSummary = selectCallee(Index, VI.getSummaryList(), NewThreshold, Summary.modulePath()); @@ -293,7 +293,8 @@ static void computeImportForFunction( return Threshold * ImportInstrFactor; }; - bool IsHotCallsite = Edge.second.Hotness == CalleeInfo::HotnessType::Hot; + bool IsHotCallsite = + Edge.second.getHotness() == CalleeInfo::HotnessType::Hot; const auto AdjThreshold = GetAdjustedThreshold(Threshold, IsHotCallsite); auto ExportModulePath = ResolvedCalleeSummary->modulePath(); |