[flang-commits] [flang] [flang][OpenMP] Remove no longer used OmpLoopDirective, NFC (PR #159576)
    via flang-commits 
    flang-commits at lists.llvm.org
       
    Thu Sep 18 07:18:05 PDT 2025
    
    
  
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-flang-parser
Author: Krzysztof Parzyszek (kparzysz)
<details>
<summary>Changes</summary>
---
Full diff: https://github.com/llvm/llvm-project/pull/159576.diff
4 Files Affected:
- (modified) flang/examples/FeatureList/FeatureList.cpp (-1) 
- (modified) flang/include/flang/Parser/dump-parse-tree.h (-1) 
- (modified) flang/include/flang/Parser/parse-tree.h (-6) 
- (modified) flang/lib/Semantics/check-omp-structure.cpp (-4) 
``````````diff
diff --git a/flang/examples/FeatureList/FeatureList.cpp b/flang/examples/FeatureList/FeatureList.cpp
index 8d370adc51d61..cb92e30051930 100644
--- a/flang/examples/FeatureList/FeatureList.cpp
+++ b/flang/examples/FeatureList/FeatureList.cpp
@@ -485,7 +485,6 @@ struct NodeVisitor {
   READ_FEATURE(OmpLinearClause::Modifier)
   READ_FEATURE(OmpLinearModifier)
   READ_FEATURE(OmpLinearModifier::Value)
-  READ_FEATURE(OmpLoopDirective)
   READ_FEATURE(OmpMapClause)
   READ_FEATURE(OmpMapClause::Modifier)
   READ_FEATURE(OmpNumTasksClause)
diff --git a/flang/include/flang/Parser/dump-parse-tree.h b/flang/include/flang/Parser/dump-parse-tree.h
index 1c9fd7673e06d..61a94223aabf4 100644
--- a/flang/include/flang/Parser/dump-parse-tree.h
+++ b/flang/include/flang/Parser/dump-parse-tree.h
@@ -615,7 +615,6 @@ class ParseTreeDumper {
   NODE_ENUM(OmpLinearModifier, Value)
   NODE(parser, OmpLocator)
   NODE(parser, OmpLocatorList)
-  NODE(parser, OmpLoopDirective)
   NODE(parser, OmpMapClause)
   NODE(OmpMapClause, Modifier)
   NODE(parser, OmpMapper)
diff --git a/flang/include/flang/Parser/parse-tree.h b/flang/include/flang/Parser/parse-tree.h
index 7307283eb91ec..ff5a8b026613f 100644
--- a/flang/include/flang/Parser/parse-tree.h
+++ b/flang/include/flang/Parser/parse-tree.h
@@ -5075,12 +5075,6 @@ struct OpenMPAtomicConstruct : public OmpBlockConstruct {
   mutable Analysis analysis;
 };
 
-// OpenMP directives that associate with loop(s)
-struct OmpLoopDirective {
-  WRAPPER_CLASS_BOILERPLATE(OmpLoopDirective, llvm::omp::Directive);
-  CharBlock source;
-};
-
 // 2.14.2 cancellation-point -> CANCELLATION POINT construct-type-clause
 struct OpenMPCancellationPointConstruct {
   WRAPPER_CLASS_BOILERPLATE(
diff --git a/flang/lib/Semantics/check-omp-structure.cpp b/flang/lib/Semantics/check-omp-structure.cpp
index 4c7cd1734e0e7..421e9e149755c 100644
--- a/flang/lib/Semantics/check-omp-structure.cpp
+++ b/flang/lib/Semantics/check-omp-structure.cpp
@@ -679,10 +679,6 @@ template <typename Checker> struct DirectiveSpellingVisitor {
     checker_(x.DirName().source, x.DirId());
     return false;
   }
-  bool Pre(const parser::OmpLoopDirective &x) {
-    checker_(x.source, x.v);
-    return false;
-  }
 
   bool Pre(const parser::OmpDirectiveSpecification &x) {
     auto &name = std::get<parser::OmpDirectiveName>(x.t);
``````````
</details>
https://github.com/llvm/llvm-project/pull/159576
    
    
More information about the flang-commits
mailing list