2020-04-01 02:45:59 +08:00
|
|
|
include_directories(include)
|
2019-10-16 06:09:45 +08:00
|
|
|
add_subdirectory(include)
|
|
|
|
|
2019-04-04 09:45:01 +08:00
|
|
|
set(LLVM_LINK_COMPONENTS
|
|
|
|
Support
|
|
|
|
)
|
|
|
|
|
2019-10-16 02:40:12 +08:00
|
|
|
set(LLVM_TARGET_DEFINITIONS mlir/ToyCombine.td)
|
2020-04-01 02:45:59 +08:00
|
|
|
mlir_tablegen(ToyCombine.inc -gen-rewriters)
|
2019-10-16 02:40:12 +08:00
|
|
|
add_public_tablegen_target(ToyCh3CombineIncGen)
|
|
|
|
|
2019-04-04 09:45:01 +08:00
|
|
|
add_toy_chapter(toyc-ch3
|
|
|
|
toyc.cpp
|
|
|
|
parser/AST.cpp
|
|
|
|
mlir/MLIRGen.cpp
|
2019-10-16 02:40:12 +08:00
|
|
|
mlir/Dialect.cpp
|
|
|
|
mlir/ToyCombine.cpp
|
2020-02-21 02:48:51 +08:00
|
|
|
|
|
|
|
DEPENDS
|
|
|
|
ToyCh3OpsIncGen
|
|
|
|
ToyCh3CombineIncGen
|
2019-04-04 09:45:01 +08:00
|
|
|
)
|
2019-10-16 02:40:12 +08:00
|
|
|
|
|
|
|
include_directories(${CMAKE_CURRENT_BINARY_DIR})
|
|
|
|
include_directories(${CMAKE_CURRENT_BINARY_DIR}/include/)
|
2019-04-04 09:45:01 +08:00
|
|
|
target_link_libraries(toyc-ch3
|
|
|
|
PRIVATE
|
|
|
|
MLIRAnalysis
|
|
|
|
MLIRIR
|
|
|
|
MLIRParser
|
2019-10-16 02:40:12 +08:00
|
|
|
MLIRPass
|
2020-03-11 03:25:08 +08:00
|
|
|
MLIRSideEffects
|
2019-04-04 09:45:01 +08:00
|
|
|
MLIRTransforms)
|
2019-10-16 02:40:12 +08:00
|
|
|
|