1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 20:12:56 +02:00

SamplePGO - Clear coverage tracking when clearing per-function data.

llvm-svn: 253877
This commit is contained in:
Diego Novillo 2015-11-23 16:30:17 +00:00
parent facc01c1fa
commit e85b89498c

View File

@ -188,6 +188,7 @@ public:
unsigned computeCoverage(unsigned Used, unsigned Total) const;
unsigned countUsedSamples(const FunctionSamples *Samples) const;
unsigned countBodySamples(const FunctionSamples *Samples) const;
void clear() { SampleCoverage.clear(); }
private:
typedef DenseMap<LineLocation, unsigned> BodySampleCoverageMap;
@ -285,6 +286,7 @@ void SampleProfileLoader::clearFunctionData() {
LI = nullptr;
Predecessors.clear();
Successors.clear();
CoverageTracker.clear();
}
/// \brief Returns the offset of lineno \p L to head_lineno \p H