Skip to content

Commit

Permalink
[MLIR] Fixes for BUILD_SHARED_LIBS=on
Browse files Browse the repository at this point in the history
Differential Revision: https://reviews.llvm.org/D75308
  • Loading branch information
stephenneuendorffer committed Mar 6, 2020
1 parent 7c64f6b commit 9f979d7
Show file tree
Hide file tree
Showing 13 changed files with 40 additions and 6 deletions.
1 change: 1 addition & 0 deletions mlir/examples/toy/Ch5/CMakeLists.txt
Expand Up @@ -35,4 +35,5 @@ target_link_libraries(toyc-ch5
MLIRIR
MLIRParser
MLIRPass
MLIRSupport
MLIRTransforms)
1 change: 1 addition & 0 deletions mlir/examples/toy/Ch6/CMakeLists.txt
Expand Up @@ -41,6 +41,7 @@ target_link_libraries(toyc-ch6
MLIRLLVMIR
MLIRParser
MLIRPass
MLIRSupport
MLIRTargetLLVMIR
MLIRTransforms
)
17 changes: 14 additions & 3 deletions mlir/lib/Analysis/CMakeLists.txt
Expand Up @@ -13,9 +13,22 @@ set(LLVM_OPTIONAL_SOURCES
Verifier.cpp
)

add_mlir_library(MLIRControlFlowAnalysis
ControlFlowInterfaces.cpp

ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Analysis

DEPENDS
MLIRControlFlowInterfacesIncGen
)
target_link_libraries(MLIRControlFlowAnalysis
PUBLIC
MLIRIR
)

add_mlir_library(MLIRAnalysis
CallGraph.cpp
ControlFlowInterfaces.cpp
InferTypeOpInterface.cpp
Liveness.cpp
SliceAnalysis.cpp
Expand All @@ -27,7 +40,6 @@ add_mlir_library(MLIRAnalysis

DEPENDS
MLIRCallOpInterfacesIncGen
MLIRControlFlowInterfacesIncGen
MLIRTypeInferOpInterfaceIncGen
)

Expand All @@ -49,7 +61,6 @@ add_mlir_library(MLIRLoopAnalysis

DEPENDS
MLIRCallOpInterfacesIncGen
MLIRControlFlowInterfacesIncGen
MLIRTypeInferOpInterfaceIncGen
)

Expand Down
8 changes: 8 additions & 0 deletions mlir/lib/Conversion/GPUToCUDA/CMakeLists.txt
Expand Up @@ -13,9 +13,17 @@ endif()
add_mlir_conversion_library(MLIRGPUtoCUDATransforms ${SOURCES})
target_link_libraries(MLIRGPUtoCUDATransforms
PUBLIC
LLVMNVPTXCodeGen
LLVMNVPTXDesc
LLVMNVPTXInfo
LLVMCore
LLVMMC
LLVMSupport
MLIRGPU
MLIRIR
MLIRLLVMIR
MLIRNVVMIR
MLIRPass
MLIRSupport
MLIRTargetNVVMIR
)
1 change: 1 addition & 0 deletions mlir/lib/Conversion/GPUToVulkan/CMakeLists.txt
Expand Up @@ -14,4 +14,5 @@ target_link_libraries(MLIRGPUtoVulkanTransforms
MLIRSupport
MLIRTransforms
MLIRTranslation
LLVMSupport
)
2 changes: 1 addition & 1 deletion mlir/lib/Dialect/CMakeLists.txt
Expand Up @@ -7,7 +7,7 @@ add_subdirectory(LoopOps)
add_subdirectory(OpenMP)
add_subdirectory(QuantOps)
add_subdirectory(SDBM)
add_subdirectory(Shape)
#add_subdirectory(Shape)
add_subdirectory(SPIRV)
add_subdirectory(StandardOps)
add_subdirectory(VectorOps)
Expand Down
1 change: 1 addition & 0 deletions mlir/lib/Dialect/LLVMIR/CMakeLists.txt
Expand Up @@ -15,6 +15,7 @@ target_link_libraries(MLIRLLVMIR
LLVMCore
LLVMSupport
LLVMFrontendOpenMP
MLIRAnalysis
MLIROpenMP
MLIRIR
MLIRSupport
Expand Down
6 changes: 5 additions & 1 deletion mlir/lib/Dialect/LoopOps/Transforms/CMakeLists.txt
Expand Up @@ -6,9 +6,13 @@ add_mlir_dialect_library(MLIRLoopOpsTransforms
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/LoopOps
)

target_link_libraries(MLIRLoopOpsTransforms
PUBLIC
MLIRAffineOps
MLIRIR
MLIRPass
MLIRLoopOps
MLIRStandardOps
MLIRSupport
LLVMSupport
)
1 change: 1 addition & 0 deletions mlir/lib/Dialect/StandardOps/CMakeLists.txt
Expand Up @@ -13,6 +13,7 @@ add_mlir_dialect_library(MLIRStandardOps
)
target_link_libraries(MLIRStandardOps
PUBLIC
MLIRControlFlowAnalysis
MLIREDSC
MLIRIR
LLVMSupport
Expand Down
1 change: 1 addition & 0 deletions mlir/lib/Dialect/VectorOps/CMakeLists.txt
Expand Up @@ -13,6 +13,7 @@ add_mlir_dialect_library(MLIRVectorOps
)
target_link_libraries(MLIRVectorOps
PUBLIC
MLIREDSC
MLIRIR
MLIRStandardOps
MLIRAffineOps
Expand Down
1 change: 1 addition & 0 deletions mlir/test/SDBM/CMakeLists.txt
Expand Up @@ -8,6 +8,7 @@ target_link_libraries(mlir-sdbm-api-test
PRIVATE
MLIRIR
MLIRSDBM
MLIRSupport
LLVMCore
LLVMSupport
)
Expand Down
1 change: 1 addition & 0 deletions mlir/test/lib/TestDialect/CMakeLists.txt
Expand Up @@ -27,6 +27,7 @@ target_link_libraries(MLIRTestDialect
MLIRIR
MLIRLinalgTransforms
MLIRPass
MLIRStandardOps
MLIRTransforms
MLIRTransformUtils
LLVMSupport
Expand Down
5 changes: 4 additions & 1 deletion mlir/tools/mlir-cpu-runner/CMakeLists.txt
Expand Up @@ -16,4 +16,7 @@ target_link_libraries(mlir-cpu-runner PRIVATE
MLIRSupport
LLVMCore
LLVMSupport
)
LLVMX86CodeGen
LLVMX86Desc
LLVMX86Info
)

0 comments on commit 9f979d7

Please sign in to comment.