efriedma added a comment. I think there's something weird happening with your timers if they're showing half a second spent parsing or instantiating std::declval: it doesn't have a definition, anywhere (it's just a placeholder for template metaprogramming tricks).
================ Comment at: lib/AST/Expr.cpp:544 + FrontendTimesIsEnabled, + getFrontendFunctionTimeCtx<const FunctionDecl *>(), {FD, 0}); if (IT != PrettyFunction && IT != PrettyFunctionNoVirtual && ---------------- You shouldn't need a separate timer here; `__func__` should only show up inside a function definition anyway. ================ Comment at: lib/Analysis/AnalysisDeclContext.cpp:99 + FrontendTimesIsEnabled, + getFrontendFunctionTimeCtx<const FunctionDecl *>(), {FD, 0}); Stmt *Body = FD->getBody(); ---------------- Not sure what you're trying to time here. ================ Comment at: lib/Parse/Parser.cpp:1131 Actions.CheckForFunctionRedefinition(FnD); Actions.MarkAsLateParsedTemplate(FnD, DP, Toks); } ---------------- CheckForFunctionRedefinition and MarkAsLateParsedTemplate are both pretty cheap; not sure it's worth separately timing them. ================ Comment at: lib/Sema/SemaDecl.cpp:2996 /// Returns true if there was an error, false otherwise. bool Sema::MergeFunctionDecl(FunctionDecl *New, NamedDecl *&OldD, Scope *S, bool MergeTypeWithOld) { ---------------- MergeFunctionDecl only has one caller: CheckFunctionDeclaration. Probably makes more sense to time that, instead? ================ Comment at: lib/Sema/SemaDecl.cpp:3595 bool Sema::MergeCompatibleFunctionDecls(FunctionDecl *New, FunctionDecl *Old, Scope *S, bool MergeTypeWithOld) { + FrontendTimeRAII<const FunctionDecl *> FTRAII( ---------------- MergeCompatibleFunctionDecls is only called by MergeFunctionDecl. https://reviews.llvm.org/D47196 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits