diff --git a/.gitignore b/.gitignore index be58b3d..258a6a8 100644 --- a/.gitignore +++ b/.gitignore @@ -16,4 +16,4 @@ bazel-testlogs /CMakeSettings.json # Compilation databases compile_commands.json -tablegen_compile_commands.yml \ No newline at end of file +tablegen_compile_commands.yml diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index f66a974..714031d 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -1,2 +1,3 @@ add_subdirectory(Dialect) -add_subdirectory(Transform) \ No newline at end of file +add_subdirectory(Conversion) +add_subdirectory(Transform) diff --git a/lib/Conversion/CMakeLists.txt b/lib/Conversion/CMakeLists.txt new file mode 100644 index 0000000..fb91c06 --- /dev/null +++ b/lib/Conversion/CMakeLists.txt @@ -0,0 +1 @@ +add_subdirectory(PolyToStandard) diff --git a/lib/Conversion/PolyToStandard/CMakeLists.txt b/lib/Conversion/PolyToStandard/CMakeLists.txt new file mode 100644 index 0000000..96dde92 --- /dev/null +++ b/lib/Conversion/PolyToStandard/CMakeLists.txt @@ -0,0 +1,29 @@ +add_mlir_library(PolyToStandard + PolyToStandard.cpp + + ${PROJECT_SOURCE_DIR}/lib/Conversion/PolyToStandard/ + ADDITIONAL_HEADER_DIRS + + DEPENDS + PolyToStandardPassIncGen + + LINK_COMPONENTS + Core + + LINK_LIBS PUBLIC + MLIRPoly + MLIRArithDialect + MLIRFuncDialect + MLIRFuncTransforms + MLIRIR + MLIRPass + MLIRSCFDialect + MLIRTensorDialect + MLIRTransforms + ) + +set(LLVM_TARGET_DEFINITIONS PolyToStandard.td) +mlir_tablegen(PolyToStandard.h.inc -gen-pass-decls -name PolyToStandard) +add_dependencies(mlir-headers MLIRPolyOpsIncGen) +add_public_tablegen_target(PolyToStandardPassIncGen) +add_mlir_doc(PolyToStandard PolyToStandard PolyToStandard/ -gen-pass-doc) diff --git a/lib/Dialect/Poly/CMakeLists.txt b/lib/Dialect/Poly/CMakeLists.txt index 628253c..f001992 100644 --- a/lib/Dialect/Poly/CMakeLists.txt +++ b/lib/Dialect/Poly/CMakeLists.txt @@ -24,4 +24,4 @@ add_mlir_dialect_library(MLIRPoly ${PROJECT_SOURCE_DIR}/lib/Dialect/Poly LINK_LIBS PUBLIC - ) \ No newline at end of file + ) diff --git a/lib/Transform/Affine/CMakeLists.txt b/lib/Transform/Affine/CMakeLists.txt index dd3340b..eaa2b68 100644 --- a/lib/Transform/Affine/CMakeLists.txt +++ b/lib/Transform/Affine/CMakeLists.txt @@ -10,4 +10,4 @@ add_mlir_library(AffineFullUnroll set(LLVM_TARGET_DEFINITIONS Passes.td) mlir_tablegen(Passes.h.inc -gen-pass-decls -name Affine) add_public_tablegen_target(MLIRAffineFullUnrollPasses) -add_mlir_doc(Passes AffinePasses ./ -gen-pass-doc) \ No newline at end of file +add_mlir_doc(Passes AffinePasses ./ -gen-pass-doc) diff --git a/tools/CMakeLists.txt b/tools/CMakeLists.txt index 930bb80..59f33b1 100644 --- a/tools/CMakeLists.txt +++ b/tools/CMakeLists.txt @@ -9,6 +9,7 @@ set (LIBS MulToAdd MLIROptLib MLIRPass + PolyToStandard ) add_llvm_executable(tutorial-opt tutorial-opt.cpp) @@ -16,4 +17,4 @@ add_llvm_executable(tutorial-opt tutorial-opt.cpp) llvm_update_compile_flags(tutorial-opt) target_link_libraries(tutorial-opt PRIVATE ${LIBS}) -mlir_check_all_link_libraries(tutorial-opt) \ No newline at end of file +mlir_check_all_link_libraries(tutorial-opt)