Skip to content

Commit 3a0b816

Browse files
committed
Sync to buddy-mlir DIP library.
1 parent ef42b23 commit 3a0b816

File tree

1 file changed

+8
-22
lines changed

1 file changed

+8
-22
lines changed

benchmarks/ImageProcessing/CMakeLists.txt

+8-22
Original file line numberDiff line numberDiff line change
@@ -82,26 +82,6 @@ set_target_properties(BuddyConv2D PROPERTIES LINKER_LANGUAGE CXX)
8282
# add_library(BuddyConv2D STATIC buddy-conv2d.o)
8383
# set_target_properties(BuddyConv2D PROPERTIES LINKER_LANGUAGE CXX)
8484

85-
#-------------------------------------------------------------------------------
86-
# Buddy DIP Dialect
87-
#-------------------------------------------------------------------------------
88-
89-
add_custom_command(OUTPUT dip.o
90-
COMMAND ${BUDDY_MLIR_BUILD_DIR}/bin/buddy-opt
91-
${BUDDY_MLIR_BUILD_DIR}/../examples/DIPDialect/dip.mlir
92-
-lower-dip="DIP-strip-mining=${SPLITING_SIZE}" -arith-expand
93-
-lower-affine -convert-scf-to-cf -convert-math-to-llvm
94-
-convert-vector-to-llvm -convert-memref-to-llvm
95-
-llvm-request-c-wrappers -convert-func-to-llvm
96-
-reconcile-unrealized-casts |
97-
${LLVM_MLIR_BINARY_DIR}/mlir-translate --mlir-to-llvmir |
98-
${LLVM_MLIR_BINARY_DIR}/llc -mtriple=${BUDDY_OPT_TRIPLE}
99-
-mattr=${BUDDY_OPT_ATTR} --filetype=obj
100-
-o ${BUDDY_BINARY_DIR}/../benchmarks/ImageProcessing/dip.o
101-
)
102-
add_library(DIP STATIC dip.o)
103-
set_target_properties(DIP PROPERTIES LINKER_LANGUAGE CXX)
104-
10585
#-------------------------------------------------------------------------------
10686
# Image Processing Benchmark Target
10787
#-------------------------------------------------------------------------------
@@ -122,12 +102,18 @@ target_include_directories(image-processing-benchmark
122102
${BUDDY_SOURCE_DIR}/benchmarks/ImageProcessing/include/
123103
${EIGEN_DIR}
124104
${EIGEN_DIR}/unsupported/
125-
)
105+
)
106+
107+
target_link_directories(image-processing-benchmark
108+
PRIVATE
109+
${BUDDY_MLIR_LIB_DIR}
110+
)
126111

127112
target_link_libraries(image-processing-benchmark
128113
GoogleBenchmark
129114
${OpenCV_LIBS}
130115
MLIRConv2D
131116
BuddyConv2D
132-
DIP
117+
# Link Buddy MLIR DIP Library.
118+
BuddyLibDIP
133119
)

0 commit comments

Comments
 (0)