Skip to content

Commit 3a30a55

Browse files
committed
removed llvm_unreachable addressing Zach's comment
1 parent 40670b1 commit 3a30a55

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

lib/Conversion/TorchToLinalg/Linear.cpp

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2101,11 +2101,7 @@ class ConvertAtenConvolutionBackwardOp
21012101
bindDimsList(context, MutableArrayRef{dims});
21022102

21032103
auto n = [&]() { return dims[0]; };
2104-
auto g = [&]() {
2105-
if (!isGrouped)
2106-
llvm_unreachable("g() called for non-grouped convolution.");
2107-
return dims[1];
2108-
};
2104+
auto g = [&]() { return dims[1]; };
21092105
auto c = [&]() { return dims[1 + static_cast<int64_t>(isGrouped)]; };
21102106
auto o = [&](size_t i) {
21112107
return dims[1 + static_cast<int64_t>(isGrouped) + 1 + i];
@@ -2180,11 +2176,7 @@ class ConvertAtenConvolutionBackwardOp
21802176
SmallVector<AffineExpr> dims(numIterators);
21812177
bindDimsList(context, MutableArrayRef{dims});
21822178

2183-
auto g = [&]() {
2184-
if (!isGrouped)
2185-
llvm_unreachable("g() called for non-grouped convolution.");
2186-
return dims[0];
2187-
};
2179+
auto g = [&]() { return dims[0]; };
21882180
auto f = [&]() { return dims[static_cast<int64_t>(isGrouped)]; };
21892181
auto c = [&]() { return dims[static_cast<int64_t>(isGrouped) + 1]; };
21902182
auto k = [&](size_t i) {

0 commit comments

Comments
 (0)