Skip to content

Commit

Permalink
[fir][NFC] Move MLIR includes to FIRDialect.td
Browse files Browse the repository at this point in the history
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@nvidia.com>
  • Loading branch information
clementval and schweitzpgi committed Oct 25, 2021
1 parent 5694dbc commit 84486cb
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
6 changes: 6 additions & 0 deletions flang/include/flang/Optimizer/Dialect/FIRDialect.td
Expand Up @@ -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";
Expand Down
6 changes: 1 addition & 5 deletions flang/include/flang/Optimizer/Dialect/FIROps.td
Expand Up @@ -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.
Expand Down

0 comments on commit 84486cb

Please sign in to comment.