aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/AST/StmtProfile.cpp
diff options
context:
space:
mode:
authorNAKAMURA Takumi <geek4civic@gmail.com>2025-01-10 19:22:46 +0900
committerNAKAMURA Takumi <geek4civic@gmail.com>2025-01-10 19:22:46 +0900
commit8b02a27fc607ebc54c5a811188b3cea5063564e7 (patch)
treec1ca7d4acca553301204ebb83383aa87cb59311a /clang/lib/AST/StmtProfile.cpp
parent694a772457b2999b7bd68625a16bf0755e95dcdb (diff)
parent397ac44f623f891d8f05d6673a95984ac0a26671 (diff)
downloadllvm-users/chapuni/cov/merge/mcdcsort.zip
llvm-users/chapuni/cov/merge/mcdcsort.tar.gz
llvm-users/chapuni/cov/merge/mcdcsort.tar.bz2
Merge branch 'main' into users/chapuni/cov/merge/mcdcsortusers/chapuni/cov/merge/mcdcsort
Diffstat (limited to 'clang/lib/AST/StmtProfile.cpp')
-rw-r--r--clang/lib/AST/StmtProfile.cpp16
1 files changed, 14 insertions, 2 deletions
diff --git a/clang/lib/AST/StmtProfile.cpp b/clang/lib/AST/StmtProfile.cpp
index 150b92ef..cd91a79 100644
--- a/clang/lib/AST/StmtProfile.cpp
+++ b/clang/lib/AST/StmtProfile.cpp
@@ -2555,8 +2555,13 @@ void OpenACCClauseProfiler::VisitCreateClause(
}
void OpenACCClauseProfiler::VisitSelfClause(const OpenACCSelfClause &Clause) {
- if (Clause.hasConditionExpr())
- Profiler.VisitStmt(Clause.getConditionExpr());
+ if (Clause.isConditionExprClause()) {
+ if (Clause.hasConditionExpr())
+ Profiler.VisitStmt(Clause.getConditionExpr());
+ } else {
+ for (auto *E : Clause.getVarList())
+ Profiler.VisitStmt(E);
+ }
}
void OpenACCClauseProfiler::VisitFinalizeClause(
@@ -2780,6 +2785,13 @@ void StmtProfiler::VisitOpenACCSetConstruct(const OpenACCSetConstruct *S) {
P.VisitOpenACCClauseList(S->clauses());
}
+void StmtProfiler::VisitOpenACCUpdateConstruct(
+ const OpenACCUpdateConstruct *S) {
+ VisitStmt(S);
+ OpenACCClauseProfiler P{*this};
+ P.VisitOpenACCClauseList(S->clauses());
+}
+
void StmtProfiler::VisitHLSLOutArgExpr(const HLSLOutArgExpr *S) {
VisitStmt(S);
}