Is there a flag to pass to cmake
when building MLIR to specify which public dialects to build along with the MLIR installation?
Running config with:
cmake -G Ninja \
-DMLIR_ENABLE_BINDINGS_PYTHON=ON \
-DPYTHON3_EXECUTABLE=$PYTHON_EXECUTABLE \
-DLLVM_ENABLE_PROJECTS=mlir \
-DLLVM_BUILD_EXAMPLES=OFF \
-DLLVM_TARGETS_TO_BUILD="Native;NVPTX;AMDGPU" \
-DCMAKE_BUILD_TYPE=Release
I can see that the build includes .inc
files for each of the public dialects under $build_dir/tools/mlir/include/mlir/Dialect
.
Reason I ask is that I am using this current MLIR build as an out-of-tree dependency for a downstream project which requires the GPUOps
library as a build dependency:
add_mlir_dialect_library(TritonGPUIR
Dialect.cpp
Traits.cpp
DEPENDS
TritonGPUTableGen
TritonGPUAttrDefsIncGen
LINK_LIBS PUBLIC
**MLIRGPUOps**
TritonIR
)
Apologies if this question is ill-posed, as I am still learning MLIR and shaky around how dialects are built / linked.
Thanks!