[Mlir-commits] [mlir] a9a3057 - [mlir] Revise naming of MLIROptMain and MLIRMlirOptLib
Alex Zinenko
llvmlistbot at llvm.org
Wed Feb 12 00:46:15 PST 2020
Author: Marius Brehler
Date: 2020-02-12T09:46:09+01:00
New Revision: a9a305716bbfa657ce0f7ae9cd50df82720a6db0
URL: https://github.com/llvm/llvm-project/commit/a9a305716bbfa657ce0f7ae9cd50df82720a6db0
DIFF: https://github.com/llvm/llvm-project/commit/a9a305716bbfa657ce0f7ae9cd50df82720a6db0.diff
LOG: [mlir] Revise naming of MLIROptMain and MLIRMlirOptLib
* Rename CMake target MLIROptMain to MLIROptLib:
The target provides the main library
* Rename CMake target MLIRMlirOptLib to MLIRMlirOptMain:
The target provides the main() entry function
At the moment, the Bazel configuration of TenorFlow maps the target
MlirOptLib to "lib/Support/MlirOptMain.cpp" and MlirOptMain to
"tools/mlir-opt/mlir-opt.cpp". This is the other way around in the CMake
configuration. As discussed in the context of the pull request
https://github.com/tensorflow/tensorflow/pull/36301, it seems useful to
revise the naming in the MLIR repo.
Differential Revision: https://reviews.llvm.org/D73778
Added:
Modified:
mlir/lib/Support/CMakeLists.txt
mlir/tools/mlir-opt/CMakeLists.txt
Removed:
################################################################################
diff --git a/mlir/lib/Support/CMakeLists.txt b/mlir/lib/Support/CMakeLists.txt
index 84fecd05fbfd..b8c0b17a68f8 100644
--- a/mlir/lib/Support/CMakeLists.txt
+++ b/mlir/lib/Support/CMakeLists.txt
@@ -17,13 +17,13 @@ add_llvm_library(MLIRSupport
)
target_link_libraries(MLIRSupport LLVMSupport ${LLVM_PTHREAD_LIB})
-add_llvm_library(MLIROptMain
+add_llvm_library(MLIROptLib
MlirOptMain.cpp
ADDITIONAL_HEADER_DIRS
${MLIR_MAIN_INCLUDE_DIR}/mlir/Support
)
-target_link_libraries(MLIROptMain
+target_link_libraries(MLIROptLib
MLIRPass
MLIRParser
LLVMSupport
diff --git a/mlir/tools/mlir-opt/CMakeLists.txt b/mlir/tools/mlir-opt/CMakeLists.txt
index de18159f18f0..2277c4110d3d 100644
--- a/mlir/tools/mlir-opt/CMakeLists.txt
+++ b/mlir/tools/mlir-opt/CMakeLists.txt
@@ -5,16 +5,16 @@ set(LLVM_OPTIONAL_SOURCES
set(LIB_LIBS
MLIRAnalysis
MLIRLLVMIR
- MLIROptMain
+ MLIROptLib
MLIRParser
MLIRPass
MLIRTransforms
MLIRSupport
)
-add_llvm_library(MLIRMlirOptLib
+add_llvm_library(MLIRMlirOptMain
mlir-opt.cpp
)
-target_link_libraries(MLIRMlirOptLib
+target_link_libraries(MLIRMlirOptMain
${LIB_LIBS}
)
@@ -43,7 +43,7 @@ set(FULL_LINK_LIBS
MLIRLoopOps
MLIRNVVMIR
MLIROpenMP
- MLIROptMain
+ MLIROptLib
MLIRParser
MLIRPass
MLIRQuantizerFxpMathConfig
@@ -71,7 +71,7 @@ set(FULL_LINK_LIBS
)
set(LIBS
MLIRIR
- MLIROptMain
+ MLIROptLib
LLVMSupport
LLVMCore
LLVMAsmParser
More information about the Mlir-commits
mailing list