Skip to content

Commit 8518342

Browse files
committed
temporary workaround: one-shot iteration folding with vscale
1 parent 560f397 commit 8518342

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

mlir/lib/Dialect/Utils/StaticValueUtils.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -272,6 +272,8 @@ std::optional<int64_t> constantTripCount(OpFoldResult lb, OpFoldResult ub,
272272
std::optional<int64_t> lbConstant = getConstantIntValue(lb);
273273
if (!lbConstant)
274274
return std::nullopt;
275+
if (*lbConstant == 0 && ub == step)
276+
return 1;
275277
std::optional<int64_t> ubConstant = getConstantIntValue(ub);
276278
if (!ubConstant)
277279
return std::nullopt;

0 commit comments

Comments
 (0)