2021-09-24 11:59:12 +08:00
|
|
|
add_subdirectory(TorchToLinalg)
|
|
|
|
add_subdirectory(TorchToSCF)
|
2022-08-11 03:12:51 +08:00
|
|
|
add_subdirectory(TorchToArith)
|
2021-10-08 10:07:03 +08:00
|
|
|
add_subdirectory(TorchToTosa)
|
2022-07-21 07:18:16 +08:00
|
|
|
if(TORCH_MLIR_ENABLE_MHLO)
|
|
|
|
add_subdirectory(TorchToMhlo)
|
|
|
|
endif()
|
2022-03-03 00:48:15 +08:00
|
|
|
add_subdirectory(TorchToTMTensor)
|
2022-03-03 00:42:25 +08:00
|
|
|
add_subdirectory(Utils)
|
2021-09-24 11:59:12 +08:00
|
|
|
|
|
|
|
# TODO: Automate this with add_torch_mlir_conversion_library.
|
2022-07-21 07:18:16 +08:00
|
|
|
set(linked_libs TorchMLIRTorchToLinalg
|
|
|
|
TorchMLIRTorchToSCF
|
2022-08-11 03:12:51 +08:00
|
|
|
TorchMLIRTorchToArith
|
2022-07-21 07:18:16 +08:00
|
|
|
TorchMLIRTorchToTosa
|
|
|
|
TorchMLIRTorchToTMTensor
|
|
|
|
TorchMLIRConversionUtils)
|
|
|
|
if(TORCH_MLIR_ENABLE_MHLO)
|
|
|
|
list(APPEND linked_libs TorchMLIRTorchToMhlo)
|
|
|
|
endif()
|
2021-09-24 11:59:12 +08:00
|
|
|
|
|
|
|
add_mlir_library(TorchMLIRConversionPasses
|
|
|
|
Passes.cpp
|
|
|
|
|
|
|
|
DEPENDS
|
|
|
|
TorchMLIRConversionPassIncGen
|
|
|
|
|
|
|
|
LINK_COMPONENTS
|
|
|
|
Core
|
|
|
|
|
|
|
|
LINK_LIBS PUBLIC
|
2022-07-21 07:18:16 +08:00
|
|
|
${linked_libs}
|
2021-09-24 11:59:12 +08:00
|
|
|
#${torch_mlir_conversion_libs}
|
|
|
|
)
|