Skip to content

Commit 01b3965

Browse files
committed
Sema: Add a timer for preCheckExpression()
1 parent 0b0025d commit 01b3965

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lib/Sema/PreCheckExpr.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1926,6 +1926,9 @@ Expr *PreCheckExpression::simplifyTypeConstructionWithLiteralArg(Expr *E) {
19261926
/// expression and folding sequence expressions.
19271927
bool ConstraintSystem::preCheckExpression(Expr *&expr, DeclContext *dc,
19281928
bool replaceInvalidRefsWithErrors) {
1929+
auto &ctx = dc->getASTContext();
1930+
FrontendStatsTracer StatsTracer(ctx.Stats, "precheck-expr", expr);
1931+
19291932
PreCheckExpression preCheck(dc, expr, replaceInvalidRefsWithErrors);
19301933
// Perform the pre-check.
19311934
if (auto result = expr->walk(preCheck)) {

0 commit comments

Comments
 (0)