File tree 2 files changed +0
-12
lines changed
src/Dialect/ONNX/Transforms
2 files changed +0
-12
lines changed Original file line number Diff line number Diff line change @@ -8,7 +8,6 @@ project(onnx-mlir)
8
8
option (ONNX_MLIR_BUILD_TESTS "Build ONNX-MLIR test executables. If OFF, just generate build targets." ON )
9
9
option (ONNX_MLIR_CCACHE_BUILD "Set to ON for a ccache enabled build." OFF )
10
10
option (ONNX_MLIR_ENABLE_STABLEHLO "Enable StableHLO support." ON )
11
- option (ONNX_MLIR_DECOMP_ONNX_CONVTRANSPOSE "Enable ONNXConvTransposeOp decomposition." ON )
12
11
option (ONNX_MLIR_ENABLE_WERROR "Enable warnings as errors." OFF )
13
12
option (ONNX_MLIR_SUPPRESS_THIRD_PARTY_WARNINGS "Suppress warning in third_party code." ON )
14
13
option (ONNX_MLIR_ENABLE_JAVA "Set to ON for building the Java runtime, tools, and tests" ON )
@@ -208,10 +207,6 @@ if (ONNX_MLIR_ENABLE_STABLEHLO)
208
207
add_compile_definitions (ONNX_MLIR_ENABLE_STABLEHLO)
209
208
endif ()
210
209
211
- if (ONNX_MLIR_DECOMP_ONNX_CONVTRANSPOSE)
212
- add_compile_definitions (ONNX_MLIR_DECOMP_ONNX_CONVTRANSPOSE)
213
- endif ()
214
-
215
210
add_subdirectory (utils)
216
211
add_subdirectory (include )
217
212
add_subdirectory (src)
Original file line number Diff line number Diff line change @@ -332,15 +332,10 @@ bool hasStaticSpatialDims(Value v) {
332
332
}
333
333
334
334
bool shouldDecomposeConvTransposeOp (Value convTransposeResult) {
335
- #ifdef ONNX_MLIR_DECOMP_ONNX_CONVTRANSPOSE
336
335
ONNXConvTransposeOp op =
337
336
mlir::cast<ONNXConvTransposeOp>(convTransposeResult.getDefiningOp ());
338
337
return hasShapeAndRank (convTransposeResult) &&
339
338
hasStaticSpatialDims (op.getX ()) && hasStaticSpatialDims (op.getW ());
340
- #else
341
- // Disable the ONNXConvTransposeOp decomposition patterns.
342
- return false ;
343
- #endif
344
339
}
345
340
346
341
// Split on the specified axis. The length of each output is one.
@@ -1128,7 +1123,6 @@ void DecomposeONNXToONNXPass::runOnOperation() {
1128
1123
op, alpha, rankA, rankB);
1129
1124
});
1130
1125
1131
- #ifdef ONNX_MLIR_DECOMP_ONNX_CONVTRANSPOSE
1132
1126
#ifdef ONNX_MLIR_ENABLE_STABLEHLO
1133
1127
// ONNXtoStablehlo pass has own rewriting for ConvTranspose Op using
1134
1128
// stablehlo ops. To avoid conflict with it, decomposing for ConvTranspose
@@ -1141,7 +1135,6 @@ void DecomposeONNXToONNXPass::runOnOperation() {
1141
1135
});
1142
1136
#ifdef ONNX_MLIR_ENABLE_STABLEHLO
1143
1137
}
1144
- #endif
1145
1138
#endif
1146
1139
1147
1140
RewritePatternSet patterns (context);
You can’t perform that action at this time.
0 commit comments