From d404345403c5ed3d89d46ea2d84705a69169d597 Mon Sep 17 00:00:00 2001 From: Mehdi Amini Date: Tue, 1 Oct 2024 00:44:21 +0200 Subject: [PATCH] Revert "CMake: Remove unnecessary dependencies on LLVM/MLIR" (#110594) Reverts llvm/llvm-project#110362 Multiple bots are broken. --- llvm/lib/MC/CMakeLists.txt | 1 + mlir/lib/Conversion/ConvertToLLVM/CMakeLists.txt | 1 + mlir/lib/Conversion/VectorToLLVM/CMakeLists.txt | 2 ++ mlir/lib/Dialect/Affine/Transforms/CMakeLists.txt | 1 + mlir/lib/Dialect/Arith/Transforms/CMakeLists.txt | 2 ++ mlir/lib/Dialect/Func/Transforms/CMakeLists.txt | 2 ++ mlir/lib/Dialect/GPU/CMakeLists.txt | 2 ++ mlir/lib/Dialect/Linalg/IR/CMakeLists.txt | 2 ++ mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt | 8 ++++++++ mlir/lib/Dialect/MemRef/Transforms/CMakeLists.txt | 3 +++ mlir/lib/Dialect/Mesh/Transforms/CMakeLists.txt | 2 ++ mlir/lib/Dialect/SCF/Transforms/CMakeLists.txt | 4 ++++ mlir/lib/Dialect/Tensor/Transforms/CMakeLists.txt | 4 ++++ mlir/lib/Dialect/Tosa/CMakeLists.txt | 3 +++ mlir/lib/Dialect/Vector/Transforms/CMakeLists.txt | 2 ++ mlir/lib/Target/LLVM/CMakeLists.txt | 1 + mlir/lib/Target/LLVMIR/CMakeLists.txt | 2 ++ mlir/lib/Target/SPIRV/CMakeLists.txt | 4 ++++ mlir/lib/Target/SPIRV/Serialization/CMakeLists.txt | 3 +++ mlir/lib/Transforms/CMakeLists.txt | 1 + mlir/unittests/Target/LLVM/CMakeLists.txt | 1 - 21 files changed, 50 insertions(+), 1 deletion(-) diff --git a/llvm/lib/MC/CMakeLists.txt b/llvm/lib/MC/CMakeLists.txt index e1d19196c8766a..a089d2bff94f42 100644 --- a/llvm/lib/MC/CMakeLists.txt +++ b/llvm/lib/MC/CMakeLists.txt @@ -79,6 +79,7 @@ add_llvm_component_library(LLVMMC Support TargetParser BinaryFormat + DebugInfoCodeView DEPENDS intrinsics_gen diff --git a/mlir/lib/Conversion/ConvertToLLVM/CMakeLists.txt b/mlir/lib/Conversion/ConvertToLLVM/CMakeLists.txt index de3d850d520c0f..df7e3f995303c9 100644 --- a/mlir/lib/Conversion/ConvertToLLVM/CMakeLists.txt +++ b/mlir/lib/Conversion/ConvertToLLVM/CMakeLists.txt @@ -20,6 +20,7 @@ add_mlir_conversion_library(MLIRConvertToLLVMPass MLIRConversionPassIncGen LINK_LIBS PUBLIC + MLIRConvertToLLVMInterface MLIRIR MLIRLLVMCommonConversion MLIRLLVMDialect diff --git a/mlir/lib/Conversion/VectorToLLVM/CMakeLists.txt b/mlir/lib/Conversion/VectorToLLVM/CMakeLists.txt index 27b5bf7eaa89f2..35576732c82cfb 100644 --- a/mlir/lib/Conversion/VectorToLLVM/CMakeLists.txt +++ b/mlir/lib/Conversion/VectorToLLVM/CMakeLists.txt @@ -34,6 +34,8 @@ add_mlir_conversion_library(MLIRVectorToLLVMPass LINK_LIBS PUBLIC MLIRVectorToLLVM + MLIRArmNeonDialect + MLIRArmSMEDialect MLIRArmSVEDialect MLIRArmSVETransforms MLIRAMXDialect diff --git a/mlir/lib/Dialect/Affine/Transforms/CMakeLists.txt b/mlir/lib/Dialect/Affine/Transforms/CMakeLists.txt index 607d4557e2f6a2..772f15335d907f 100644 --- a/mlir/lib/Dialect/Affine/Transforms/CMakeLists.txt +++ b/mlir/lib/Dialect/Affine/Transforms/CMakeLists.txt @@ -32,6 +32,7 @@ add_mlir_dialect_library(MLIRAffineTransforms MLIRIR MLIRMemRefDialect MLIRPass + MLIRSCFUtils MLIRSideEffectInterfaces MLIRTensorDialect MLIRTransformUtils diff --git a/mlir/lib/Dialect/Arith/Transforms/CMakeLists.txt b/mlir/lib/Dialect/Arith/Transforms/CMakeLists.txt index 93a004d31916f5..6b8bde8dc2aaf3 100644 --- a/mlir/lib/Dialect/Arith/Transforms/CMakeLists.txt +++ b/mlir/lib/Dialect/Arith/Transforms/CMakeLists.txt @@ -20,6 +20,8 @@ add_mlir_dialect_library(MLIRArithTransforms LINK_LIBS PUBLIC MLIRAnalysis MLIRArithDialect + MLIRBufferizationDialect + MLIRBufferizationTransforms MLIRFuncDialect MLIRFuncTransforms MLIRInferIntRangeInterface diff --git a/mlir/lib/Dialect/Func/Transforms/CMakeLists.txt b/mlir/lib/Dialect/Func/Transforms/CMakeLists.txt index 6ba7aaaae903f4..172019907c3a8a 100644 --- a/mlir/lib/Dialect/Func/Transforms/CMakeLists.txt +++ b/mlir/lib/Dialect/Func/Transforms/CMakeLists.txt @@ -12,6 +12,8 @@ add_mlir_dialect_library(MLIRFuncTransforms MLIRFuncTransformsIncGen LINK_LIBS PUBLIC + MLIRBufferizationDialect + MLIRBufferizationTransforms MLIRFuncDialect MLIRIR MLIRMemRefDialect diff --git a/mlir/lib/Dialect/GPU/CMakeLists.txt b/mlir/lib/Dialect/GPU/CMakeLists.txt index a8a961282993a2..a59645480aba21 100644 --- a/mlir/lib/Dialect/GPU/CMakeLists.txt +++ b/mlir/lib/Dialect/GPU/CMakeLists.txt @@ -67,7 +67,9 @@ add_mlir_dialect_library(MLIRGPUTransforms MLIRPass MLIRSCFDialect MLIRSideEffectInterfaces + MLIRSPIRVTarget MLIRSupport + MLIRROCDLTarget MLIRTransformUtils MLIRVectorDialect ) diff --git a/mlir/lib/Dialect/Linalg/IR/CMakeLists.txt b/mlir/lib/Dialect/Linalg/IR/CMakeLists.txt index f1fcb22fb8d548..c187563b8f0c4e 100644 --- a/mlir/lib/Dialect/Linalg/IR/CMakeLists.txt +++ b/mlir/lib/Dialect/Linalg/IR/CMakeLists.txt @@ -25,12 +25,14 @@ add_mlir_dialect_library(MLIRLinalgDialect MLIRInferTypeOpInterface MLIRIR MLIRParser + MLIRShardingInterface MLIRSideEffectInterfaces MLIRSparseTensorDialect MLIRSCFDialect MLIRMathDialect MLIRMemRefDialect MLIRTensorDialect + MLIRTilingInterface MLIRValueBoundsOpInterface MLIRViewLikeInterface ) diff --git a/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt b/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt index 06bac0d470d42e..47af392def94ac 100644 --- a/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt +++ b/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt @@ -48,11 +48,14 @@ add_mlir_dialect_library(MLIRLinalgTransforms LINK_LIBS PUBLIC MLIRAffineDialect + MLIRAffineTransforms MLIRAffineUtils MLIRAnalysis MLIRArithDialect MLIRArithTransforms MLIRArithUtils + MLIRBufferizationDialect + MLIRBufferizationTransforms MLIRComplexDialect MLIRDestinationStyleOpInterface MLIRDialectUtils @@ -63,15 +66,20 @@ add_mlir_dialect_library(MLIRLinalgTransforms MLIRIR MLIRMemRefDialect MLIRMemRefTransforms + MLIRMeshDialect MLIRMeshTransforms MLIRLinalgDialect MLIRLinalgUtils MLIRSCFDialect MLIRSCFTransforms + MLIRSCFUtils MLIRPass + MLIRShardingInterface MLIRSubsetOpInterface MLIRSparseTensorDialect MLIRTensorDialect + MLIRTensorTilingInterfaceImpl + MLIRTensorTransforms MLIRTransforms MLIRTransformUtils MLIRValueBoundsOpInterface diff --git a/mlir/lib/Dialect/MemRef/Transforms/CMakeLists.txt b/mlir/lib/Dialect/MemRef/Transforms/CMakeLists.txt index ecab97bc2b8e75..4c7f42745ce8bb 100644 --- a/mlir/lib/Dialect/MemRef/Transforms/CMakeLists.txt +++ b/mlir/lib/Dialect/MemRef/Transforms/CMakeLists.txt @@ -22,10 +22,13 @@ add_mlir_dialect_library(MLIRMemRefTransforms MLIRMemRefPassIncGen LINK_LIBS PUBLIC + MLIRAffineDialect MLIRAffineTransforms MLIRAffineUtils MLIRArithDialect MLIRArithTransforms + MLIRBufferizationDialect + MLIRBufferizationTransforms MLIRDialectUtils MLIRFuncDialect MLIRGPUDialect diff --git a/mlir/lib/Dialect/Mesh/Transforms/CMakeLists.txt b/mlir/lib/Dialect/Mesh/Transforms/CMakeLists.txt index d1d6261fb448d4..212ea6d6948b27 100644 --- a/mlir/lib/Dialect/Mesh/Transforms/CMakeLists.txt +++ b/mlir/lib/Dialect/Mesh/Transforms/CMakeLists.txt @@ -23,6 +23,8 @@ add_mlir_dialect_library(MLIRMeshTransforms MLIRIR MLIRMeshDialect MLIRPass + MLIRShardingInterface MLIRSupport MLIRTensorDialect + MLIRTosaShardingInterfaceImpl ) diff --git a/mlir/lib/Dialect/SCF/Transforms/CMakeLists.txt b/mlir/lib/Dialect/SCF/Transforms/CMakeLists.txt index fb877b50914920..8c73515c608f58 100644 --- a/mlir/lib/Dialect/SCF/Transforms/CMakeLists.txt +++ b/mlir/lib/Dialect/SCF/Transforms/CMakeLists.txt @@ -29,6 +29,8 @@ add_mlir_dialect_library(MLIRSCFTransforms MLIRAffineDialect MLIRAffineAnalysis MLIRArithDialect + MLIRBufferizationDialect + MLIRBufferizationTransforms MLIRDestinationStyleOpInterface MLIRDialectUtils MLIRIR @@ -38,7 +40,9 @@ add_mlir_dialect_library(MLIRSCFTransforms MLIRSCFUtils MLIRSideEffectInterfaces MLIRSupport + MLIRTensorDialect MLIRTensorTransforms + MLIRTilingInterface MLIRTransforms MLIRTransformUtils ) diff --git a/mlir/lib/Dialect/Tensor/Transforms/CMakeLists.txt b/mlir/lib/Dialect/Tensor/Transforms/CMakeLists.txt index a6152ecc23b532..ce32dea09bb0b5 100644 --- a/mlir/lib/Dialect/Tensor/Transforms/CMakeLists.txt +++ b/mlir/lib/Dialect/Tensor/Transforms/CMakeLists.txt @@ -20,9 +20,12 @@ add_mlir_dialect_library(MLIRTensorTransforms LINK_LIBS PUBLIC MLIRAffineDialect + MLIRAffineTransforms MLIRAffineUtils MLIRArithDialect MLIRArithUtils + MLIRBufferizationDialect + MLIRBufferizationTransforms MLIRDialectUtils MLIRIR MLIRLinalgDialect @@ -32,6 +35,7 @@ add_mlir_dialect_library(MLIRTensorTransforms MLIRSubsetOpInterface MLIRTensorDialect MLIRTensorUtils + MLIRTilingInterface MLIRTransforms MLIRVectorDialect MLIRVectorUtils diff --git a/mlir/lib/Dialect/Tosa/CMakeLists.txt b/mlir/lib/Dialect/Tosa/CMakeLists.txt index 4b72309a70c064..1911405c63cd58 100644 --- a/mlir/lib/Dialect/Tosa/CMakeLists.txt +++ b/mlir/lib/Dialect/Tosa/CMakeLists.txt @@ -19,6 +19,7 @@ add_mlir_dialect_library(MLIRTosaDialect MLIRDialect MLIRCallInterfaces MLIRControlFlowInterfaces + MLIRQuantDialect MLIRQuantUtils MLIRSideEffectInterfaces MLIRTensorDialect @@ -34,8 +35,10 @@ add_mlir_dialect_library(MLIRTosaShardingInterfaceImpl LINK_LIBS PUBLIC MLIRIR + MLIRMeshDialect MLIRShardingInterface MLIRSupport + MLIRTosaDialect ) add_subdirectory(Transforms) diff --git a/mlir/lib/Dialect/Vector/Transforms/CMakeLists.txt b/mlir/lib/Dialect/Vector/Transforms/CMakeLists.txt index b7e8724c3c2582..2639a67e1c8b31 100644 --- a/mlir/lib/Dialect/Vector/Transforms/CMakeLists.txt +++ b/mlir/lib/Dialect/Vector/Transforms/CMakeLists.txt @@ -35,6 +35,8 @@ add_mlir_dialect_library(MLIRVectorTransforms MLIRAffineAnalysis MLIRAffineUtils MLIRArithDialect + MLIRBufferizationDialect + MLIRBufferizationTransforms MLIRDialectUtils MLIRGPUDialect MLIRIR diff --git a/mlir/lib/Target/LLVM/CMakeLists.txt b/mlir/lib/Target/LLVM/CMakeLists.txt index 7e597b0f9bf94a..bc14c568e46be2 100644 --- a/mlir/lib/Target/LLVM/CMakeLists.txt +++ b/mlir/lib/Target/LLVM/CMakeLists.txt @@ -125,6 +125,7 @@ add_mlir_dialect_library(MLIRROCDLTarget MLIRSupport MLIRGPUDialect MLIRTargetLLVM + MLIRROCDLToLLVMIRTranslation ) if(MLIR_ENABLE_ROCM_CONVERSIONS) diff --git a/mlir/lib/Target/LLVMIR/CMakeLists.txt b/mlir/lib/Target/LLVMIR/CMakeLists.txt index 4cc83edb0e9616..93032c3ce10387 100644 --- a/mlir/lib/Target/LLVMIR/CMakeLists.txt +++ b/mlir/lib/Target/LLVMIR/CMakeLists.txt @@ -38,6 +38,7 @@ add_mlir_translation_library(MLIRTargetLLVMIRExport MLIRDLTIDialect MLIRLLVMDialect MLIRLLVMIRTransforms + MLIRTranslateLib MLIRTransformUtils ) @@ -78,6 +79,7 @@ add_mlir_translation_library(MLIRTargetLLVMIRImport LINK_LIBS PUBLIC MLIRDLTIDialect MLIRLLVMDialect + MLIRTranslateLib ) add_mlir_translation_library(MLIRFromLLVMIRTranslationRegistration diff --git a/mlir/lib/Target/SPIRV/CMakeLists.txt b/mlir/lib/Target/SPIRV/CMakeLists.txt index 2926320ed286b8..22d6d195a249eb 100644 --- a/mlir/lib/Target/SPIRV/CMakeLists.txt +++ b/mlir/lib/Target/SPIRV/CMakeLists.txt @@ -12,6 +12,7 @@ add_mlir_translation_library(MLIRSPIRVBinaryUtils LINK_LIBS PUBLIC MLIRIR + MLIRSPIRVDialect MLIRSupport ) @@ -20,9 +21,11 @@ add_mlir_translation_library(MLIRSPIRVTranslateRegistration LINK_LIBS PUBLIC MLIRIR + MLIRSPIRVDialect MLIRSPIRVSerialization MLIRSPIRVDeserialization MLIRSupport + MLIRTranslateLib ) add_mlir_dialect_library(MLIRSPIRVTarget @@ -31,6 +34,7 @@ add_mlir_dialect_library(MLIRSPIRVTarget LINK_LIBS PUBLIC MLIRIR MLIRGPUDialect + MLIRSPIRVDialect MLIRSPIRVSerialization MLIRSupport ) diff --git a/mlir/lib/Target/SPIRV/Serialization/CMakeLists.txt b/mlir/lib/Target/SPIRV/Serialization/CMakeLists.txt index 036b97af4f9e7c..71580d8fcb978e 100644 --- a/mlir/lib/Target/SPIRV/Serialization/CMakeLists.txt +++ b/mlir/lib/Target/SPIRV/Serialization/CMakeLists.txt @@ -8,7 +8,10 @@ add_mlir_translation_library(MLIRSPIRVSerialization LINK_LIBS PUBLIC MLIRIR + MLIRSPIRVDialect MLIRSPIRVBinaryUtils MLIRSupport MLIRTranslateLib ) + + diff --git a/mlir/lib/Transforms/CMakeLists.txt b/mlir/lib/Transforms/CMakeLists.txt index 058039e47313e2..90c0298fb5e46a 100644 --- a/mlir/lib/Transforms/CMakeLists.txt +++ b/mlir/lib/Transforms/CMakeLists.txt @@ -29,6 +29,7 @@ add_mlir_library(MLIRTransforms LINK_LIBS PUBLIC MLIRAnalysis + MLIRCopyOpInterface MLIRFunctionInterfaces MLIRLoopLikeInterface MLIRMemorySlotInterfaces diff --git a/mlir/unittests/Target/LLVM/CMakeLists.txt b/mlir/unittests/Target/LLVM/CMakeLists.txt index 5d50e98f1a2a45..6d612548a94c0f 100644 --- a/mlir/unittests/Target/LLVM/CMakeLists.txt +++ b/mlir/unittests/Target/LLVM/CMakeLists.txt @@ -19,7 +19,6 @@ target_link_libraries(MLIRTargetLLVMTests MLIRNVVMToLLVMIRTranslation MLIRROCDLToLLVMIRTranslation MLIRGPUToLLVMIRTranslation - MLIRParser ${llvm_libs} )