This commit adds a new library that merges/combines a number of spv modules into a combined one. The library has a single entry point: combine(...). To combine a number of MLIR spv modules, we move all the module-level ops from all the input modules into one big combined module. To that end, the combination process can proceed in 2 phases: (1) resolving conflicts between pairs of ops from different modules (2) deduplicate equivalent ops/sub-ops in the merged module. (TODO) This patch implements only the first phase. Reviewed By: antiagainst Differential Revision: https://reviews.llvm.org/D90477
12 lines
201 B
CMake
12 lines
201 B
CMake
add_mlir_dialect_library(MLIRSPIRVModuleCombiner
|
|
ModuleCombiner.cpp
|
|
|
|
ADDITIONAL_HEADER_DIRS
|
|
${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/SPIRV
|
|
|
|
LINK_LIBS PUBLIC
|
|
MLIRIR
|
|
MLIRSPIRV
|
|
MLIRSupport
|
|
)
|