diff options
-rw-r--r-- | llvm/include/llvm/ProfileData/InstrProf.h | 6 | ||||
-rw-r--r-- | llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp | 2 |
2 files changed, 5 insertions, 3 deletions
diff --git a/llvm/include/llvm/ProfileData/InstrProf.h b/llvm/include/llvm/ProfileData/InstrProf.h index 6a1ff499d24..ea11885c073 100644 --- a/llvm/include/llvm/ProfileData/InstrProf.h +++ b/llvm/include/llvm/ProfileData/InstrProf.h @@ -91,10 +91,12 @@ inline StringRef getCoverageMappingVarName() { } /// Return the name of the internal variable recording the array -/// of PGO name vars referenced by the coverage mapping, The owning +/// of PGO name vars referenced by the coverage mapping. The owning /// functions of those names are not emitted by FE (e.g, unused inline /// functions.) -inline StringRef getCoverageNamesVarName() { return "__llvm_coverage_names"; } +inline StringRef getCoverageUnusedNamesVarName() { + return "__llvm_coverage_names"; +} /// Return the name of function that registers all the per-function control /// data at program startup time by calling __llvm_register_function. This diff --git a/llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp b/llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp index 80418163f4a..40413add6ea 100644 --- a/llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp +++ b/llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp @@ -166,7 +166,7 @@ bool InstrProfiling::runOnModule(Module &M) { } if (GlobalVariable *CoverageNamesVar = - M.getNamedGlobal(getCoverageNamesVarName())) { + M.getNamedGlobal(getCoverageUnusedNamesVarName())) { lowerCoverageData(CoverageNamesVar); MadeChange = true; } |