Skip to content

Commit

Permalink
[mlir] Rename the Standard dialect to the Func dialect
Browse files Browse the repository at this point in the history
The last remaining operations in the standard dialect all revolve around
FuncOp/function related constructs. This patch simply handles the initial
renaming (which by itself is already huge), but there are a large number
of cleanups unlocked/necessary afterwards:

* Removing a bunch of unnecessary dependencies on Func
* Cleaning up the From/ToStandard conversion passes
* Preparing for the move of FuncOp to the Func dialect

See the discussion at https://discourse.llvm.org/t/standard-dialect-the-final-chapter/6061

Differential Revision: https://reviews.llvm.org/D120624
  • Loading branch information
River707 committed Mar 1, 2022
1 parent 9bf6e3e commit 23aa5a7
Show file tree
Hide file tree
Showing 309 changed files with 958 additions and 980 deletions.
2 changes: 1 addition & 1 deletion flang/include/flang/Lower/Support/Utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include "flang/Common/indirection.h"
#include "flang/Parser/char-block.h"
#include "flang/Semantics/tools.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "mlir/IR/BuiltinAttributes.h"
#include "llvm/ADT/StringRef.h"
#include <cstdint>
Expand Down
2 changes: 1 addition & 1 deletion flang/include/flang/Optimizer/Builder/Factory.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

#include "flang/Optimizer/Dialect/FIROps.h"
#include "flang/Optimizer/Dialect/FIRType.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "llvm/ADT/iterator_range.h"

namespace mlir {
Expand Down
2 changes: 1 addition & 1 deletion flang/include/flang/Optimizer/Builder/Runtime/Character.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
#ifndef FORTRAN_OPTIMIZER_BUILDER_RUNTIME_CHARACTER_H
#define FORTRAN_OPTIMIZER_BUILDER_RUNTIME_CHARACTER_H

#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"

namespace fir {
class ExtendedValue;
Expand Down
2 changes: 1 addition & 1 deletion flang/include/flang/Optimizer/Builder/Runtime/Numeric.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
#ifndef FORTRAN_OPTIMIZER_BUILDER_RUNTIME_NUMERIC_H
#define FORTRAN_OPTIMIZER_BUILDER_RUNTIME_NUMERIC_H

#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"

namespace fir {
class ExtendedValue;
Expand Down
2 changes: 1 addition & 1 deletion flang/include/flang/Optimizer/Builder/Runtime/Reduction.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#ifndef FORTRAN_OPTIMIZER_BUILDER_RUNTIME_REDUCTION_H
#define FORTRAN_OPTIMIZER_BUILDER_RUNTIME_REDUCTION_H

#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"

namespace fir {
class ExtendedValue;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#ifndef FORTRAN_OPTIMIZER_BUILDER_RUNTIME_TRANSFORMATIONAL_H
#define FORTRAN_OPTIMIZER_BUILDER_RUNTIME_TRANSFORMATIONAL_H

#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"

namespace fir {
class ExtendedValue;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@

include "mlir/IR/OpBase.td"
include "mlir/Dialect/Arithmetic/IR/ArithmeticOps.td"
include "mlir/Dialect/StandardOps/IR/Ops.td"
include "flang/Optimizer/Dialect/FIROps.td"

def IdenticalTypePred : Constraint<CPred<"$0.getType() == $1.getType()">>;
Expand Down
2 changes: 1 addition & 1 deletion flang/include/flang/Optimizer/Dialect/FIROps.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

#include "flang/Optimizer/Dialect/FIRType.h"
#include "mlir/Dialect/Arithmetic/IR/Arithmetic.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "mlir/Interfaces/LoopLikeInterface.h"
#include "mlir/Interfaces/SideEffectInterfaces.h"

Expand Down
4 changes: 2 additions & 2 deletions flang/include/flang/Optimizer/Dialect/FIROpsSupport.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#define FORTRAN_OPTIMIZER_DIALECT_FIROPSSUPPORT_H

#include "flang/Optimizer/Dialect/FIROps.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "mlir/IR/BuiltinOps.h"

namespace fir {
Expand All @@ -25,7 +25,7 @@ inline bool nonVolatileLoad(mlir::Operation *op) {
/// return true iff the Operation is a call
inline bool isaCall(mlir::Operation *op) {
return isa<fir::CallOp>(op) || isa<fir::DispatchOp>(op) ||
isa<mlir::CallOp>(op) || isa<mlir::CallIndirectOp>(op);
isa<mlir::func::CallOp>(op) || isa<mlir::func::CallIndirectOp>(op);
}

/// return true iff the Operation is a fir::CallOp, fir::DispatchOp,
Expand Down
2 changes: 1 addition & 1 deletion flang/include/flang/Optimizer/Support/InitFIR.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ namespace fir::support {
mlir::AffineDialect, FIROpsDialect, mlir::acc::OpenACCDialect, \
mlir::omp::OpenMPDialect, mlir::scf::SCFDialect, \
mlir::arith::ArithmeticDialect, mlir::cf::ControlFlowDialect, \
mlir::StandardOpsDialect, mlir::vector::VectorDialect
mlir::func::FuncDialect, mlir::vector::VectorDialect

// The definitive list of dialects used by flang.
#define FLANG_DIALECT_LIST \
Expand Down
2 changes: 1 addition & 1 deletion flang/include/flang/Optimizer/Support/Utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

#include "flang/Common/default-kinds.h"
#include "flang/Optimizer/Dialect/FIRType.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "mlir/IR/BuiltinAttributes.h"

namespace fir {
Expand Down
10 changes: 5 additions & 5 deletions flang/include/flang/Optimizer/Transforms/Passes.td
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def AbstractResultOpt : Pass<"abstract-result-opt", "mlir::FuncOp"> {
}];
let constructor = "::fir::createAbstractResultOptPass()";
let dependentDialects = [
"fir::FIROpsDialect", "mlir::StandardOpsDialect"
"fir::FIROpsDialect", "mlir::func::FuncDialect"
];
let options = [
Option<"passResultAsBox", "abstract-result-as-box",
Expand Down Expand Up @@ -56,7 +56,7 @@ def AffineDialectPromotion : Pass<"promote-to-affine", "::mlir::FuncOp"> {
}];
let constructor = "::fir::createPromoteToAffinePass()";
let dependentDialects = [
"fir::FIROpsDialect", "mlir::StandardOpsDialect", "mlir::AffineDialect"
"fir::FIROpsDialect", "mlir::func::FuncDialect", "mlir::AffineDialect"
];
}

Expand All @@ -70,7 +70,7 @@ def AffineDialectDemotion : Pass<"demote-affine", "::mlir::FuncOp"> {
}];
let constructor = "::fir::createAffineDemotionPass()";
let dependentDialects = [
"fir::FIROpsDialect", "mlir::StandardOpsDialect", "mlir::AffineDialect"
"fir::FIROpsDialect", "mlir::func::FuncDialect", "mlir::AffineDialect"
];
}

Expand Down Expand Up @@ -122,7 +122,7 @@ def CFGConversion : Pass<"cfg-conversion", "::mlir::FuncOp"> {
}];
let constructor = "::fir::createFirToCfgPass()";
let dependentDialects = [
"fir::FIROpsDialect", "mlir::StandardOpsDialect"
"fir::FIROpsDialect", "mlir::func::FuncDialect"
];
let options = [
Option<"forceLoopToExecuteOnce", "always-execute-loop-body", "bool",
Expand All @@ -148,7 +148,7 @@ def MemRefDataFlowOpt : Pass<"fir-memref-dataflow-opt", "::mlir::FuncOp"> {
}];
let constructor = "::fir::createMemDataFlowOptPass()";
let dependentDialects = [
"fir::FIROpsDialect", "mlir::StandardOpsDialect"
"fir::FIROpsDialect", "mlir::func::FuncDialect"
];
}

Expand Down
4 changes: 2 additions & 2 deletions flang/lib/Lower/Bridge.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,7 @@ class FirConverter : public Fortran::lower::AbstractConverter {
/// Generate the cleanup block before the program exits
void genExitRoutine() {
if (blockIsUnterminated())
builder->create<mlir::ReturnOp>(toLocation());
builder->create<mlir::func::ReturnOp>(toLocation());
}
void genFIR(const Fortran::parser::EndProgramStmt &) { genExitRoutine(); }

Expand Down Expand Up @@ -459,7 +459,7 @@ class FirConverter : public Fortran::lower::AbstractConverter {
TODO(loc, "Convert to actual type");
return builder->create<fir::LoadOp>(loc, resultRef);
});
builder->create<mlir::ReturnOp>(loc, resultVal);
builder->create<mlir::func::ReturnOp>(loc, resultVal);
}

void genFIRProcedureExit(Fortran::lower::pft::FunctionLikeUnit &funit,
Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Lower/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ add_flang_library(FortranLower
FortranEvaluate
FortranSemantics
MLIRAffineToStandard
MLIRFunc
MLIRLLVMIR
MLIRSCFToControlFlow
MLIRStandard

LINK_COMPONENTS
Support
Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Lower/ConvertExpr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
#include "flang/Semantics/symbol.h"
#include "flang/Semantics/tools.h"
#include "flang/Semantics/type.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "llvm/Support/Debug.h"

#define DEBUG_TYPE "flang-lower-expr"
Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Optimizer/Builder/Runtime/Character.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#include "flang/Optimizer/Builder/FIRBuilder.h"
#include "flang/Optimizer/Builder/Runtime/RTBuilder.h"
#include "flang/Runtime/character.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"

using namespace Fortran::runtime;

Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Optimizer/Builder/Runtime/Numeric.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#include "flang/Optimizer/Builder/FIRBuilder.h"
#include "flang/Optimizer/Builder/Runtime/RTBuilder.h"
#include "flang/Runtime/numeric.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"

using namespace Fortran::runtime;

Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Optimizer/Builder/Runtime/Reduction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#include "flang/Optimizer/Builder/FIRBuilder.h"
#include "flang/Optimizer/Builder/Runtime/RTBuilder.h"
#include "flang/Runtime/reduction.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"

using namespace Fortran::runtime;

Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Optimizer/Builder/Runtime/Transformational.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#include "flang/Optimizer/Builder/Runtime/RTBuilder.h"
#include "flang/Runtime/matmul.h"
#include "flang/Runtime/transformational.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"

using namespace Fortran::runtime;

Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Optimizer/CodeGen/CGOps.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#define OPTIMIZER_CODEGEN_CGOPS_H

#include "flang/Optimizer/Dialect/FIRType.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"

using namespace mlir;

Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Optimizer/CodeGen/PreCGRewrite.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ class CodeGenRewrite : public CodeGenRewriteBase<CodeGenRewrite> {
mlir::OpBuilder rewriter(&context);
mlir::ConversionTarget target(context);
target.addLegalDialect<mlir::arith::ArithmeticDialect, FIROpsDialect,
FIRCodeGenDialect, mlir::StandardOpsDialect>();
FIRCodeGenDialect, mlir::func::FuncDialect>();
target.addIllegalOp<ArrayCoorOp>();
target.addIllegalOp<ReboxOp>();
target.addDynamicallyLegalOp<EmboxOp>([](EmboxOp embox) {
Expand Down
8 changes: 4 additions & 4 deletions flang/lib/Optimizer/CodeGen/TargetRewrite.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -599,20 +599,20 @@ class TargetRewrite : public TargetRewriteBase<TargetRewrite> {
auto newArg = func.front().insertArgument(fixup.index,
newInTys[fixup.index], loc);
offset++;
func.walk([&](mlir::ReturnOp ret) {
func.walk([&](mlir::func::ReturnOp ret) {
rewriter->setInsertionPoint(ret);
auto oldOper = ret.getOperand(0);
auto oldOperTy = ReferenceType::get(oldOper.getType());
auto cast = rewriter->create<ConvertOp>(loc, oldOperTy, newArg);
rewriter->create<fir::StoreOp>(loc, oldOper, cast);
rewriter->create<mlir::ReturnOp>(loc);
rewriter->create<mlir::func::ReturnOp>(loc);
ret.erase();
});
} break;
case FixupTy::Codes::ReturnType: {
// The function is still returning a value, but its type has likely
// changed to suit the target ABI convention.
func.walk([&](mlir::ReturnOp ret) {
func.walk([&](mlir::func::ReturnOp ret) {
rewriter->setInsertionPoint(ret);
auto oldOper = ret.getOperand(0);
auto oldOperTy = ReferenceType::get(oldOper.getType());
Expand All @@ -621,7 +621,7 @@ class TargetRewrite : public TargetRewriteBase<TargetRewrite> {
auto cast = rewriter->create<ConvertOp>(loc, oldOperTy, mem);
rewriter->create<fir::StoreOp>(loc, oldOper, cast);
mlir::Value load = rewriter->create<fir::LoadOp>(loc, mem);
rewriter->create<mlir::ReturnOp>(loc, load);
rewriter->create<mlir::func::ReturnOp>(loc, load);
ret.erase();
});
} break;
Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Optimizer/Dialect/FIRDialect.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ struct FIRInlinerInterface : public mlir::DialectInlinerInterface {
/// return.
void handleTerminator(mlir::Operation *op,
llvm::ArrayRef<mlir::Value> valuesToRepl) const final {
auto returnOp = cast<mlir::ReturnOp>(op);
auto returnOp = cast<mlir::func::ReturnOp>(op);
assert(returnOp.getNumOperands() == valuesToRepl.size());
for (const auto &it : llvm::enumerate(returnOp.getOperands()))
valuesToRepl[it.index()].replaceAllUsesWith(it.value());
Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Optimizer/Dialect/FIROps.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include "flang/Optimizer/Dialect/FIRType.h"
#include "flang/Optimizer/Support/Utils.h"
#include "mlir/Dialect/CommonFolders.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "mlir/IR/BuiltinAttributes.h"
#include "mlir/IR/BuiltinOps.h"
#include "mlir/IR/Diagnostics.h"
Expand Down
14 changes: 7 additions & 7 deletions flang/lib/Optimizer/Transforms/AbstractResult.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#include "flang/Optimizer/Dialect/FIROps.h"
#include "flang/Optimizer/Dialect/FIRType.h"
#include "flang/Optimizer/Transforms/Passes.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "mlir/IR/Diagnostics.h"
#include "mlir/Pass/Pass.h"
#include "mlir/Transforms/DialectConversion.h"
Expand Down Expand Up @@ -149,14 +149,14 @@ class SaveResultOpConversion
}
};

class ReturnOpConversion : public mlir::OpRewritePattern<mlir::ReturnOp> {
class ReturnOpConversion : public mlir::OpRewritePattern<mlir::func::ReturnOp> {
public:
using OpRewritePattern::OpRewritePattern;
ReturnOpConversion(mlir::MLIRContext *context,
const AbstractResultOptions &opt)
: OpRewritePattern(context), options{opt} {}
mlir::LogicalResult
matchAndRewrite(mlir::ReturnOp ret,
matchAndRewrite(mlir::func::ReturnOp ret,
mlir::PatternRewriter &rewriter) const override {
rewriter.setInsertionPoint(ret);
auto returnedValue = ret.getOperand(0);
Expand All @@ -177,7 +177,7 @@ class ReturnOpConversion : public mlir::OpRewritePattern<mlir::ReturnOp> {
if (!replacedStorage)
rewriter.create<fir::StoreOp>(ret.getLoc(), returnedValue,
options.newArg);
rewriter.replaceOpWithNewOp<mlir::ReturnOp>(ret);
rewriter.replaceOpWithNewOp<mlir::func::ReturnOp>(ret);
return mlir::success();
}

Expand Down Expand Up @@ -239,8 +239,8 @@ class AbstractResultOpt : public fir::AbstractResultOptBase<AbstractResultOpt> {
rewriter.create<fir::BoxAddrOp>(loc, bufferType, options.newArg);
}
patterns.insert<ReturnOpConversion>(context, options);
target.addDynamicallyLegalOp<mlir::ReturnOp>(
[](mlir::ReturnOp ret) { return ret.operands().empty(); });
target.addDynamicallyLegalOp<mlir::func::ReturnOp>(
[](mlir::func::ReturnOp ret) { return ret.operands().empty(); });
}
}

Expand All @@ -249,7 +249,7 @@ class AbstractResultOpt : public fir::AbstractResultOptBase<AbstractResultOpt> {

// Convert the calls and, if needed, the ReturnOp in the function body.
target.addLegalDialect<fir::FIROpsDialect, mlir::arith::ArithmeticDialect,
mlir::StandardOpsDialect>();
mlir::func::FuncDialect>();
target.addIllegalOp<fir::SaveResultOp>();
target.addDynamicallyLegalOp<fir::CallOp>([](fir::CallOp call) {
return !mustConvertCallOrFunc(call.getFunctionType());
Expand Down
4 changes: 2 additions & 2 deletions flang/lib/Optimizer/Transforms/AffineDemotion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@
#include "flang/Optimizer/Transforms/Passes.h"
#include "mlir/Dialect/Affine/IR/AffineOps.h"
#include "mlir/Dialect/Affine/Utils.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "mlir/Dialect/MemRef/IR/MemRef.h"
#include "mlir/Dialect/SCF/SCF.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/IR/BuiltinAttributes.h"
#include "mlir/IR/IntegerSet.h"
#include "mlir/IR/Visitors.h"
Expand Down Expand Up @@ -158,7 +158,7 @@ class AffineDialectDemotion
});
target.addLegalDialect<FIROpsDialect, mlir::scf::SCFDialect,
mlir::arith::ArithmeticDialect,
mlir::StandardOpsDialect>();
mlir::func::FuncDialect>();

if (mlir::failed(mlir::applyPartialConversion(function, target,
std::move(patterns)))) {
Expand Down
4 changes: 2 additions & 2 deletions flang/lib/Optimizer/Transforms/AffinePromotion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
#include "flang/Optimizer/Dialect/FIRType.h"
#include "flang/Optimizer/Transforms/Passes.h"
#include "mlir/Dialect/Affine/IR/AffineOps.h"
#include "mlir/Dialect/Func/IR/FuncOps.h"
#include "mlir/Dialect/SCF/SCF.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/IR/BuiltinAttributes.h"
#include "mlir/IR/IntegerSet.h"
#include "mlir/IR/Visitors.h"
Expand Down Expand Up @@ -595,7 +595,7 @@ class AffineDialectPromotion
mlir::ConversionTarget target = *context;
target.addLegalDialect<
mlir::AffineDialect, FIROpsDialect, mlir::scf::SCFDialect,
mlir::arith::ArithmeticDialect, mlir::StandardOpsDialect>();
mlir::arith::ArithmeticDialect, mlir::func::FuncDialect>();
target.addDynamicallyLegalOp<IfOp>([&functionAnalysis](fir::IfOp op) {
return !(functionAnalysis.getChildIfAnalysis(op).canPromoteToAffine());
});
Expand Down
2 changes: 1 addition & 1 deletion flang/lib/Optimizer/Transforms/ArrayValueCopy.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -792,7 +792,7 @@ class ArrayValueCopyConverter
mlir::ConversionTarget target(*context);
target.addLegalDialect<
FIROpsDialect, mlir::scf::SCFDialect, mlir::arith::ArithmeticDialect,
mlir::cf::ControlFlowDialect, mlir::StandardOpsDialect>();
mlir::cf::ControlFlowDialect, mlir::func::FuncDialect>();
target.addIllegalOp<ArrayFetchOp, ArrayUpdateOp, ArrayModifyOp>();
// Rewrite the array fetch and array update ops.
if (mlir::failed(
Expand Down
Loading

0 comments on commit 23aa5a7

Please sign in to comment.