diff options
Diffstat (limited to 'clang/lib/CodeGen/CodeGenPGO.cpp')
| -rw-r--r-- | clang/lib/CodeGen/CodeGenPGO.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenPGO.cpp b/clang/lib/CodeGen/CodeGenPGO.cpp index 052d58a04a14..08ae87785065 100644 --- a/clang/lib/CodeGen/CodeGenPGO.cpp +++ b/clang/lib/CodeGen/CodeGenPGO.cpp @@ -811,6 +811,9 @@ void CodeGenPGO::assignRegionCounters(GlobalDecl GD, llvm::Function *Fn) { if (isa<CXXDestructorDecl>(D) && GD.getDtorType() != Dtor_Base) return; + if (Fn->hasFnAttribute(llvm::Attribute::NoProfile)) + return; + CGM.ClearUnusedCoverageMapping(D); setFuncName(Fn); |
