[flang-commits] [flang] 84486cb - [fir][NFC] Move MLIR includes to FIRDialect.td

Valentin Clement via flang-commits flang-commits at lists.llvm.org
Mon Oct 25 09:33:53 PDT 2021


Author: Valentin Clement
Date: 2021-10-25T18:33:46+02:00
New Revision: 84486cb22265204c5b8abc5da940aea9d2cd64b2

URL: https://github.com/llvm/llvm-project/commit/84486cb22265204c5b8abc5da940aea9d2cd64b2
DIFF: https://github.com/llvm/llvm-project/commit/84486cb22265204c5b8abc5da940aea9d2cd64b2.diff

LOG: [fir][NFC] Move MLIR includes to FIRDialect.td

The fir_Dialect definition was coming silently through FIRTypes.td.
Make the include of flang/Optimizer/Dialect/FIRDialect.td explicit in
FIROps.td and move MLIR includes to FIRDialect.td.

This patch is part of the upstreaming effort from fir-dev branch.

Reviewed By: AlexisPerry

Differential Revision: https://reviews.llvm.org/D112418

Co-authored-by: Eric Schweitz <eschweitz at nvidia.com>

Added: 
    

Modified: 
    flang/include/flang/Optimizer/Dialect/FIRDialect.td
    flang/include/flang/Optimizer/Dialect/FIROps.td

Removed: 
    


################################################################################
diff  --git a/flang/include/flang/Optimizer/Dialect/FIRDialect.td b/flang/include/flang/Optimizer/Dialect/FIRDialect.td
index 0510848b8934..93a020c8ad78 100644
--- a/flang/include/flang/Optimizer/Dialect/FIRDialect.td
+++ b/flang/include/flang/Optimizer/Dialect/FIRDialect.td
@@ -14,6 +14,12 @@
 #ifndef FORTRAN_DIALECT_FIR_DIALECT
 #define FORTRAN_DIALECT_FIR_DIALECT
 
+include "mlir/IR/SymbolInterfaces.td"
+include "mlir/Interfaces/CallInterfaces.td"
+include "mlir/Interfaces/ControlFlowInterfaces.td"
+include "mlir/Interfaces/LoopLikeInterface.td"
+include "mlir/Interfaces/SideEffectInterfaces.td"
+
 def fir_Dialect : Dialect {
   let name = "fir";
   let cppNamespace = "::fir";

diff  --git a/flang/include/flang/Optimizer/Dialect/FIROps.td b/flang/include/flang/Optimizer/Dialect/FIROps.td
index b18fb27bd15c..a1f09ad0b630 100644
--- a/flang/include/flang/Optimizer/Dialect/FIROps.td
+++ b/flang/include/flang/Optimizer/Dialect/FIROps.td
@@ -14,11 +14,7 @@
 #ifndef FORTRAN_DIALECT_FIR_OPS
 #define FORTRAN_DIALECT_FIR_OPS
 
-include "mlir/IR/SymbolInterfaces.td"
-include "mlir/Interfaces/CallInterfaces.td"
-include "mlir/Interfaces/ControlFlowInterfaces.td"
-include "mlir/Interfaces/LoopLikeInterface.td"
-include "mlir/Interfaces/SideEffectInterfaces.td"
+include "flang/Optimizer/Dialect/FIRDialect.td"
 include "flang/Optimizer/Dialect/FIRTypes.td"
 
 // Base class for FIR operations.


        


More information about the flang-commits mailing list