diff --git a/include/matxscript/runtime/mlir/func_loader.h b/include/matxscript/runtime/mlir/func_loader.h index f0293794..a2330bd0 100644 --- a/include/matxscript/runtime/mlir/func_loader.h +++ b/include/matxscript/runtime/mlir/func_loader.h @@ -20,8 +20,8 @@ #pragma once #include -#include #include +#include namespace matxscript { namespace runtime { diff --git a/python/matx/kernel/codegen/graph_ir_printer.py b/python/matx/kernel/codegen/graph_ir_printer.py index a75483e2..3cbb69e5 100644 --- a/python/matx/kernel/codegen/graph_ir_printer.py +++ b/python/matx/kernel/codegen/graph_ir_printer.py @@ -231,7 +231,6 @@ def as_linalg_text(self): mlir_name_and_type = (f"{name}: {t}" for name, t in zip(mlir_args, mlir_arg_types)) self.mlir_printer.print(f"({', '.join(mlir_name_and_type)})", end='') - old_printer = self.mlir_printer body_printer = IrPrinter() self.mlir_printer = body_printer diff --git a/python/matx/kernel/compile_linalg.py b/python/matx/kernel/compile_linalg.py index 6a3a3dbb..2579b976 100644 --- a/python/matx/kernel/compile_linalg.py +++ b/python/matx/kernel/compile_linalg.py @@ -133,12 +133,12 @@ def write_linalg(graph_ir, output_fname="tmp.mlir", debug=False, over_written_co def lower_linalg_to_cpu(input_fname, output_fname="llvm_tmp.mlir"): env = os.environ.copy() lower = subprocess.Popen(['mlir-opt', - '--expand-strided-metadata', # for lower strided memref + '--expand-strided-metadata', # for lower strided memref '--convert-linalg-to-loops', '--lower-affine', '--arith-expand', '--memref-expand', - #'--normalize-memrefs', + # '--normalize-memrefs', '--fold-memref-alias-ops', '--arith-unsigned-when-equivalent', '--convert-scf-to-cf', @@ -151,10 +151,10 @@ def lower_linalg_to_cpu(input_fname, output_fname="llvm_tmp.mlir"): '--convert-cf-to-llvm', '--scf-for-loop-peeling', '--scf-for-loop-specialization', - #'--affine-expand-index-ops', - #'--affine-data-copy-generate', - #'--lower-affine', - #'--convert-arith-to-llvm', + # '--affine-expand-index-ops', + # '--affine-data-copy-generate', + # '--lower-affine', + # '--convert-arith-to-llvm', '--reconcile-unrealized-casts', input_fname, '-o', diff --git a/src/runtime/mlir/func_loader.cpp b/src/runtime/mlir/func_loader.cpp index 4010a8c4..3b1a8ec4 100644 --- a/src/runtime/mlir/func_loader.cpp +++ b/src/runtime/mlir/func_loader.cpp @@ -18,7 +18,6 @@ // under the License. #include "matxscript/runtime/mlir/func_loader.h" -#include "matxscript/runtime/mlir/convert_memref.h" #include "matxscript/runtime/py_args.h" namespace matxscript { namespace runtime {