diff options
Diffstat (limited to 'llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp')
| -rw-r--r-- | llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp b/llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp index 9b7eb1e4bf5..ccfdf1a7657 100644 --- a/llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp +++ b/llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp @@ -693,6 +693,7 @@ void PGOUseFunc::populateCounters() { DEBUG(dbgs() << "Populate counts in " << NumPasses << " passes.\n"); // Assert every BB has a valid counter. uint64_t FuncEntryCount = getBBInfo(&*F.begin()).CountValue; + F.setEntryCount(FuncEntryCount); uint64_t FuncMaxCount = FuncEntryCount; for (auto &BB : F) { assert(getBBInfo(&BB).CountValid && "BB count is not valid"); |

