Skip to content

Commit d542cb3

Browse files
[mlir][Interfaces][NFC] ValueBoundsConstraintSet: Delete dead code (#86098)
There is an assertion that the stop condition is not satisfied for the the starting point at the beginning of `computeBound`. Therefore, that case does not have to be handled later on in that function.
1 parent e69cab7 commit d542cb3

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

mlir/lib/Interfaces/ValueBoundsOpInterface.cpp

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -286,18 +286,6 @@ LogicalResult ValueBoundsConstraintSet::computeBound(
286286
Builder b(value.getContext());
287287
mapOperands.clear();
288288

289-
if (stopCondition(value, dim)) {
290-
// Special case: If the stop condition is satisfied for the input
291-
// value/dimension, directly return it.
292-
mapOperands.push_back(std::make_pair(value, dim));
293-
AffineExpr bound = b.getAffineDimExpr(0);
294-
if (type == BoundType::UB)
295-
bound = bound + ubAdjustment;
296-
resultMap = AffineMap::get(/*dimCount=*/1, /*symbolCount=*/0,
297-
b.getAffineDimExpr(0));
298-
return success();
299-
}
300-
301289
// Process the backward slice of `value` (i.e., reverse use-def chain) until
302290
// `stopCondition` is met.
303291
ValueDim valueDim = std::make_pair(value, dim.value_or(kIndexValue));

0 commit comments

Comments
 (0)