[Mlir-commits] [mlir] 2488016 - [MLIR] Remove redundant library dependencies
Stephen Neuendorffer
llvmlistbot at llvm.org
Fri Mar 6 10:12:42 PST 2020
Author: Stephen Neuendorffer
Date: 2020-03-06T10:12:31-08:00
New Revision: 2488016baecfba3d4afcbfd1a4431eede32435c7
URL: https://github.com/llvm/llvm-project/commit/2488016baecfba3d4afcbfd1a4431eede32435c7
DIFF: https://github.com/llvm/llvm-project/commit/2488016baecfba3d4afcbfd1a4431eede32435c7.diff
LOG: [MLIR] Remove redundant library dependencies
In cmake, it is redundant to have a target list under target_link_libraries()
and add_dependency(). This patch removes the redundant dependency from
add_dependency().
Differential Revision: https://reviews.llvm.org/D74929
Added:
Modified:
mlir/lib/Analysis/CMakeLists.txt
mlir/lib/Conversion/AffineToStandard/CMakeLists.txt
mlir/lib/Conversion/LoopToStandard/CMakeLists.txt
mlir/lib/Conversion/LoopsToGPU/CMakeLists.txt
mlir/lib/Conversion/StandardToLLVM/CMakeLists.txt
mlir/lib/Dialect/AffineOps/CMakeLists.txt
mlir/lib/Dialect/FxpMathOps/CMakeLists.txt
mlir/lib/Dialect/GPU/CMakeLists.txt
mlir/lib/Dialect/LLVMIR/CMakeLists.txt
mlir/lib/Dialect/Linalg/Analysis/CMakeLists.txt
mlir/lib/Dialect/Linalg/EDSC/CMakeLists.txt
mlir/lib/Dialect/Linalg/IR/CMakeLists.txt
mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt
mlir/lib/Dialect/Linalg/Utils/CMakeLists.txt
mlir/lib/Dialect/LoopOps/CMakeLists.txt
mlir/lib/Dialect/QuantOps/CMakeLists.txt
mlir/lib/Dialect/SDBM/CMakeLists.txt
mlir/lib/Dialect/StandardOps/CMakeLists.txt
mlir/lib/IR/CMakeLists.txt
mlir/lib/Parser/CMakeLists.txt
mlir/lib/Pass/CMakeLists.txt
mlir/lib/Quantizer/CMakeLists.txt
mlir/test/lib/IR/CMakeLists.txt
Removed:
################################################################################
diff --git a/mlir/lib/Analysis/CMakeLists.txt b/mlir/lib/Analysis/CMakeLists.txt
index c7beabd37d98..c66086f69482 100644
--- a/mlir/lib/Analysis/CMakeLists.txt
+++ b/mlir/lib/Analysis/CMakeLists.txt
@@ -26,11 +26,9 @@ add_llvm_library(MLIRAnalysis
${MLIR_MAIN_INCLUDE_DIR}/mlir/Analysis
)
add_dependencies(MLIRAnalysis
- MLIRAffineOps
MLIRCallOpInterfacesIncGen
MLIRControlFlowInterfacesIncGen
MLIRTypeInferOpInterfaceIncGen
- MLIRLoopOps
)
target_link_libraries(MLIRAnalysis
@@ -50,11 +48,9 @@ add_llvm_library(MLIRLoopAnalysis
${MLIR_MAIN_INCLUDE_DIR}/mlir/Analysis
)
add_dependencies(MLIRLoopAnalysis
- MLIRAffineOps
MLIRCallOpInterfacesIncGen
MLIRControlFlowInterfacesIncGen
MLIRTypeInferOpInterfaceIncGen
- MLIRLoopOps
)
target_link_libraries(MLIRLoopAnalysis
diff --git a/mlir/lib/Conversion/AffineToStandard/CMakeLists.txt b/mlir/lib/Conversion/AffineToStandard/CMakeLists.txt
index 80408d76c2a9..aa916739697e 100644
--- a/mlir/lib/Conversion/AffineToStandard/CMakeLists.txt
+++ b/mlir/lib/Conversion/AffineToStandard/CMakeLists.txt
@@ -4,15 +4,6 @@ add_mlir_conversion_library(MLIRAffineToStandard
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Conversion/AffineToStandard
)
-add_dependencies(
- MLIRAffineToStandard
-
- MLIRAffineOps
- MLIRStandardOps
- MLIRIR
- LLVMCore
- LLVMSupport
-)
target_link_libraries(
MLIRAffineToStandard
PUBLIC
@@ -24,4 +15,4 @@ target_link_libraries(
MLIRIR
LLVMCore
LLVMSupport
-)
+ )
diff --git a/mlir/lib/Conversion/LoopToStandard/CMakeLists.txt b/mlir/lib/Conversion/LoopToStandard/CMakeLists.txt
index 2b6361eae3d5..87188dbf3dbd 100644
--- a/mlir/lib/Conversion/LoopToStandard/CMakeLists.txt
+++ b/mlir/lib/Conversion/LoopToStandard/CMakeLists.txt
@@ -4,14 +4,6 @@ add_mlir_conversion_library(MLIRLoopToStandard
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Conversion/LoopToStandard
)
-add_dependencies(
- MLIRLoopToStandard
-
- MLIRLoopOps
- MLIRTransforms
- LLVMCore
- LLVMSupport
-)
target_link_libraries(
MLIRLoopToStandard
PUBLIC
@@ -19,4 +11,4 @@ target_link_libraries(
MLIRTransforms
LLVMCore
LLVMSupport
-)
+ )
diff --git a/mlir/lib/Conversion/LoopsToGPU/CMakeLists.txt b/mlir/lib/Conversion/LoopsToGPU/CMakeLists.txt
index 3dde75ad1411..dd69af418bde 100644
--- a/mlir/lib/Conversion/LoopsToGPU/CMakeLists.txt
+++ b/mlir/lib/Conversion/LoopsToGPU/CMakeLists.txt
@@ -1,4 +1,12 @@
-set(LIBS
+add_mlir_conversion_library(MLIRLoopsToGPU
+ LoopsToGPU.cpp
+ LoopsToGPUPass.cpp
+
+ ADDITIONAL_HEADER_DIRS
+ ${MLIR_MAIN_INCLUDE_DIR}/mlir/Conversion/LoopsToGPU
+)
+target_link_libraries(MLIRLoopsToGPU
+ PUBLIC
MLIRAffineOps
MLIRAffineToStandard
MLIRGPU
@@ -9,16 +17,4 @@ set(LIBS
MLIRSupport
MLIRTransforms
LLVMSupport
-)
-
-add_mlir_conversion_library(MLIRLoopsToGPU
- LoopsToGPU.cpp
- LoopsToGPUPass.cpp
-
- ADDITIONAL_HEADER_DIRS
- ${MLIR_MAIN_INCLUDE_DIR}/mlir/Conversion/LoopsToGPU
-)
-add_dependencies(MLIRLoopsToGPU ${LIBS})
-target_link_libraries(MLIRLoopsToGPU
- PUBLIC
- ${LIBS})
+ )
diff --git a/mlir/lib/Conversion/StandardToLLVM/CMakeLists.txt b/mlir/lib/Conversion/StandardToLLVM/CMakeLists.txt
index dd9245b7e108..50081d4d6de7 100644
--- a/mlir/lib/Conversion/StandardToLLVM/CMakeLists.txt
+++ b/mlir/lib/Conversion/StandardToLLVM/CMakeLists.txt
@@ -4,14 +4,6 @@ add_mlir_conversion_library(MLIRStandardToLLVM
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Conversion/StandardToLLVM
)
-add_dependencies(
- MLIRStandardToLLVM
-
- MLIRLLVMIR
- MLIRTransforms
- LLVMCore
- LLVMSupport
-)
target_link_libraries(
MLIRStandardToLLVM
PUBLIC
@@ -19,4 +11,4 @@ target_link_libraries(
MLIRTransforms
LLVMCore
LLVMSupport
-)
+ )
diff --git a/mlir/lib/Dialect/AffineOps/CMakeLists.txt b/mlir/lib/Dialect/AffineOps/CMakeLists.txt
index bfa86b247b41..5746377eac24 100644
--- a/mlir/lib/Dialect/AffineOps/CMakeLists.txt
+++ b/mlir/lib/Dialect/AffineOps/CMakeLists.txt
@@ -7,12 +7,8 @@ add_mlir_dialect_library(MLIRAffineOps
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/AffineOps
)
add_dependencies(MLIRAffineOps
-
MLIRAffineOpsIncGen
- MLIREDSC
- MLIRIR
MLIRLoopLikeInterfaceIncGen
- MLIRStandardOps
)
target_link_libraries(MLIRAffineOps
PUBLIC
diff --git a/mlir/lib/Dialect/FxpMathOps/CMakeLists.txt b/mlir/lib/Dialect/FxpMathOps/CMakeLists.txt
index e0621225fb0f..0ccf79416fad 100644
--- a/mlir/lib/Dialect/FxpMathOps/CMakeLists.txt
+++ b/mlir/lib/Dialect/FxpMathOps/CMakeLists.txt
@@ -15,9 +15,5 @@ target_link_libraries(MLIRFxpMathOps
MLIRStandardOps
)
add_dependencies(MLIRFxpMathOps
- MLIRFxpMathOpsIncGen
- MLIRQuantOps
- MLIRIR
- MLIRPass
- MLIRSupport
- MLIRStandardOps)
+ MLIRFxpMathOpsIncGen
+ )
diff --git a/mlir/lib/Dialect/GPU/CMakeLists.txt b/mlir/lib/Dialect/GPU/CMakeLists.txt
index 79291acbf5d4..4ca74e9f767e 100644
--- a/mlir/lib/Dialect/GPU/CMakeLists.txt
+++ b/mlir/lib/Dialect/GPU/CMakeLists.txt
@@ -10,13 +10,7 @@ add_mlir_dialect_library(MLIRGPU
)
add_dependencies(MLIRGPU
MLIRGPUOpsIncGen
- MLIREDSC
- MLIRIR
- MLIRLLVMIR
- MLIRLoopOps
- MLIRSupport
- MLIRTransformUtils
- LLVMSupport)
+ )
target_link_libraries(MLIRGPU
PUBLIC
MLIREDSC
diff --git a/mlir/lib/Dialect/LLVMIR/CMakeLists.txt b/mlir/lib/Dialect/LLVMIR/CMakeLists.txt
index 7c6c3c1d1e32..60b5bdca2802 100644
--- a/mlir/lib/Dialect/LLVMIR/CMakeLists.txt
+++ b/mlir/lib/Dialect/LLVMIR/CMakeLists.txt
@@ -4,7 +4,11 @@ add_mlir_dialect_library(MLIRLLVMIR
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/LLVMIR
)
-add_dependencies(MLIRLLVMIR MLIRControlFlowInterfacesIncGen MLIRLLVMOpsIncGen MLIRLLVMConversionsIncGen MLIROpenMP LLVMFrontendOpenMP LLVMAsmParser LLVMCore LLVMSupport)
+add_dependencies(MLIRLLVMIR
+ MLIRControlFlowInterfacesIncGen
+ MLIRLLVMOpsIncGen
+ MLIRLLVMConversionsIncGen
+ )
target_link_libraries(MLIRLLVMIR
PUBLIC
LLVMAsmParser
@@ -12,7 +16,9 @@ target_link_libraries(MLIRLLVMIR
LLVMSupport
LLVMFrontendOpenMP
MLIROpenMP
- MLIRIR)
+ MLIRIR
+ MLIRSupport
+ )
add_mlir_dialect_library(MLIRNVVMIR
IR/NVVMDialect.cpp
@@ -20,14 +26,18 @@ add_mlir_dialect_library(MLIRNVVMIR
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/LLVMIR
)
-add_dependencies(MLIRNVVMIR MLIRNVVMOpsIncGen MLIRNVVMConversionsIncGen LLVMAsmParser LLVMCore LLVMSupport)
+add_dependencies(MLIRNVVMIR
+ MLIRNVVMOpsIncGen
+ MLIRNVVMConversionsIncGen
+ )
target_link_libraries(MLIRNVVMIR
PUBLIC
LLVMAsmParser
MLIRIR
MLIRLLVMIR
LLVMSupport
- LLVMCore)
+ LLVMCore
+ )
add_mlir_dialect_library(MLIRROCDLIR
IR/ROCDLDialect.cpp
@@ -35,10 +45,14 @@ add_mlir_dialect_library(MLIRROCDLIR
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/LLVMIR
)
-add_dependencies(MLIRROCDLIR MLIRROCDLOpsIncGen MLIRROCDLConversionsIncGen LLVMAsmParser LLVMCore LLVMSupport)
+add_dependencies(MLIRROCDLIR
+ MLIRROCDLOpsIncGen
+ MLIRROCDLConversionsIncGen
+ )
target_link_libraries(MLIRROCDLIR
PUBLIC
LLVMAsmParser
LLVMCore
LLVMSupport
- MLIRIR)
+ MLIRIR
+ )
diff --git a/mlir/lib/Dialect/Linalg/Analysis/CMakeLists.txt b/mlir/lib/Dialect/Linalg/Analysis/CMakeLists.txt
index 4d5570529399..acb2ab6d91d7 100644
--- a/mlir/lib/Dialect/Linalg/Analysis/CMakeLists.txt
+++ b/mlir/lib/Dialect/Linalg/Analysis/CMakeLists.txt
@@ -1,20 +1,17 @@
-set(LIBS
-
- MLIRLinalgOps
- MLIRStandardOps
- )
-
-
add_mlir_dialect_library(MLIRLinalgAnalysis
DependenceAnalysis.cpp
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/Linalg
+
DEPENDS
intrinsics_gen
)
-add_dependencies(MLIRLinalgAnalysis ${LIBS})
target_link_libraries(MLIRLinalgAnalysis
PUBLIC
- ${LIBS})
+ MLIRIR
+ MLIRLinalgOps
+ MLIRStandardOps
+ LLVMSupport
+ )
diff --git a/mlir/lib/Dialect/Linalg/EDSC/CMakeLists.txt b/mlir/lib/Dialect/Linalg/EDSC/CMakeLists.txt
index 078179b91eaa..85ecf2802b25 100644
--- a/mlir/lib/Dialect/Linalg/EDSC/CMakeLists.txt
+++ b/mlir/lib/Dialect/Linalg/EDSC/CMakeLists.txt
@@ -1,23 +1,20 @@
-set(LIBS
-
- MLIREDSC
- MLIRIR
- MLIRAffineOps
- MLIRLinalgOps
- MLIRLoopOps
- MLIRStandardOps
- )
-
add_mlir_dialect_library(MLIRLinalgEDSC
Builders.cpp
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/Linalg
+
DEPENDS
intrinsics_gen
)
-add_dependencies(MLIRLinalgEDSC ${LIBS})
target_link_libraries(MLIRLinalgEDSC
PUBLIC
- ${LIBS})
+ MLIREDSC
+ MLIRIR
+ MLIRAffineOps
+ MLIRLinalgOps
+ MLIRLoopOps
+ MLIRStandardOps
+ LLVMSupport
+ )
diff --git a/mlir/lib/Dialect/Linalg/IR/CMakeLists.txt b/mlir/lib/Dialect/Linalg/IR/CMakeLists.txt
index ef7e90856308..c14a5ce8e757 100644
--- a/mlir/lib/Dialect/Linalg/IR/CMakeLists.txt
+++ b/mlir/lib/Dialect/Linalg/IR/CMakeLists.txt
@@ -1,26 +1,20 @@
-set(LIBS
-
- MLIRIR
- MLIRStandardOps
- )
-
add_mlir_dialect_library(MLIRLinalgOps
LinalgOps.cpp
LinalgTypes.cpp
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/Linalg
+
DEPENDS
intrinsics_gen
)
-
add_dependencies(MLIRLinalgOps
-
- ${LIBS}
MLIRLinalgOpsIncGen
MLIRLinalgStructuredOpsIncGen
MLIRLinalgStructuredOpsInterfaceIncGen
)
target_link_libraries(MLIRLinalgOps
PUBLIC
- ${LIBS})
+ MLIRIR
+ MLIRStandardOps
+ )
diff --git a/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt b/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt
index 2711dd1e6531..4a7aaad436a7 100644
--- a/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt
+++ b/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt
@@ -1,21 +1,3 @@
-set(LIBS
-
- MLIRAffineOps
- MLIRAnalysis
- MLIREDSC
- MLIRIR
- MLIRLinalgAnalysis
- MLIRLinalgEDSC
- MLIRLinalgOps
- MLIRLinalgUtils
- MLIRLoopOps
- MLIRPass
- MLIRStandardOps
- MLIRStandardToLLVM
- MLIRTransformUtils
- MLIRVectorOps
- )
-
add_mlir_dialect_library(MLIRLinalgTransforms
Fusion.cpp
LinalgTransforms.cpp
@@ -30,10 +12,22 @@ add_mlir_dialect_library(MLIRLinalgTransforms
)
add_dependencies(MLIRLinalgTransforms
-
- ${LIBS}
MLIRLinalgTransformPatternsIncGen
)
target_link_libraries(MLIRLinalgTransforms
PUBLIC
- ${LIBS})
+ MLIRAffineOps
+ MLIRAnalysis
+ MLIREDSC
+ MLIRIR
+ MLIRLinalgAnalysis
+ MLIRLinalgEDSC
+ MLIRLinalgOps
+ MLIRLinalgUtils
+ MLIRLoopOps
+ MLIRPass
+ MLIRStandardOps
+ MLIRStandardToLLVM
+ MLIRTransformUtils
+ MLIRVectorOps
+ )
diff --git a/mlir/lib/Dialect/Linalg/Utils/CMakeLists.txt b/mlir/lib/Dialect/Linalg/Utils/CMakeLists.txt
index 1f0f174cface..681a47d31271 100644
--- a/mlir/lib/Dialect/Linalg/Utils/CMakeLists.txt
+++ b/mlir/lib/Dialect/Linalg/Utils/CMakeLists.txt
@@ -1,16 +1,4 @@
-set(LIBS
-
- MLIREDSC
- MLIRIR
- MLIRLinalgOps
- MLIRLoopOps
- MLIRPass
- MLIRStandardOps
- MLIRTransformUtils
- )
-
add_mlir_dialect_library(MLIRLinalgUtils
-
Utils.cpp
ADDITIONAL_HEADER_DIRS
@@ -19,7 +7,14 @@ add_mlir_dialect_library(MLIRLinalgUtils
intrinsics_gen
)
-add_dependencies(MLIRLinalgUtils ${LIBS})
target_link_libraries(MLIRLinalgUtils
PUBLIC
- ${LIBS})
+ MLIRAffineOps
+ MLIREDSC
+ MLIRIR
+ MLIRLinalgOps
+ MLIRLoopOps
+ MLIRPass
+ MLIRStandardOps
+ MLIRTransformUtils
+ )
diff --git a/mlir/lib/Dialect/LoopOps/CMakeLists.txt b/mlir/lib/Dialect/LoopOps/CMakeLists.txt
index 248f1479b0cf..f41e22d9c8bd 100644
--- a/mlir/lib/Dialect/LoopOps/CMakeLists.txt
+++ b/mlir/lib/Dialect/LoopOps/CMakeLists.txt
@@ -7,12 +7,8 @@ add_mlir_dialect_library(MLIRLoopOps
${MLIR_MAIN_INCLUDE_DIR}/mlir/LoopOps
)
add_dependencies(MLIRLoopOps
-
- MLIREDSC
MLIRLoopLikeInterfaceIncGen
MLIRLoopOpsIncGen
- MLIRStandardOps
- LLVMSupport
)
target_link_libraries(MLIRLoopOps
PUBLIC
diff --git a/mlir/lib/Dialect/QuantOps/CMakeLists.txt b/mlir/lib/Dialect/QuantOps/CMakeLists.txt
index 188de3f93dc9..f7fbd6c044ec 100644
--- a/mlir/lib/Dialect/QuantOps/CMakeLists.txt
+++ b/mlir/lib/Dialect/QuantOps/CMakeLists.txt
@@ -13,12 +13,8 @@ add_mlir_dialect_library(MLIRQuantOps
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/QuantOps
)
add_dependencies(MLIRQuantOps
- MLIRIR
- MLIRPass
- MLIRQuantOpsIncGen
- MLIRSupport
- MLIRStandardOps)
-
+ MLIRQuantOpsIncGen
+ )
target_link_libraries(MLIRQuantOps
PUBLIC
MLIRIR
diff --git a/mlir/lib/Dialect/SDBM/CMakeLists.txt b/mlir/lib/Dialect/SDBM/CMakeLists.txt
index 1d3230604db0..64d58c666e63 100644
--- a/mlir/lib/Dialect/SDBM/CMakeLists.txt
+++ b/mlir/lib/Dialect/SDBM/CMakeLists.txt
@@ -5,7 +5,7 @@ add_mlir_dialect_library(MLIRSDBM
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/SDBM
)
-add_dependencies(MLIRSDBM MLIRIR)
target_link_libraries(MLIRSDBM
PUBLIC
- MLIRIR)
+ MLIRIR
+ )
diff --git a/mlir/lib/Dialect/StandardOps/CMakeLists.txt b/mlir/lib/Dialect/StandardOps/CMakeLists.txt
index a2f79f23138f..578e90bd45b1 100644
--- a/mlir/lib/Dialect/StandardOps/CMakeLists.txt
+++ b/mlir/lib/Dialect/StandardOps/CMakeLists.txt
@@ -7,13 +7,9 @@ add_mlir_dialect_library(MLIRStandardOps
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/StandardOps
)
add_dependencies(MLIRStandardOps
-
MLIRCallOpInterfacesIncGen
MLIRControlFlowInterfacesIncGen
- MLIREDSC
- MLIRIR
MLIRStandardOpsIncGen
- LLVMSupport
)
target_link_libraries(MLIRStandardOps
PUBLIC
diff --git a/mlir/lib/IR/CMakeLists.txt b/mlir/lib/IR/CMakeLists.txt
index b4c1859dd175..4f473f6be56f 100644
--- a/mlir/lib/IR/CMakeLists.txt
+++ b/mlir/lib/IR/CMakeLists.txt
@@ -5,5 +5,11 @@ add_llvm_library(MLIRIR
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/IR
)
-add_dependencies(MLIRIR MLIRCallOpInterfacesIncGen MLIROpAsmInterfacesIncGen MLIRSupport LLVMSupport)
-target_link_libraries(MLIRIR PUBLIC MLIRSupport LLVMSupport)
+add_dependencies(MLIRIR
+ MLIRCallOpInterfacesIncGen
+ MLIROpAsmInterfacesIncGen
+ )
+target_link_libraries(MLIRIR
+ PUBLIC
+ MLIRSupport
+ LLVMSupport)
diff --git a/mlir/lib/Parser/CMakeLists.txt b/mlir/lib/Parser/CMakeLists.txt
index 2b3554bded5f..5608eefe8aeb 100644
--- a/mlir/lib/Parser/CMakeLists.txt
+++ b/mlir/lib/Parser/CMakeLists.txt
@@ -6,7 +6,6 @@ add_llvm_library(MLIRParser
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Parser
)
-add_dependencies(MLIRParser MLIRIR MLIRAnalysis)
target_link_libraries(MLIRParser
PUBLIC
MLIRIR
diff --git a/mlir/lib/Pass/CMakeLists.txt b/mlir/lib/Pass/CMakeLists.txt
index 8db845b029f0..31d4b63352eb 100644
--- a/mlir/lib/Pass/CMakeLists.txt
+++ b/mlir/lib/Pass/CMakeLists.txt
@@ -5,7 +5,6 @@ add_llvm_library(MLIRPass
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Pass
)
-add_dependencies(MLIRPass MLIRAnalysis MLIRIR LLVMSupport)
target_link_libraries(MLIRPass
PUBLIC
MLIRAnalysis
diff --git a/mlir/lib/Quantizer/CMakeLists.txt b/mlir/lib/Quantizer/CMakeLists.txt
index e98d3683431a..23dca84d8418 100644
--- a/mlir/lib/Quantizer/CMakeLists.txt
+++ b/mlir/lib/Quantizer/CMakeLists.txt
@@ -11,11 +11,6 @@ add_llvm_library(MLIRQuantizerSupport
ADDITIONAL_HEADER_DIRS
)
-add_dependencies(MLIRQuantizerSupport
- MLIRIR
- MLIRQuantOps
- MLIRSupport
- MLIRStandardOps)
target_link_libraries(MLIRQuantizerSupport
PUBLIC
MLIRIR
@@ -33,8 +28,8 @@ add_llvm_library(MLIRQuantizerFxpMathConfig
)
add_dependencies(MLIRQuantizerFxpMathConfig
- MLIRFxpMathOpsIncGen
- MLIRQuantizerSupport)
+ MLIRFxpMathOpsIncGen
+ )
target_link_libraries(MLIRQuantizerFxpMathConfig
PUBLIC
MLIRIR
@@ -51,10 +46,6 @@ add_llvm_library(MLIRQuantizerTransforms
ADDITIONAL_HEADER_DIRS
)
-add_dependencies(MLIRQuantizerTransforms
- MLIRQuantizerFxpMathConfig
- MLIRQuantizerSupport
- MLIRPass)
target_link_libraries(MLIRQuantizerTransforms
PUBLIC
MLIRIR
diff --git a/mlir/test/lib/IR/CMakeLists.txt b/mlir/test/lib/IR/CMakeLists.txt
index e537b8cba9a0..c10dc157edd9 100644
--- a/mlir/test/lib/IR/CMakeLists.txt
+++ b/mlir/test/lib/IR/CMakeLists.txt
@@ -7,9 +7,7 @@ add_llvm_library(MLIRTestIR
)
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../TestDialect)
include_directories(${CMAKE_CURRENT_BINARY_DIR}/../TestDialect)
-add_dependencies(MLIRTestIR
- MLIRTestDialect
- )
+
target_link_libraries(MLIRTestIR
PUBLIC
MLIRPass
More information about the Mlir-commits
mailing list