diff --git a/flang/include/flang/Parser/dump-parse-tree.h b/flang/include/flang/Parser/dump-parse-tree.h --- a/flang/include/flang/Parser/dump-parse-tree.h +++ b/flang/include/flang/Parser/dump-parse-tree.h @@ -504,7 +504,6 @@ "llvm::omp::Clause = ", llvm::omp::getOpenMPClauseName(x)) .str(); } - NODE(parser, OmpNowait) NODE(parser, OmpObject) NODE(parser, OmpObjectList) NODE(parser, OmpProcBindClause) diff --git a/flang/include/flang/Parser/parse-tree.h b/flang/include/flang/Parser/parse-tree.h --- a/flang/include/flang/Parser/parse-tree.h +++ b/flang/include/flang/Parser/parse-tree.h @@ -3456,9 +3456,6 @@ std::variant u; }; -// 2.7.1 nowait-clause -> NOWAIT -EMPTY_CLASS(OmpNowait); - // dist_schedule clause does not fit in generic clause class for tablegen. // Therefore it is declared separatly here. WRAPPER_CLASS(OmpDistScheduleClause, std::optional); diff --git a/flang/lib/Parser/openmp-parsers.cpp b/flang/lib/Parser/openmp-parsers.cpp --- a/flang/lib/Parser/openmp-parsers.cpp +++ b/flang/lib/Parser/openmp-parsers.cpp @@ -203,7 +203,7 @@ "NOGROUP" >> construct(construct()) || "NOTINBRANCH" >> construct(construct()) || - "NOWAIT" >> construct(construct()) || + "NOWAIT" >> construct(construct()) || "NUM_TASKS" >> construct(construct( parenthesized(scalarIntExpr))) || "NUM_TEAMS" >> construct(construct( diff --git a/flang/lib/Parser/unparse.cpp b/flang/lib/Parser/unparse.cpp --- a/flang/lib/Parser/unparse.cpp +++ b/flang/lib/Parser/unparse.cpp @@ -2076,7 +2076,6 @@ std::get>(x.t)); Word(")"); } - void Unparse(const OmpNowait &) { Word("NOWAIT"); } void Unparse(const OmpDistScheduleClause &x) { Word("DIST_SCHEDULE(STATIC"); Walk(", ", x.v); diff --git a/flang/lib/Semantics/check-omp-structure.h b/flang/lib/Semantics/check-omp-structure.h --- a/flang/lib/Semantics/check-omp-structure.h +++ b/flang/lib/Semantics/check-omp-structure.h @@ -126,7 +126,7 @@ void Leave(const parser::OmpClauseList &); void Enter(const parser::OmpClause &); - void Enter(const parser::OmpNowait &); + void Enter(const parser::OmpClause::Nowait &); void Enter(const parser::OmpClause::Allocator &); void Enter(const parser::OmpClause::Inbranch &); void Enter(const parser::OmpClause::Mergeable &); diff --git a/flang/lib/Semantics/check-omp-structure.cpp b/flang/lib/Semantics/check-omp-structure.cpp --- a/flang/lib/Semantics/check-omp-structure.cpp +++ b/flang/lib/Semantics/check-omp-structure.cpp @@ -416,6 +416,7 @@ CHECK_SIMPLE_CLAUSE(Mergeable, OMPC_mergeable) CHECK_SIMPLE_CLAUSE(Nogroup, OMPC_nogroup) CHECK_SIMPLE_CLAUSE(Notinbranch, OMPC_notinbranch) +CHECK_SIMPLE_CLAUSE(Nowait, OMPC_nowait) CHECK_SIMPLE_CLAUSE(To, OMPC_to) CHECK_SIMPLE_CLAUSE(Uniform, OMPC_uniform) CHECK_SIMPLE_CLAUSE(Untied, OMPC_untied) @@ -492,7 +493,6 @@ CHECK_SIMPLE_PARSER_CLAUSE(OmpAllocateClause, OMPC_allocate) CHECK_SIMPLE_PARSER_CLAUSE(OmpDefaultClause, OMPC_default) CHECK_SIMPLE_PARSER_CLAUSE(OmpDistScheduleClause, OMPC_dist_schedule) -CHECK_SIMPLE_PARSER_CLAUSE(OmpNowait, OMPC_nowait) CHECK_SIMPLE_PARSER_CLAUSE(OmpProcBindClause, OMPC_proc_bind) CHECK_SIMPLE_PARSER_CLAUSE(OmpReductionClause, OMPC_reduction) // Atomic-clause diff --git a/llvm/include/llvm/Frontend/OpenMP/OMP.td b/llvm/include/llvm/Frontend/OpenMP/OMP.td --- a/llvm/include/llvm/Frontend/OpenMP/OMP.td +++ b/llvm/include/llvm/Frontend/OpenMP/OMP.td @@ -147,7 +147,6 @@ } def OMPC_NoWait : Clause<"nowait"> { let clangClass = "OMPNowaitClause"; - let flangClass = "OmpNowait"; } def OMPC_Untied : Clause<"untied"> { let clangClass = "OMPUntiedClause"; } def OMPC_Mergeable : Clause<"mergeable"> {