[clang-tools-extra] [clang-doc] add ftime profiling (PR #97644)
via cfe-commits
cfe-commits at lists.llvm.org
Fri Jul 12 04:08:39 PDT 2024
================
@@ -13,12 +13,17 @@
#include "clang/Index/USRGeneration.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/Support/Error.h"
+#include "llvm/Support/TimeProfiler.h"
namespace clang {
namespace doc {
void MapASTVisitor::HandleTranslationUnit(ASTContext &Context) {
+ if (CDCtx.FTimeTrace)
+ llvm::timeTraceProfilerInitialize(CDCtx.Granularity, "clang-doc");
----------------
PeterChou1 wrote:
I thought it would be more clear since we also use llvm::timeTraceProfilerFinishThread in the method
https://github.com/llvm/llvm-project/pull/97644
More information about the cfe-commits
mailing list